tycho-versions-plugin for 4.0.9 fails with "missing class"
We get the following error while trying to use set-version:
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-versions-plugin:4.0.9:set-version (default-cli) on project parent: Execution default-cli of goal org.eclipse.tycho:tycho-versions-plugin:4.0.9:set-version failed: A required class was missing while executing org.eclipse.tycho:tycho-versions-plugin:4.0.9:set-version: org/eclipse/tycho/model/manifest/MutableBundleManifest
Specific way that we call it:
./mvnw -Dtycho.mode=maven org.eclipse.tycho:tycho-versions-plugin:set-version -DnewVersion=$VERSION-SNAPSHOT
(see https://github.com/eclipse/lsp4mp/blob/f3628e2bc9521d8507c7125ca3e9915f34b567ea/Release.Jenkinsfile#L30)
The 4.0.8 version of the plugin works
I get the same error.
Working command:
mvn versions:update-parent -DgenerateBackupPoms=false org.eclipse.tycho:tycho-versions-plugin:4.0.8:set-version -DnewVersion="12.1.0-SNAPSHOT"
Not working:
mvn versions:update-parent -DgenerateBackupPoms=false org.eclipse.tycho:tycho-versions-plugin:4.0.9:set-version -DnewVersion="12.1.0-SNAPSHOT"
I cannot reproduce this.
git clone https://github.com/eclipse/lsp4mp.git
cd lsp4mp/microprofile.jdt
mvn org.eclipse.tycho:tycho-versions-plugin:4.0.9:set-version -DnewVersion=1.2.3-SNAPSHOT
works perfectly fine here.
Can you run with -e and give some information about your environment (java version, etc.)?
Just some notes
-Dtycho.mode=mavenis not supported anymore, you should avoid using that- when changing Tycho versions I noticed it is sometimes required to pass
-Uto force maven to really download everything required. - If you are using a different version in your build it can become a problem for CLI invocations, so make sure that the project uses the same tycho version as well as the extensions.xml (if used).
If you are using a different version in your build it can become a problem for CLI invocations
This was the issue. We were using a 3.y.z version of Tycho for the build, but we didn't specify the version of the tycho-versions-plugin to use, so I'm guessing it pulled in the latest. @rgrunber made a change to update to Tycho 4.0.9 for the build, so now (as @sratz pointed out) running tycho-versions-plugin 4.0.9 on the command line works: https://github.com/eclipse/lsp4mp/commit/7ca4b44ee566643e8e5c32e632e14d2bd2a22240#diff-a8cdf9ab5d54b6694c54edd69c5b02dbcb9d047c63d492cfe2ee7160063dd918R13
Thanks for your help and sorry for the noise!