[jira] (MNG-3092) Version ranges with non-snapshot bounds can contain snapshot versions
[ https://jira.codehaus.org/browse/MNG-3092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=301225#comment-301225 ] Kristoffer Peterhansel commented on MNG-3092: - Like [~soeren.chittka] and [~herder] said. It makes no sense for the pre-release version of an excluded version to be included in the build. Just had to work around this myself with using a very high (sub next major) version for the range boundary. > Version ranges with non-snapshot bounds can contain snapshot versions > - > > Key: MNG-3092 > URL: https://jira.codehaus.org/browse/MNG-3092 > Project: Maven 2 & 3 > Issue Type: Bug > Components: Dependencies >Reporter: Mark Hobson > Attachments: MNG-3092.patch > > > Contrary to the 2.0 design docs: > "Resolution of dependency ranges should not resolve to a snapshot > (development version) unless it is included as an explicit boundary." > -- from > http://docs.codehaus.org/display/MAVEN/Dependency+Mediation+and+Conflict+Resolution#DependencyMediationandConflictResolution-Incorporating%7B%7BSNAPSHOT%7D%7Dversionsintothespecification > The following is equates to true: > VersionRange.createFromVersionSpec( "[1.0,1.1]" ).containsVersion( new > DefaultArtifactVersion( "1.1-SNAPSHOT" ) ) > The attached patch only allows snapshot versions to be contained in a range > if they are equal to one of the boundaries. Note that this is a strict > equality, so [1.0,1.2-SNAPSHOT] will not contain 1.1-SNAPSHOT. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MNG-5006) M3 attempts to get released parent pom from snapshot repository when a dependency has range
[ http://jira.codehaus.org/browse/MNG-5006?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=257422#action_257422 ] Kristoffer Peterhansel commented on MNG-5006: - Nice work. Didn't think it would be so easy to reproduce =) Instead of cleaning the repo you can just use another one. Running Maven on these projects with an option like "-Dmaven.repo.local=..\repo" will do it for me. > M3 attempts to get released parent pom from snapshot repository when a > dependency has range > --- > > Key: MNG-5006 > URL: http://jira.codehaus.org/browse/MNG-5006 > Project: Maven 2 & 3 > Issue Type: Bug >Affects Versions: 3.0.2 > Environment: WinXP SP3, Java 6u20 >Reporter: Kristoffer Peterhansel > Attachments: maven-version-range-test.zip, > maven-version-range-test2.zip, mvn-verify-fixed-version.log, > mvn-verify-offline.log, mvn-verify-range-version.log > > > I have a bit of a strange issue. When running under Maven 3.0.2 I am getting > build errors when I try to build one of our projects when one of their > dependencies have a range version. But when setting it to a specific version > it seems to work. The same project works without a hitch in Maven 2.2.1. > As can be seen from the first included verbose trace > (mvn-verify-range-version.log). Maven attempts to get the pom from our > snapshot repository. That will, obviously, not work for a released artefact. > Changing the dependency version from the [1,2) range to 1.0.1-SNAPSHOT seems > to skip that step completely. Even though it resolves to the same version in > the end. As seen in the other verbose trace (mvn-verify-fixed-version.log) -- 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