Release with Maven 3.0.3 and Ranges: Referencing Snapshot-Versions
------------------------------------------------------------------

                 Key: MRELEASE-678
                 URL: http://jira.codehaus.org/browse/MRELEASE-678
             Project: Maven 2.x Release Plugin
          Issue Type: Bug
          Components: perform
    Affects Versions: 2.1
         Environment: Maven 3.0.3, java-6-sun 1.6.0_24, RHEL5
            Reporter: Christian Bittner


In the POM of the to be released project we reference dependencies by range as 
follows:

      <dependency>
        <groupId>sample</groupId>
        <artifactId>XYZ</artifactId>
        <version>[7.4.0, 7.4.9999]</version>
      </dependency>

Since the last Version of XYZ is a snapshot the maven-compiler-plugin classpath 
in the perform phase references this snapshot (Maven 3.0.3):

[INFO] [DEBUG]   (f) classpathElements = 
[/opt/mvn/hudson/workspace/RangeB/target/checkout/target/classes, 
/opt/mvn/.m2/repository/sample/XYZ/7.4.4-SNAPSHOT/XYZ-7.4.4-SNAPSHOT.jar, 
/opt/mvn/.m2/repository/commons-collections/commons-collections/3.2.1/commons-collections-3.2.1.jar,
 /opt/mvn/.m2/repository/log4j/log4j/1.2.15/log4j-1.2.15.jar, 
...

Snapshots MUST not be referenced in releases. The last released version 7.4.3 
of XYZ must be referenced instead.

Note: We know that this effect is caused by the broken range concept of maven. 
Nevertheless the release plugin seems to be the right plugin to report this, 
since releasing is senseless when it does not work properly.




-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to