Community
Participate
Working Groups
A feature can include other features, so says the feature.xml description. In this include-statement an option, "optional=true/false(default)" is mentioned, I tried that one like this: In a plain eclipse installation, if I remove the directory "features/org.eclipse.jdt.source..." and add an "optional" to the reference of this feature in the "sdk"-feature, an error is reported by the UM. Is this bug or feature?
Seems that the problem is in IncludedFeatureReference line 84: public IncludedFeatureReferenceModel(IFeatureReference featureReference) { super((FeatureReferenceModel)featureReference); isOptional(false); That line ignores the value of isOptional. WHY ?!
Any update on this? The line above should instead be along the lines of: if (featureReference instanceof IIncludedFeatureReference) isOptional( ((IIncludedFeatureReference)featureReference).isOptional() ); else isOptional(false);//?! may this happen?
will be fixed for 3.2.1
*** Bug 157481 has been marked as a duplicate of this bug. ***
When you apply the patch in comment #2, update manager allows you to continue in the wizard and select your feature. After a couple of pages you are prompted with a list of optional feature which you can de-select and proceed with the installation of your original feature. When Eclipse is restarted and you go to Help -> About -> Plug-in Details your new plug-ins are listed. When you go to Help -> About -> Feature Details your new feature is NOT listed. So it looks like the real fix for this problem is not only limited to this one class.
Created attachment 51572 [details] update site Sample update site that includes a feature with a reference to an optional (missing) feature.
Created attachment 51577 [details] update site Ignore my comment previously related to the Help -> About details. Update manager only adds features to this list which are considered to have branding. (that is, they have a bundle with the same identifier) Attached is a new update site which still exhibits the original problem, but the resulting features (when installed with the patch) appear in Help -> About.
Branko, is the code change described in comment #2 all that is needed to fix this bug? KevinH, please add your +1 as a PMC representative if you approve for fixing in the 3.2 maintenance stream.
this is in 3.2.2 stream and we have published a patch for 3.2.1.
Branko, can you also put in HEAD and version/release into 3.3 M4?
in the head
*** Bug 162523 has been marked as a duplicate of this bug. ***