Community
Participate
Working Groups
Build Identifier: Tycho 0.13.0-SNAPSHOT With pomDependencies=consider, an eclipse-repository build fails to resolve a Maven snapshot bundle dependency. Apparently, Tycho gets confused about the SNAPSHOT vs. timestamp suffix for the p2 metadata files. Reproducible: Always Steps to Reproduce: - Unpack the attached sample project. - Use a profile which enables a snapshot repository: mvn -Pwicketstuff-snapshot clean install - The build fails with this message [INFO] --- tycho-p2-repository-plugin:0.13.0-SNAPSHOT:assemble-repository (default-assemble-repository) @ org.omadac.demo.site --- [WARNING] Mirror tool: "Messages while mirroring artifact descriptors.": ["Artifact not found: canonical: osgi.bundle,org.wicketstuff.bundle,1.5.0.SNAPSHOT."] - The snapshot artifact is now in the local repository, and repeating the build without the snapshot profile now succeeds: mvn clean install - To reproduce: rm -fr ~/.m2/repository/org/wicketstuff/wicketstuff-bundle/1.5-SNAPSHOT/, and start again.
Created attachment 199693 [details] Sample project to reproduce the problem
This is not nice: A build that fails the first time, but succeeds the second time. Thanks for the bug report - we'll look into it for 0.13
Fixed with 7a4b416 - a one-liner, but hard to find. @Igor: The fix was to replace Artifact.getVersion with Artifact.getBaseVersion. Neither method has any JavaDoc - are you aware of any unwanted effects this change could have?
(In reply to comment #3) > Fixed with 7a4b416 - a one-liner, but hard to find. > > @Igor: The fix was to replace Artifact.getVersion with Artifact.getBaseVersion. > Neither method has any JavaDoc - are you aware of any unwanted effects this > change could have? No, no side effects, the change is good. For snapshots, artifact base version is always the same 1.2.3-SNAPSHOT, while version gets expanded to a new value each time new snapshot is deployed (but it is still the same for locally installed artifacts and inside reactor). For releases, version and base version are always the same.