maven build issues with non-numeric custom version

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

maven build issues with non-numeric custom version

Ryan McKinley
From:

It says we can get a custom build number using:
ant -Dversion=my-special-version get-maven-poms

but this fails with:

BUILD FAILED

/Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'



Using a numeric version number things work OK.


Any ideas?


ryan


Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

shikhar
I have run into this as well. It'd be great to allow arbitary strings for versioning of custom releases.

This is the culprit:


On Tue, Jan 28, 2014 at 4:10 AM, Ryan McKinley <[hidden email]> wrote:
From:

It says we can get a custom build number using:
ant -Dversion=my-special-version get-maven-poms

but this fails with:

BUILD FAILED

/Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'



Using a numeric version number things work OK.


Any ideas?


ryan



Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

shikhar
On Tue, Jan 28, 2014 at 7:28 PM, shikhar <[hidden email]> wrote:
I have run into this as well. It'd be great to allow arbitary strings for versioning of custom releases.

Specifically, I was trying to use git sha's.
Reply | Threaded
Open this post in threaded view
|

RE: maven build issues with non-numeric custom version

Uwe Schindler
In reply to this post by Ryan McKinley

You should not use a version like this to build artifacts, because it violates the Maven specs for versioning. You can define a custom version, but you have to prepend it with a valid Maven-version number, like:

 

-Dversion=“4.6-my-special-version”

 

Ideally do it like Jenkins with build number:

 

-Ddev.version.suffix=”my-special-version”, which will produce the above version number with the 4.6 checkout.

 

Uwe

 

-----

Uwe Schindler

H.-H.-Meier-Allee 63, D-28213 Bremen

http://www.thetaphi.de

eMail: [hidden email]

 

From: Ryan McKinley [mailto:[hidden email]]
Sent: Monday, January 27, 2014 11:41 PM
To: [hidden email]
Subject: maven build issues with non-numeric custom version

 

From:

 

It says we can get a custom build number using:

ant -Dversion=my-special-version get-maven-poms

 

but this fails with:

BUILD FAILED

/Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'

 

 

Using a numeric version number things work OK.

 

Any ideas?

 

ryan

 

Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

Ryan McKinley
The real version number i was trying was:
-Dversion=4.7.r1562172M

essentially a standard lucene build with a few chances.  Having the non-numbers in the version make it fail

This used to work -- and now seems to fail only for lucene-analyzers-phonetic

but i don't have any idea where to start!

ryan


On Tue, Jan 28, 2014 at 9:30 AM, Uwe Schindler <[hidden email]> wrote:

You should not use a version like this to build artifacts, because it violates the Maven specs for versioning. You can define a custom version, but you have to prepend it with a valid Maven-version number, like:

 

-Dversion=“4.6-my-special-version”

 

Ideally do it like Jenkins with build number:

 

-Ddev.version.suffix=”my-special-version”, which will produce the above version number with the 4.6 checkout.

 

Uwe

 

-----

Uwe Schindler

H.-H.-Meier-Allee 63, D-28213 Bremen

http://www.thetaphi.de

eMail: [hidden email]

 

From: Ryan McKinley [mailto:[hidden email]]
Sent: Monday, January 27, 2014 11:41 PM
To: [hidden email]
Subject: maven build issues with non-numeric custom version

 

From:

 

It says we can get a custom build number using:

ant -Dversion=my-special-version get-maven-poms

 

but this fails with:

BUILD FAILED

/Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'

 

 

Using a numeric version number things work OK.

 

Any ideas?

 

ryan

 


Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

sarowe

Ryan, I'll take a look today. - Steve

On Jan 28, 2014 2:39 PM, "Ryan McKinley" <[hidden email]> wrote:
The real version number i was trying was:
-Dversion=4.7.r1562172M

essentially a standard lucene build with a few chances.  Having the non-numbers in the version make it fail

This used to work -- and now seems to fail only for lucene-analyzers-phonetic

but i don't have any idea where to start!

ryan


On Tue, Jan 28, 2014 at 9:30 AM, Uwe Schindler <[hidden email]> wrote:

You should not use a version like this to build artifacts, because it violates the Maven specs for versioning. You can define a custom version, but you have to prepend it with a valid Maven-version number, like:

 

-Dversion=“4.6-my-special-version”

 

Ideally do it like Jenkins with build number:

 

-Ddev.version.suffix=”my-special-version”, which will produce the above version number with the 4.6 checkout.

 

Uwe

 

-----

Uwe Schindler

H.-H.-Meier-Allee 63, D-28213 Bremen

http://www.thetaphi.de

eMail: [hidden email]

 

From: Ryan McKinley [mailto:[hidden email]]
Sent: Monday, January 27, 2014 11:41 PM
To: [hidden email]
Subject: maven build issues with non-numeric custom version

 

From:

 

It says we can get a custom build number using:

ant -Dversion=my-special-version get-maven-poms

 

but this fails with:

BUILD FAILED

/Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:

/Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'

 

 

Using a numeric version number things work OK.

 

Any ideas?

 

ryan

 


Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

sarowe
See https://issues.apache.org/jira/browse/LUCENE-5420 - I put up a patch that fixes the issue for me. - Steve

On Jan 28, 2014, at 3:10 PM, Steve Rowe <[hidden email]> wrote:

> Ryan, I'll take a look today. - Steve
>
> On Jan 28, 2014 2:39 PM, "Ryan McKinley" <[hidden email]> wrote:
> The real version number i was trying was:
> -Dversion=4.7.r1562172M
>
> essentially a standard lucene build with a few chances.  Having the non-numbers in the version make it fail
>
> This used to work -- and now seems to fail only for lucene-analyzers-phonetic
>
> but i don't have any idea where to start!
>
> ryan
>
>
> On Tue, Jan 28, 2014 at 9:30 AM, Uwe Schindler <[hidden email]> wrote:
> You should not use a version like this to build artifacts, because it violates the Maven specs for versioning. You can define a custom version, but you have to prepend it with a valid Maven-version number, like:
>
>  
>
> -Dversion=“4.6-my-special-version”
>
>  
>
> Ideally do it like Jenkins with build number:
>
>  
>
> -Ddev.version.suffix=”my-special-version”, which will produce the above version number with the 4.6 checkout.
>
>  
>
> Uwe
>
>  
>
> -----
>
> Uwe Schindler
>
> H.-H.-Meier-Allee 63, D-28213 Bremen
>
> http://www.thetaphi.de
>
> eMail: [hidden email]
>
>  
>
> From: Ryan McKinley [mailto:[hidden email]]
> Sent: Monday, January 27, 2014 11:41 PM
> To: [hidden email]
> Subject: maven build issues with non-numeric custom version
>
>  
>
> From:
>
> http://svn.apache.org/repos/asf/lucene/dev/branches/branch_4x/dev-tools/maven/README.maven
>
>  
>
> It says we can get a custom build number using:
>
> ant -Dversion=my-special-version get-maven-poms
>  
>
> but this fails with:
>
> BUILD FAILED
> /Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:
> /Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:
> /Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'
>  
>  
> Using a numeric version number things work OK.
>  
> Any ideas?
>  
> ryan
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: maven build issues with non-numeric custom version

sarowe
Ryan, Shikhar, Uwe: thanks for the feedback.  

I committed the fix on LUCENE-5420, and all of the following worked for me (no build errors) and ‘mvn -DskipTests install’ also worked for each from the resulting POMs under maven-build/:

ant -Dversion=4.7.r1562172M get-maven-poms
ant -Ddev.version.suffix=r1562172M get-maven-poms

ant -Dversion=my-special-version get-maven-poms
ant -Ddev.version.suffix=my-special-version get-maven-poms

ant -Dversion=0L8e0UWtDs get-maven-poms
ant -Ddev.version.suffix=0L8e0UWtDs get-maven-poms

ant -Dversion=36433c00c4e02003c2c3bc702a0f65891a373244 get-maven-poms
ant -Ddev.version.suffix=36433c00c4e02003c2c3bc702a0f65891a373244 get-maven-poms

Steve

On Jan 29, 2014, at 10:07 AM, Steve Rowe <[hidden email]> wrote:

> See https://issues.apache.org/jira/browse/LUCENE-5420 - I put up a patch that fixes the issue for me. - Steve
>
> On Jan 28, 2014, at 3:10 PM, Steve Rowe <[hidden email]> wrote:
>
>> Ryan, I'll take a look today. - Steve
>>
>> On Jan 28, 2014 2:39 PM, "Ryan McKinley" <[hidden email]> wrote:
>> The real version number i was trying was:
>> -Dversion=4.7.r1562172M
>>
>> essentially a standard lucene build with a few chances.  Having the non-numbers in the version make it fail
>>
>> This used to work -- and now seems to fail only for lucene-analyzers-phonetic
>>
>> but i don't have any idea where to start!
>>
>> ryan
>>
>>
>> On Tue, Jan 28, 2014 at 9:30 AM, Uwe Schindler <[hidden email]> wrote:
>> You should not use a version like this to build artifacts, because it violates the Maven specs for versioning. You can define a custom version, but you have to prepend it with a valid Maven-version number, like:
>>
>>
>>
>> -Dversion=“4.6-my-special-version”
>>
>>
>>
>> Ideally do it like Jenkins with build number:
>>
>>
>>
>> -Ddev.version.suffix=”my-special-version”, which will produce the above version number with the 4.6 checkout.
>>
>>
>>
>> Uwe
>>
>>
>>
>> -----
>>
>> Uwe Schindler
>>
>> H.-H.-Meier-Allee 63, D-28213 Bremen
>>
>> http://www.thetaphi.de
>>
>> eMail: [hidden email]
>>
>>
>>
>> From: Ryan McKinley [mailto:[hidden email]]
>> Sent: Monday, January 27, 2014 11:41 PM
>> To: [hidden email]
>> Subject: maven build issues with non-numeric custom version
>>
>>
>>
>> From:
>>
>> http://svn.apache.org/repos/asf/lucene/dev/branches/branch_4x/dev-tools/maven/README.maven
>>
>>
>>
>> It says we can get a custom build number using:
>>
>> ant -Dversion=my-special-version get-maven-poms
>>
>>
>> but this fails with:
>>
>> BUILD FAILED
>> /Users/ryan/workspace/apache/lucene_4x/build.xml:141: The following error occurred while executing this line:
>> /Users/ryan/workspace/apache/lucene_4x/lucene/common-build.xml:1578: The following error occurred while executing this line:
>> /Users/ryan/workspace/apache/lucene_4x/lucene/tools/custom-tasks.xml:122: Malformed module dependency from 'lucene-analyzers-phonetic.internal.test.dependencies': 'lucene/build/analysis/common/lucene-analyzers-common-my-special-version.jar'
>>
>>
>> Using a numeric version number things work OK.
>>
>> Any ideas?
>>
>> ryan
>>
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]