Community
Participate
Working Groups
Scenario: Feature A (feature) Feature Patch for A (feature.patch) Feature B (feature.combine) that requires feature and feature.patch Error: $ mvn package [ERROR] Cannot resolve project dependencies: [ERROR] Software being installed: feature.combine.feature.group 1.0.0 [ERROR] Only one of the following can be installed at once: [org.eclipse.osgi 3.5.2.R35x_v20100126, org.eclipse.osgi 3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.combine.feature.group 1.0.0 depends on: feature.feature.group 0.0.0 [ERROR] Cannot satisfy dependency: feature.combine.feature.group 1.0.0 depends on: feature.patch.feature.group 0.0.0 [ERROR] Cannot satisfy dependency: feature.feature.group 1.0.0 depends on: org.eclipse.osgi [3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.patch.feature.group 1.0.0 depends on: org.eclipse.osgi [3.5.2.R35x_v20100126] [ERROR] I have attached a sample project that demonstrates the problem based on tycho-its/featurePatch.build.
Created attachment 214076 [details] demo project
Any thoughts where we should start looking in order to enable building features that include a feature along with a feature patch?
From the p2 error message, I would assume that it would not be possible to install the feature.combine if it was built. So what would you need the feature.combine for?
We are building a similar project with PDE build and AFAIK the combined feature is installable. Unfortunately I'm unable to produce a repository with Tycho since a repository build is failing with a similar error even though this should result in a sensible repository: [INFO] Resolving dependencies of MavenProject: 348326featurePatch:repository:1.0.0 @ /stuff/tmp/featurePatch.build/repository/pom.xml [INFO] Cannot complete the request. Generating details. [INFO] Cannot complete the request. Generating details. [INFO] {osgi.ws=gtk, osgi.os=linux, osgi.arch=x86_64, org.eclipse.update.install.features=true} [ERROR] Cannot resolve project dependencies: [ERROR] Software being installed: repository 1.0.0 [ERROR] Only one of the following can be installed at once: [org.eclipse.osgi 3.5.2.R35x_v20100126, org.eclipse.osgi 3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.feature.group 1.0.0 depends on: org.eclipse.osgi [3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.patch.feature.group 1.0.0 depends on: org.eclipse.osgi [3.5.2.R35x_v20100126] [ERROR] Cannot satisfy dependency: repository 1.0.0 depends on: feature.feature.group 0.0.0 [ERROR] Cannot satisfy dependency: repository 1.0.0 depends on: feature.patch.feature.group 0.0.0 I didn't see any tests in the tycho repository that handle scenarios for distributing feature patches. Do you know to what extend feature patches are supported?
Looking into this further I'm not able to build a repository with a category.xml as simple as this: <site> <feature id="feature.patch"/> </site> The error is: [ERROR] Cannot resolve project dependencies: [ERROR] Software being installed: repository.patch 1.0.0 [ERROR] Missing requirement: feature.patch.feature.group 1.0.0 requires 'feature.feature.group 0.0.0' but it could not be found [ERROR] Cannot satisfy dependency: repository.patch 1.0.0 depends on: feature.patch.feature.group 0.0.0 With a category.xml that includes both: <site> <feature id="feature"/> <feature id="feature.patch"/> </site> The error is: [ERROR] Cannot resolve project dependencies: [ERROR] Software being installed: repository.both 1.0.0 [ERROR] Only one of the following can be installed at once: [org.eclipse.osgi 3.5.2.R35x_v20100126, org.eclipse.osgi 3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.feature.group 1.0.0 depends on: org.eclipse.osgi [3.4.3.R34x_v20081215-1030] [ERROR] Cannot satisfy dependency: feature.patch.feature.group 1.0.0 depends on: org.eclipse.osgi [3.5.2.R35x_v20100126] [ERROR] Cannot satisfy dependency: repository.both 1.0.0 depends on: feature.feature.group 0.0.0 [ERROR] Cannot satisfy dependency: repository.both 1.0.0 depends on: feature.patch.feature.group 0.0.0
The only way I have been able to get at least one step further was by setting <deployableFeature>true</deployableFeature> which then actually creates a repository for the feature.patch feature. If I create an eclipse-repository project that consumes the deployed features as repositories I'm able to build a site that has feature and feature.patch. pom.xml: <repositories> <repository> <id>feature</id> <url>file:../feature/target/site</url> <layout>p2</layout> </repository> <repository> <id>feature.patch</id> <url>file:../feature.patch/target/site</url> <layout>p2</layout> </repository> </repositories> category.xml: <site> <feature id="feature"/> <feature id="feature.patch"/> </site> It seems weird that it makes a difference whether dependencies come from p2 repositories or the reactor. The build repository is not complete though, it is missing the bundle included in feature: $ find repository.mirror/target/repository repository.mirror/target/repository repository.mirror/target/repository/artifacts.jar repository.mirror/target/repository/plugins repository.mirror/target/repository/plugins/org.eclipse.osgi_3.5.2.R35x_v20100126.jar repository.mirror/target/repository/features repository.mirror/target/repository/features/feature_1.0.0.jar repository.mirror/target/repository/features/feature.patch_1.0.0.jar repository.mirror/target/repository/content.jar The publisher does warn about that during the build: [INFO] --- tycho-p2-repository-plugin:0.15.0:assemble-repository (default-assemble-repository) @ repository --- [WARNING] Mirror tool: "Problems resolving provisioning plan.": ["Unable to satisfy dependency from feature.feature.group 1.0.0 to org.eclipse.osgi [3.4.3.R34x_v20081215-1030]."] [WARNING] More information on the preceding warning(s) can be found here: [WARNING] - http://wiki.eclipse.org/Tycho_Messages_Explained#Mirror_tool
Created attachment 216756 [details] updated demo project
This is related to bug 378794 which describes the problem in comment 6 in more detail.
Eclipse Tycho is moving away from this bugs.eclipse.org issue tracker to https://github.com/eclipse/tycho/issues/ instead. If this issue is relevant to you, your action is required. 0. Verify this issue is still happening with latest Tycho 2.4.0-SNAPSHOT if issue has disappeared, please change status of this issue to "CLOSED WORKFORME" with some details about your testing environment and how you did verify the issue; and you're done if issue is still present when latest release: * Create a new issue at https://github.com/eclipse/tycho/issues/ ** Use as title in GitHub the title of this Bugzilla ticket (may include the bug number or not, at your own convenience) ** In the GitHub description, start with a link to this bugzilla ticket ** Optionally add new content to the description if it can helps towards resolution ** Submit GitHub issue * Update bugzilla ticket ** Add to "See also" property (up right column) the link to the newly created GitHub issue ** Add a comment "Migrated to <link-to-newly-created-GitHub-issue>" ** Set status as CLOSED MOVED ** Submit All issues that remain open will be automatically closed next week or so. Then the Bugzilla component for Tycho will be archived and made read-only.