jmini / Eclipse-Copyright-Generator

Fork of http://sourceforge.net/projects/eclipsecopyrigh/
Eclipse Public License 1.0
7 stars 12 forks source link

Installation from P2 repository fails due to conflicting dependency on `org.eclipse.help` #2

Closed mkrupcale closed 7 years ago

mkrupcale commented 7 years ago

On trying to use the new P2 repository https://dl.bintray.com/jmini/Eclipse-Copyright-Generator/ to install the Copyright Wizard plugin, it fails due to a conflicting dependency:

Cannot complete the install because of a conflicting dependency.
  Software being installed: Copyright Wizard 1.5.0 (com.wdev91.eclipse.copyright.feature.feature.group 1.5.0)
  Software currently installed: Eclipse Platform 4.6.2.v20170109-1424 (org.eclipse.platform.ide 4.6.2.v20170109-1424)
  Only one of the following can be installed at once: 
    Help System Core 3.7.0.v20160602-1307 (org.eclipse.help 3.7.0.v20160602-1307)
    Help System Core 3.7.0.v20170109-1424 (org.eclipse.help 3.7.0.v20170109-1424)
  Cannot satisfy dependency:
    From: Copyright Wizard 1.5.0 (com.wdev91.eclipse.copyright.feature.feature.group 1.5.0)
    To: org.eclipse.help [3.7.0.v20160602-1307]

I'm not sure if maybe in my PR I messed up the plugin/feature dependencies (I moved org.eclipse.help out of the plugin dependencies and into the feature), but it seems that com.wdev91.eclipse.copyright.feature wants an older version of org.eclipse.help than I currently have installed. I did not have this installation issue when I use a local installation through File -> Export -> Plug-in Development -> Deployable features, which might be because the exported plugin used the version of org.eclipse.help which I have.

I think then that I moved org.eclipse.help to the wrong part of com.wdev91.eclipse.copyright.feature/feature.xml: currently it is considered an "Included plug-in", whereas I think instead it should just be a "Dependency". To fix this, we probably need to delete

   <plugin
         id="org.eclipse.help"
         download-size="0"
         install-size="0"
         version="0.0.0"
         unpack="false"/>

from feature.xml and instead add something like

   <requires>
      <import plugin="org.eclipse.help"/>
   </requires>

I would make this change and submit a PR, but I don't really know how to test it with the different org.eclipse.help version (which I presume is what you built the plug-in with on your end and then uploaded to the P2 repository).

jmini commented 7 years ago

Thank you for reporting this issue!

I have built with:

Eclipse for RCP and RAP Developers Version: Neon.3 Release (4.6.3) Build id: 20170314-1500

And you are probabelly installing the plugin in an older version of the IDE. This is why it does not match.

I have tested my P2 repository with an other Eclipse installation but also Neon.3. This is why I did not see the problem.

Yes, I agree with you, org.eclipse.help should not be in the feature.

I think we should update the version to 1.5.1. Please do a pull request. I will also test it on my side. When it is merged, I will publish a new version on Bintray.

mkrupcale commented 7 years ago

Okay, I will fix that. I agree we should update the version to1.5.1, but should the version of the feature only be changed or the plug-in as well since there is not really any change to the plug-in?

jmini commented 7 years ago

Even if it is not required, I am in favor of using the same version everywhere: plugin project, feature project, site project, maven build for the docs. This help releasing a new version from this repository (tag, release notes, milestone for issues and code are in sync)

jmini commented 7 years ago

Thank you for your work, I have published the version 1.5.1 on bintray. I could install it in a Mars Version of Eclipse IDE and in an older Neon Version.

mkrupcale commented 7 years ago

No problem, this seems to have fixed the issue, and I was able to successfully install from the Bintray P2 repository.