Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API tool reports ficticious changes to execution environment #1301

Closed
ptziegler opened this issue Jun 14, 2024 · 4 comments · Fixed by #1302
Closed

API tool reports ficticious changes to execution environment #1301

ptziegler opened this issue Jun 14, 2024 · 4 comments · Fixed by #1302

Comments

@ptziegler
Copy link
Contributor

This is something that can be seen in the GEF workspace whenever we start a new release. A change in execution environment is reported for each bundle, even though the BREE hasn't been changed.

image

In short: The baseline bundles don't contain a Bundle-RequiredExecutionEnvironment header, but only a Required-Capability header.

Related to eclipse-equinox/equinox#643

@ptziegler
Copy link
Contributor Author

To briefly explain why this error shows up:

The API tool / PDE depends on the value returned by BundleDescription.getExecutionEnvironments(). When a bundle uses the Require-Capability but not the Bundle-RequireExecutionEnvironment header, this method returns an empty array.

The question is whether this should be fixed in PDE or in Equinox.

Given the documentation of this method, I believe that this behavior is wrong:

/**
 * Returns the list of execution environments that are required by this bundle.
 * Any one of the listed execution environments will allow this bundle to be
 * resolved.
 * 
 * @since 3.2
 * @return the list of execution environments that are required.
 */
public String[] getExecutionEnvironments();

@laeubi
Copy link
Contributor

laeubi commented Jun 14, 2024

@ptziegler please take into consideration that this is

  1. "deprecated" /legacy API
  2. maybe was before Require-Capability was adopted

so if you can fix it at Equinox, go for it there is not much that can get worse here, if its too hard and there is a quick-path at API tools do it but be aware that maybe other places call this method that the needs this fix as well.

@merks
Copy link
Contributor

merks commented Jun 14, 2024

FYI. I think the require capability can express a much more complex constraint than simply a list of EE. In any case, the list that PDE creates for this header really needs to match what equinox does for that same header.

@laeubi
Copy link
Contributor

laeubi commented Jun 14, 2024

Yes effectively you need a list of EEs that you can match against the req-capability...

ptziegler added a commit to ptziegler/eclipse.pde that referenced this issue Jun 20, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
ptziegler added a commit to ptziegler/eclipse.pde that referenced this issue Jun 20, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to HannesWell/eclipse.pde that referenced this issue Jun 27, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jun 27, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jun 28, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jun 28, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jun 28, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jun 29, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit to ptziegler/eclipse.pde that referenced this issue Jul 7, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
HannesWell pushed a commit that referenced this issue Jul 7, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves #1301
fedejeanne pushed a commit to fedejeanne/eclipse.pde that referenced this issue Jul 31, 2024
The API tool only checks the Bundle-RequiredExecutionEnvironment header
when comparing the baseline with the workspace bundle. If the EE of the
baseline bundle is described via the Require-Capability header, an empty
string is compared to the workspace EE, which is treated as an
incompatibility.

This also adds a simple test case where the execution environment of two
bundles is checked. One bundle uses the  Require-Capability, the other
one the Bundle-RequiredExecutionEnvironment header.

Resolves eclipse-pde#1301
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants