Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Test failure in I-build #55

Closed
akurtakov opened this issue Apr 29, 2022 · 4 comments · Fixed by #60
Closed

Test failure in I-build #55

akurtakov opened this issue Apr 29, 2022 · 4 comments · Fixed by #60
Assignees

Comments

@akurtakov
Copy link
Member

In the last few I-builds we have test failure:
https://download.eclipse.org/eclipse/downloads/drops4/I20220428-1800/testresults/html/org.eclipse.pde.ui.templates.tests_ep424I-unit-cen64-gtk3-java11_linux.gtk.x86_64_11.html

Generated product fails validation: [Missing Constraint: Import-Package: org.osgi.util.function; version="[1.0.0,2.0.0)", Missing Constraint: Require-Bundle: org.osgi.util.promise; bundle-version="[1.2.0,1.3.0)", Missing Constraint: Import-Package: org.osgi.util.promise; version="[1.0.0,2.0.0)", Missing Constraint: Require-Bundle: org.osgi.util.position; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.measurement; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.xml; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.function; bundle-version="[1.2.0,1.3.0)"]

java.lang.AssertionError: Generated product fails validation:
[Missing Constraint: Import-Package: org.osgi.util.function; version="[1.0.0,2.0.0)", Missing Constraint: Require-Bundle: org.osgi.util.promise; bundle-version="[1.2.0,1.3.0)", Missing Constraint: Import-Package: org.osgi.util.promise; version="[1.0.0,2.0.0)", Missing Constraint: Require-Bundle: org.osgi.util.position; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.measurement; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.xml; bundle-version="[1.0.0,1.1.0)", Missing Constraint: Require-Bundle: org.osgi.util.function; bundle-version="[1.2.0,1.3.0)"]
at org.junit.Assert.fail(Assert.java:89)
at org.eclipse.pde.ui.templates.tests.TestPDETemplates.validateProduct(TestPDETemplates.java:196)
at jdk.internal.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at org.junit.vintage.engine.execution.RunnerExecutor.execute(RunnerExecutor.java:42)
at org.junit.vintage.engine.VintageTestEngine.executeAllChildren(VintageTestEngine.java:80)
at org.junit.vintage.engine.VintageTestEngine.execute(VintageTestEngine.java:72)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:107)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:88)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:54)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:67)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:52)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:53)
at org.eclipse.test.EclipseTestRunner.runTests(EclipseTestRunner.java:226)
at org.eclipse.test.EclipseTestRunner.run(EclipseTestRunner.java:202)
at org.eclipse.test.UITestApplication.lambda$0(UITestApplication.java:103)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:40)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:185)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:5004)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4484)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1155)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:338)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1046)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:155)
at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:644)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:338)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:551)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:156)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:152)
at org.eclipse.test.UITestApplication.run(UITestApplication.java:48)
at org.eclipse.test.UITestApplication.start(UITestApplication.java:118)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:203)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:136)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:402)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:255)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:659)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:596)
at org.eclipse.equinox.launcher.Main.run(Main.java:1467)
at org.eclipse.equinox.launcher.Main.main(Main.java:1440)
at org.eclipse.core.launcher.Main.main(Main.java:44) 
@akurtakov
Copy link
Member Author

This looks closely related to recent changes to osgi.utils.

akurtakov added a commit to akurtakov/eclipse.pde.ui that referenced this issue Apr 29, 2022
* Stop using assertThat(message, variable equalTo(constant). It's just
complicated way to write assertEquals(message, constant, variable) which
even calls out to yet another library.
* Remove needless throws declaration.

Seen while investigating eclipse-pde#55

Change-Id: If4b7a6937a9ec9acac88e435c21c52f7e7e6f1d8
akurtakov added a commit that referenced this issue Apr 29, 2022
* Stop using assertThat(message, variable equalTo(constant). It's just
complicated way to write assertEquals(message, constant, variable) which
even calls out to yet another library.
* Remove needless throws declaration.

Seen while investigating #55

Change-Id: If4b7a6937a9ec9acac88e435c21c52f7e7e6f1d8
@HannesWell
Copy link
Member

This looks closely related to recent changes to osgi.utils.

Yes. From a quick first look it looks like the replacing bundles are not included into the launch config.
We can either add them or simply use the new "include required Plug-ins automatically".

I will have a look at this this evening.

@akurtakov
Copy link
Member Author

This looks closely related to recent changes to osgi.utils.

Yes. From a quick first look it looks like the replacing bundles are not included into the launch config. We can either add them or simply use the new "include required Plug-ins automatically".

If templates are not using "include required Plug-ins automatically" please adjust them to do so. We should do as much as possible to make people know of new automation and it being on by default for new projects.

HannesWell added a commit to HannesWell/eclipse.pde that referenced this issue Apr 29, 2022
With the latest changes in Equinox o.e.osgi.util was replaced by the
corresponding 'original' OSGi-reference bundles that are
required+reexported by o.e.osgi.util. Unfortunately the re-export does
not help in this product launch. Therefore o.e.osgi.util is replaced by
the actually needed plugins.

And apply one minor code improvement in TestPDETemplates

Fixes eclipse-pde#55
HannesWell added a commit to HannesWell/eclipse.pde that referenced this issue Apr 29, 2022
With the latest changes in Equinox o.e.osgi.util was replaced by the
corresponding 'original' OSGi-reference bundles that are
required+reexported by o.e.osgi.util. Unfortunately the re-export does
not help in this product launch. Therefore o.e.osgi.util is replaced by
the actually needed plug-ins.

And apply one minor code improvement in TestPDETemplates.

Fixes eclipse-pde#55
@HannesWell
Copy link
Member

For the record, as Aleks suspected this was was a side effect of by eclipse-equinox/equinox.framework#41

Yes. From a quick first look it looks like the replacing bundles are not included into the launch config. We can either add them or simply use the new "include required Plug-ins automatically".

If templates are not using "include required Plug-ins automatically" please adjust them to do so. We should do as much as possible to make people know of new automation and it being on by default for new projects.

Unfortunately we cannot use that yet because that only works on Launch-Config level. For product level this is almost completed in PR #7, but then the automatic inclusion of requirements can only be controlled in the IDE, not yet in a Tycho/Maven build (not sure if this is relevant for the template).

Nevertheless this template can really benefit from mixed-products for which I'm planning to add support to PDE soon (P2/Tycho already supports it for a while). I have already created a draft in PR #61 how it should look then.

HannesWell added a commit to HannesWell/eclipse.pde that referenced this issue Apr 29, 2022
With the latest changes in Equinox o.e.osgi.util was replaced by the
corresponding 'original' OSGi-reference bundles that are
required+reexported by o.e.osgi.util. Unfortunately the re-export does
not help in this product launch. Therefore o.e.osgi.util is replaced by
the actually needed plug-ins.

Fixes eclipse-pde#55
HannesWell added a commit to HannesWell/eclipse.pde that referenced this issue Apr 30, 2022
With the latest changes in Equinox o.e.osgi.util was replaced by the
corresponding 'original' OSGi-reference bundles that are
required+reexported by o.e.osgi.util. Unfortunately the re-export does
not help in this product launch. Therefore o.e.osgi.util is replaced by
the actually needed plug-ins.

And apply one minor code improvement in TestPDETemplates.

Fixes eclipse-pde#55
HannesWell added a commit that referenced this issue Apr 30, 2022
With the latest changes in Equinox o.e.osgi.util was replaced by the
corresponding 'original' OSGi-reference bundles that are
required+reexported by o.e.osgi.util. Unfortunately the re-export does
not help in this product launch. Therefore o.e.osgi.util is replaced by
the actually needed plug-ins.

And apply one minor code improvement in TestPDETemplates.

Fixes #55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants