Discussion:
Weird error when using p2-installable-unit
(too old to reply)
Max Rydahl Andersen
2011-11-26 10:54:39 UTC
Permalink
Hi,

Im trying to resolve an issue in our test runs where it works when we run with all optional dependencies in PDE but it fails when running without optional in PDE and equally so in Tycho.

In PDE I just need to add "org.eclipse.jdt.launching.macosx" to make the tests pass, but in Tycho that does not help and to top it off I'm getting a weird error:

I started trying to use:

<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>

But this give me this really weird error:

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]

I don't see anywhere where that "extra-1322304115336" is coming from ?

If I use:

<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>

It loads and the bundle is visible at runtime but i'm still getting test failures.


Thus three questions:

1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?

2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)

3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?

Any hints appreciated, thanks
/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-28 12:44:52 UTC
Permalink
See inline

--
Regards,
Igor
Post by Max Rydahl Andersen
Hi,
Im trying to resolve an issue in our test runs where it works when we run with all optional dependencies in PDE but it fails when running without optional in PDE and equally so in Tycho.
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?

[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).

This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Post by Max Rydahl Andersen
Any hints appreciated, thanks
/max
http://about.me/maxandersen
Max Rydahl Andersen
2011-11-28 13:31:35 UTC
Permalink
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?
[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Not yet - right now i'm just trying to run it on OSX - once I get it working I'll move it out to a profile.
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Yeah, I figured this out eventually when I noticed the number kept changing and then realized its java/unix timestamp.

One suggestion: Name that "extra-<timestamp>" something with tycho so one actually know that ? :)

diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundle
index 7ae582e..6484c13 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
@@ -195,7 +195,7 @@ public class ProjectorResolutionStrategy extends ResolutionStrategy {
if (!additionalRequirements.isEmpty()) {
InstallableUnitDescription iud = new MetadataFactory.InstallableUnitDescription();
String time = Long.toString(System.currentTimeMillis());
- iud.setId("extra-" + time);
+ iud.setId("tycho-extra-" + time);
iud.setVersion(Version.createOSGi(0, 0, 0, time));
iud.setRequirements(additionalRequirements.toArray(new IRequiredCapability[additionalRequirements.size()]));

(nontested patch ;)
Post by Igor Fedorenko
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).
This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Ok - cool.

But after digging some more it seem to be my target platform have "more" in it than I would like, i.e. currently i'm now getting:

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322486420857 0.0.0.1322486420857 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from org.eclipse.jdt.core 3.7.1.v_OTDT_r201_201109101025 to org.eclipse.objectteams.otdt.core.patch.feature.group [2.0.0,3.0.0).", "Unable to satisfy dependency from 1322486420872 0.0.0.1322486420872 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]


So I somehow got org.eclipse.objectteams.otdt.* into the target platform - which is really weird.

What could help me is someway to actually see the list of bundles that are *in* the target platform after Tycho done its resolution stuff.

Is there available somewhere ? -X does not seem to print it out.

And I can't spot anything in target/work/* directory.

Is that information stored somewhere?

/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-28 14:40:17 UTC
Permalink
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.

I've seen org.eclipse.objectteams.otdt.* before. It is claims to be a
JDT feature patch or something like that. I can't remember what I
decided was that right way to do with it. If you can provide a sample
project that shows the problem I will have a look.

--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?
[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Not yet - right now i'm just trying to run it on OSX - once I get it working I'll move it out to a profile.
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Yeah, I figured this out eventually when I noticed the number kept changing and then realized its java/unix timestamp.
One suggestion: Name that "extra-<timestamp>" something with tycho so one actually know that ? :)
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundle
index 7ae582e..6484c13 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
@@ -195,7 +195,7 @@ public class ProjectorResolutionStrategy extends ResolutionStrategy {
if (!additionalRequirements.isEmpty()) {
InstallableUnitDescription iud = new MetadataFactory.InstallableUnitDescription();
String time = Long.toString(System.currentTimeMillis());
- iud.setId("extra-" + time);
+ iud.setId("tycho-extra-" + time);
iud.setVersion(Version.createOSGi(0, 0, 0, time));
iud.setRequirements(additionalRequirements.toArray(new IRequiredCapability[additionalRequirements.size()]));
(nontested patch ;)
Post by Igor Fedorenko
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).
This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Ok - cool.
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322486420857 0.0.0.1322486420857 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from org.eclipse.jdt.core 3.7.1.v_OTDT_r201_201109101025 to org.eclipse.objectteams.otdt.core.patch.feature.group [2.0.0,3.0.0).", "Unable to satisfy dependency from 1322486420872 0.0.0.1322486420872 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
So I somehow got org.eclipse.objectteams.otdt.* into the target platform - which is really weird.
What could help me is someway to actually see the list of bundles that are *in* the target platform after Tycho done its resolution stuff.
Is there available somewhere ? -X does not seem to print it out.
And I can't spot anything in target/work/* directory.
Is that information stored somewhere?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Max Rydahl Andersen
2011-11-28 15:02:54 UTC
Permalink
Post by Igor Fedorenko
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.

I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
Post by Igor Fedorenko
I've seen org.eclipse.objectteams.otdt.* before. It is claims to be a
JDT feature patch or something like that.
Yes, its evil.
Post by Igor Fedorenko
I can't remember what I
decided was that right way to do with it. If you can provide a sample
project that shows the problem I will have a look.
right now its inside jboss tools (ws/tests/org.jboss.tools.ws.jaxrs.core.test) so don't have a "minimized" version of it yet.

/max
Post by Igor Fedorenko
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?
[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Not yet - right now i'm just trying to run it on OSX - once I get it working I'll move it out to a profile.
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Yeah, I figured this out eventually when I noticed the number kept changing and then realized its java/unix timestamp.
One suggestion: Name that "extra-<timestamp>" something with tycho so one actually know that ? :)
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundle
index 7ae582e..6484c13 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
@@ -195,7 +195,7 @@ public class ProjectorResolutionStrategy extends ResolutionStrategy {
if (!additionalRequirements.isEmpty()) {
InstallableUnitDescription iud = new MetadataFactory.InstallableUnitDescription();
String time = Long.toString(System.currentTimeMillis());
- iud.setId("extra-" + time);
+ iud.setId("tycho-extra-" + time);
iud.setVersion(Version.createOSGi(0, 0, 0, time));
iud.setRequirements(additionalRequirements.toArray(new IRequiredCapability[additionalRequirements.size()]));
(nontested patch ;)
Post by Igor Fedorenko
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).
This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Ok - cool.
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322486420857 0.0.0.1322486420857 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from org.eclipse.jdt.core 3.7.1.v_OTDT_r201_201109101025 to org.eclipse.objectteams.otdt.core.patch.feature.group [2.0.0,3.0.0).", "Unable to satisfy dependency from 1322486420872 0.0.0.1322486420872 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
So I somehow got org.eclipse.objectteams.otdt.* into the target platform - which is really weird.
What could help me is someway to actually see the list of bundles that are *in* the target platform after Tycho done its resolution stuff.
Is there available somewhere ? -X does not seem to print it out.
And I can't spot anything in target/work/* directory.
Is that information stored somewhere?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-28 15:23:00 UTC
Permalink
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId

http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java

--
Regards,
Igor
Max Rydahl Andersen
2011-11-28 15:32:00 UTC
Permalink
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!

Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.

With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?

/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-28 17:11:48 UTC
Permalink
You should see way more logs

For p2 you should see entire resolver data flow, separately for each
os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
* Root IUs: shows project installable unit(s)
* Extra IUs: shows installable units generated from <dependency/>
elements
* Slice: shows installable units "reachable" from the root and extra IUs
* Resolved IUs: shows IUs after resolving all conflicts and duplicates


For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see

--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Max Rydahl Andersen
2011-11-29 00:45:30 UTC
Permalink
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from <dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(

I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.

Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(

I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Igor Fedorenko
2011-11-29 02:10:18 UTC
Permalink
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )


[INFO] Cannot complete the request. Generating details.
[INFO]
{org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1,
osgi.ws=win32, osgi.arch=x86, osgi.os=win32,
org.eclipse.update.install.features=true,
org.osgi.framework.system.packages=}
[ERROR] Cannot resolve project dependencies:
[ERROR] You requested to install 'bundle
org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be
found


Try adding the following to your test project pom.xml (insert <version>,
if you don't have corresponding <pluginManagement>).


<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>


This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.

--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Alex Blewitt
2011-11-29 07:13:44 UTC
Permalink
Post by Igor Fedorenko
Tycho
should only resolve test runtime for the current system's os/ws/arch.
I think this is a good idea to default to. You can't install/test fragments for anything other than your current os/ws/arch in any case, even if you go on to build a repository for all platforms.

Alex
Max Rydahl Andersen
2011-11-29 11:51:25 UTC
Permalink
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert <version>,
if you don't have corresponding <pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
When I do that I get:

!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more

If I actually go and physically remove the other target platforms in my parent:

<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>


Then it works!

That is just weird because we got other stuff that is os specific.

/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-29 16:26:00 UTC
Permalink
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).

For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090

--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
…
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Max Rydahl Andersen
2011-11-29 17:11:54 UTC
Permalink
Post by Igor Fedorenko
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
I can confirm that your example project works for me as discussed here.

trying to see if I can figure out why it doesn't work for my project.

/max
Post by Igor Fedorenko
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Max Rydahl Andersen
2011-11-29 18:47:05 UTC
Permalink
every attempt I do on this causes SWT errors for me when running the tests.

I'm lost :(

/max
Post by Igor Fedorenko
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-29 18:50:34 UTC
Permalink
Can you attach -X -Dtycho.debug.resolver=<artufactId> log for the SWT
failure?

--
Regards,
Igor
Post by Max Rydahl Andersen
every attempt I do on this causes SWT errors for me when running the tests.
I'm lost :(
/max
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Max Rydahl Andersen
2011-11-29 19:46:53 UTC
Permalink
Can you attach -X -Dtycho.debug.resolver=<artufactId> log for the SWT failure?
with pleasure. see attached.

output from running:
mvn integration-test -X -Dtycho.debug.resolver=org.jboss.tools.ws.jaxrs.core.test > swterror.log
Max Rydahl Andersen
2011-11-29 19:48:06 UTC
Permalink
just realized that we put -d32 to ensure it uses 32bit jam for testing, but maybe the platform configuration
sees we are running 64bit and resolves against that ?

/max
Can you attach -X -Dtycho.debug.resolver=<artufactId> log for the SWT failure?
--
Regards,
Igor
Post by Max Rydahl Andersen
every attempt I do on this causes SWT errors for me when running the tests.
I'm lost :(
/max
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Max Rydahl Andersen
2011-11-29 19:57:01 UTC
Permalink
Post by Max Rydahl Andersen
just realized that we put -d32 to ensure it uses 32bit jam for testing, but maybe the platform configuration
sees we are running 64bit and resolves against that ?
So I removed the -d32 and arch poperty and now it starts up (hinting its running via 64bit but now
the launcher.macosx is not being installed resulting in failure.

Feel there is some combo that should work …. just not finding it.
/max
Post by Max Rydahl Andersen
/max
Can you attach -X -Dtycho.debug.resolver=<artufactId> log for the SWT failure?
--
Regards,
Igor
Post by Max Rydahl Andersen
every attempt I do on this causes SWT errors for me when running the tests.
I'm lost :(
/max
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)

at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
/max
http://about.me/maxandersen
Igor Fedorenko
2011-11-29 20:52:42 UTC
Permalink
I am able to reproduce the SWT failure with -d32. Attached modified
sample projects fixes this too (note os/ws/arch properties *and*
target-platform-configuration under osx profile).

Let me know if this fixes your build.

--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Max Rydahl Andersen
just realized that we put -d32 to ensure it uses 32bit jam for testing, but maybe the platform configuration
sees we are running 64bit and resolves against that ?
So I removed the -d32 and arch poperty and now it starts up (hinting its running via 64bit but now
the launcher.macosx is not being installed resulting in failure.
Feel there is some combo that should work …. just not finding it.
/max
Post by Max Rydahl Andersen
/max
Can you attach -X -Dtycho.debug.resolver=<artufactId> log for the SWT failure?
--
Regards,
Igor
Post by Max Rydahl Andersen
every attempt I do on this causes SWT errors for me when running the tests.
I'm lost :(
/max
<environments combine.self="override"> workaround works for the small
example project I setup (see attached).
For the proper solution I've opened
https://bugs.eclipse.org/bugs/show_bug.cgi?id=365090
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Looks like your build has multiple os/ws/arch configured and resolution
fails when trying to resolve for win32/win32/x86 combo. Here is the
relevant log message (from right above the error ;-) )
Couldn't see the forrest for trees.
Post by Igor Fedorenko
[INFO] Cannot complete the request. Generating details.
[INFO] {org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=win32, osgi.arch=x86, osgi.os=win32, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[ERROR] You requested to install 'bundle org.eclipse.jdt.launching.macosx 3.2.100.v20110509' but it could not be found
Try adding the following to your test project pom.xml (insert<version>,
if you don't have corresponding<pluginManagement>).
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<environments combine.self="override">
</environments>
</configuration>
</plugin>
</plugins>
</build>
!ENTRY org.eclipse.osgi 4 0 2011-11-29 12:47:59.109
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (147).
!STACK 0
org.osgi.framework.BundleException: The activator org.eclipse.ui.internal.WorkbenchPlugin for bundle org.eclipse.ui.workbench is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
…
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:166)
... 34 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tychoVersion}</version>
<configuration>
<resolver>p2</resolver>
<ignoreTychoRepositories>true</ignoreTychoRepositories>
<environments>
<environment>
<os>macosx</os>
<ws>cocoa</ws>
<arch>x86</arch>
</environment>
</environments>
</configuration>
</plugin>
Then it works!
That is just weird because we got other stuff that is os specific.
/max
Post by Igor Fedorenko
This should tell Tycho to only resolve test project's dependencies for
the current os/ws/arch. If this helps, please open a bugreport, Tycho
should only resolve test runtime for the current system's os/ws/arch.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
You should see way more logs
Yeah, I got it now.
Post by Igor Fedorenko
For p2 you should see entire resolver data flow, separately for each os/ws/arch combo enabled in target resolver configuration
* Available IUs: shows all installable units visible to the project
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Root IUs: shows project installable unit(s)
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Extra IUs: shows installable units generated from<dependency/>
elements
Yes, launching.macosx is listed here
Post by Igor Fedorenko
* Slice: shows installable units "reachable" from the root and extra IUs
its not listed here and then I get the error about it being non resolvable with no explanation ;(
I've taken the liberty to attach my raw log file for the output in case you can spot anything out of the ordinary.
Note, i've got rid of the object team feature problem so now i'm just trying to grok why it won't install this plugin ;(
I also tried the trick about only enabling it conditionally in a profile but when I did that it never gets attempted to be installed (which surprises me)
Post by Igor Fedorenko
* Resolved IUs: shows IUs after resolving all conflicts and duplicates
For equinox
* Resolved OSGi state: resolved OSGi state, i.e. RESOLVED lines you see
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
Okey, I'll try see what that will give me.
I looked in the code and I couldn't find a place where tycho.debug.resolver was used for anything beyond a boolean flag.
Where is the artifactid taken into account ?
DebugUtils checks for project artifactId
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/DebugUtils.java
Ah gothca!
Thought you mean tycho.debug.resolver=<pluginid> so I had tycho.debug.resolver=org.eclipse.jdt.launching.macosx and saw no diff output.
With tycho.debug.resolver=<my project artifactid> I get a lot of RESOLVED: lines - I assume that is what you referenced to?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
<multienv.zip>_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Alex Blewitt
2011-11-28 15:05:34 UTC
Permalink
The JDT objectstream issue is known (see bug 350133). Basically, if you install JDT then that gets sucked in as well. The only way it doesn't is if you install (say) SDK or PDE which has a transitive dependency on JDT - in which case it doesn't prompt you to update the feature.

Alex

Sent from my iPhone 4S
Post by Igor Fedorenko
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
I've seen org.eclipse.objectteams.otdt.* before. It is claims to be a
JDT feature patch or something like that. I can't remember what I
decided was that right way to do with it. If you can provide a sample
project that shows the problem I will have a look.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?
[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Not yet - right now i'm just trying to run it on OSX - once I get it working I'll move it out to a profile.
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Yeah, I figured this out eventually when I noticed the number kept changing and then realized its java/unix timestamp.
One suggestion: Name that "extra-<timestamp>" something with tycho so one actually know that ? :)
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundle
index 7ae582e..6484c13 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
@@ -195,7 +195,7 @@ public class ProjectorResolutionStrategy extends ResolutionStrategy {
if (!additionalRequirements.isEmpty()) {
InstallableUnitDescription iud = new MetadataFactory.InstallableUnitDescription();
String time = Long.toString(System.currentTimeMillis());
- iud.setId("extra-" + time);
+ iud.setId("tycho-extra-" + time);
iud.setVersion(Version.createOSGi(0, 0, 0, time));
iud.setRequirements(additionalRequirements.toArray(new IRequiredCapability[additionalRequirements.size()]));
(nontested patch ;)
Post by Igor Fedorenko
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).
This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Ok - cool.
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322486420857 0.0.0.1322486420857 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from org.eclipse.jdt.core 3.7.1.v_OTDT_r201_201109101025 to org.eclipse.objectteams.otdt.core.patch.feature.group [2.0.0,3.0.0).", "Unable to satisfy dependency from 1322486420872 0.0.0.1322486420872 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
So I somehow got org.eclipse.objectteams.otdt.* into the target platform - which is really weird.
What could help me is someway to actually see the list of bundles that are *in* the target platform after Tycho done its resolution stuff.
Is there available somewhere ? -X does not seem to print it out.
And I can't spot anything in target/work/* directory.
Is that information stored somewhere?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Max Rydahl Andersen
2011-11-28 15:26:47 UTC
Permalink
grrrr….so the only way around this is to depend on a *very* specific version in the target platform ?

/max
Post by Alex Blewitt
The JDT objectstream issue is known (see bug 350133). Basically, if you install JDT then that gets sucked in as well. The only way it doesn't is if you install (say) SDK or PDE which has a transitive dependency on JDT - in which case it doesn't prompt you to update the feature.
Alex
Sent from my iPhone 4S
Post by Igor Fedorenko
Running the build with -X -Dtycho.debug.resolver=<artifactId> will
provide detailed information about dependency resolution, starting with
all installable units visible to the project.
I've seen org.eclipse.objectteams.otdt.* before. It is claims to be a
JDT feature patch or something like that. I can't remember what I
decided was that right way to do with it. If you can provide a sample
project that shows the problem I will have a look.
--
Regards,
Igor
Post by Max Rydahl Andersen
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>p2-installable-unit</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322304115336 0.0.0.1322304115336 to org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from 1322304115347 0.0.0.1322304115347 to org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
I don't see anywhere where that "extra-1322304115336" is coming from ?
What environment(s) do you run the tests on? Did you put
o.e.jdt.launching.macosx test dependency in OSX-specific profile, like
we did for m2e tests [1]?
[1] https://github.com/sonatype/m2e-core-tests/blob/master/pom.xml
Not yet - right now i'm just trying to run it on OSX - once I get it working I'll move it out to a profile.
Post by Igor Fedorenko
Post by Max Rydahl Andersen
<dependency>
<type>eclipse-fragment</type>
<artifactId>org.eclipse.jdt.launching.macosx</artifactId>
<version>0.0.0</version>
</dependency>
It loads and the bundle is visible at runtime but i'm still getting test failures.
1) Why is Tycho complaining with that error ? it also seem to happen when I just add it to even basic tests with no extra dependencies.
…or at least any tip on debugging where it is finding extra-* references?
extra-* is an internal installable unit tycho generates to represent
<dependency/> elements. Just ignore it.
Yeah, I figured this out eventually when I noticed the number kept changing and then realized its java/unix timestamp.
One suggestion: Name that "extra-<timestamp>" something with tycho so one actually know that ? :)
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundle
index 7ae582e..6484c13 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
@@ -195,7 +195,7 @@ public class ProjectorResolutionStrategy extends ResolutionStrategy {
if (!additionalRequirements.isEmpty()) {
InstallableUnitDescription iud = new MetadataFactory.InstallableUnitDescription();
String time = Long.toString(System.currentTimeMillis());
- iud.setId("extra-" + time);
+ iud.setId("tycho-extra-" + time);
iud.setVersion(Version.createOSGi(0, 0, 0, time));
iud.setRequirements(additionalRequirements.toArray(new IRequiredCapability[additionalRequirements.size()]));
(nontested patch ;)
Post by Igor Fedorenko
Post by Max Rydahl Andersen
2) Any tips on tracking down which optional dependencies that are magically missing ? (eclipse got about 71 plugins marked as optional so its like looking for a needle in a haystack)
3) Is there any way for a test run to enable "get all the optional dependencies" so it simulates what happens in PDE when launching with "all optional" ? At least so I can verify it actually works
in Tycho too when "everything" is installed ?
Not possible now, but in 0.14 there will be resolver flag that will let
you choose between forcing all optional dependencies as required or
ignoring them altogether (in the latter case it will still be possible
to add specific dependencies back).
This support is currently implemented on 351842_optionalDependencies
branch, waiting for my p2 patches to be reviewed and applied.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351842
Ok - cool.
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test (default-test) on project org.jboss.tools.ws.jaxrs.core.test: Execution default-test of goal org.eclipse.tycho:tycho-surefire-plugin:0.13.0:test failed: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from extra-1322486420857 0.0.0.1322486420857 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "Unable to satisfy dependency from org.eclipse.jdt.core 3.7.1.v_OTDT_r201_201109101025 to org.eclipse.objectteams.otdt.core.patch.feature.group [2.0.0,3.0.0).", "Unable to satisfy dependency from 1322486420872 0.0.0.1322486420872 to bundle org.eclipse.jdt.launching.macosx 0.0.0.", "No solution found because the problem is unsatisfiable."] -> [Help 1]
So I somehow got org.eclipse.objectteams.otdt.* into the target platform - which is really weird.
What could help me is someway to actually see the list of bundles that are *in* the target platform after Tycho done its resolution stuff.
Is there available somewhere ? -X does not seem to print it out.
And I can't spot anything in target/work/* directory.
Is that information stored somewhere?
/max
http://about.me/maxandersen
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
/max
http://about.me/maxandersen
Continue reading on narkive:
Loading...