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

!! Tests DNF since I20230614-2220 #278

Closed
jukzi opened this issue Jun 15, 2023 · 10 comments · Fixed by #279
Closed

!! Tests DNF since I20230614-2220 #278

jukzi opened this issue Jun 15, 2023 · 10 comments · Fixed by #279
Assignees
Labels
bug Something isn't working regression
Milestone

Comments

@jukzi
Copy link
Contributor

jukzi commented Jun 15, 2023

Caused by: java.lang.NullPointerException: Cannot invoke "org.eclipse.core.runtime.IPath.removeTrailingSeparator()" because "path" is null
at org.eclipse.core.internal.resources.Resource.<init>(Resource.java:49)
at org.eclipse.core.internal.resources.Container.<init>(Container.java:30)
at org.eclipse.core.internal.resources.WorkspaceRoot.<init>(WorkspaceRoot.java:41)

locally reproducable with org.eclipse.core.tests.resources.AutomatedResourceTests on WIN that
org.eclipse.core.runtime.Path.ROOT == null
while
org.eclipse.core.runtime.IPath.ROOT== "/"

@HannesWell probably related to
#277

@jukzi
Copy link
Contributor Author

jukzi commented Jun 15, 2023

I dont't see an obvious error in the commit but reverting 277 solves the issue. Probably some sort of initialization order problem.

@iloveeclipse
Copy link
Member

I've marked https://download.eclipse.org/eclipse/downloads/drops4/I20230614-2220/ as unstable, it can't be used, SDK fails immediately on startup.

!SESSION 2023-06-15 08:31:05.944 -----------------------------------------------
eclipse.buildId=4.29.0.I20230614-2220
java.version=17.0.6-internal
java.vendor=N/A
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Command-line arguments:  -os linux -ws gtk -arch x86_64

!ENTRY org.eclipse.osgi 4 0 2023-06-15 08:31:10.614
!MESSAGE An error occurred while automatically activating bundle org.eclipse.core.resources (74).
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start() of bundle org.eclipse.core.resources.
	at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:839)
	at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:767)
	at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1032)
	at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:371)
	at org.eclipse.osgi.container.Module.doStart(Module.java:605)
	at org.eclipse.osgi.container.Module.start(Module.java:468)
	at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:513)
	at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:117)
	at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:570)
	at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:335)
	at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:397)
	at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:41)
	at org.eclipse.osgi.internal.loader.BundleLoader.findClass0(BundleLoader.java:496)
	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:416)
	at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:168)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:153)
	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:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	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)
Caused by: java.lang.NullPointerException: Cannot invoke "org.eclipse.core.runtime.IPath.removeTrailingSeparator()" because "path" is null
	at org.eclipse.core.internal.resources.Resource.<init>(Resource.java:49)
	at org.eclipse.core.internal.resources.Container.<init>(Container.java:30)
	at org.eclipse.core.internal.resources.WorkspaceRoot.<init>(WorkspaceRoot.java:41)
	at org.eclipse.core.internal.resources.Workspace.<init>(Workspace.java:112)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:568)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:1)
	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:943)
	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:1)
	at org.osgi.util.tracker.AbstractTracked.trackAdding(AbstractTracked.java:256)
	at org.osgi.util.tracker.AbstractTracked.trackInitial(AbstractTracked.java:183)
	at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:321)
	at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:264)
	at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:545)
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:818)
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:569)
	at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:810)
	... 29 more
Root exception:
java.lang.NullPointerException: Cannot invoke "org.eclipse.core.runtime.IPath.removeTrailingSeparator()" because "path" is null
	at org.eclipse.core.internal.resources.Resource.<init>(Resource.java:49)
	at org.eclipse.core.internal.resources.Container.<init>(Container.java:30)
	at org.eclipse.core.internal.resources.WorkspaceRoot.<init>(WorkspaceRoot.java:41)
	at org.eclipse.core.internal.resources.Workspace.<init>(Workspace.java:112)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:568)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:1)
	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:943)
	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:1)
	at org.osgi.util.tracker.AbstractTracked.trackAdding(AbstractTracked.java:256)
	at org.osgi.util.tracker.AbstractTracked.trackInitial(AbstractTracked.java:183)
	at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:321)
	at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:264)
	at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:545)
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:818)
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:569)
	at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:810)
	at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:767)
	at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1032)
	at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:371)
	at org.eclipse.osgi.container.Module.doStart(Module.java:605)
	at org.eclipse.osgi.container.Module.start(Module.java:468)
	at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:513)
	at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:117)
	at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:570)
	at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:335)
	at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:397)
	at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:41)
	at org.eclipse.osgi.internal.loader.BundleLoader.findClass0(BundleLoader.java:496)
	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:416)
	at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:168)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:153)
	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:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	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)

@jukzi
Copy link
Contributor Author

jukzi commented Jun 15, 2023

please fix today or revert until solution found

@laeubi
Copy link
Member

laeubi commented Jun 15, 2023

@jukzi can you please try to change

	protected final IWorkspaceRoot defaultRoot = new WorkspaceRoot(Path.ROOT, this);

	protected final IWorkspaceRoot defaultRoot = new WorkspaceRoot(IPath.ROOT, this);

but that's just a guess..

@jukzi
Copy link
Contributor Author

jukzi commented Jun 15, 2023

that ends up in


Caused by: org.eclipse.core.runtime.AssertionFailedException: assertion failed: 
	at org.eclipse.core.runtime.Assert.isTrue(Assert.java:113)
	at org.eclipse.core.runtime.Assert.isTrue(Assert.java:99)
	at org.eclipse.core.internal.resources.WorkspaceRoot.<init>(WorkspaceRoot.java:42)
	at org.eclipse.core.internal.resources.Workspace.<init>(Workspace.java:112)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:568)
	at org.eclipse.core.resources.ResourcesPlugin$WorkspaceInitCustomizer.addingService(ResourcesPlugin.java:1)

@iloveeclipse
Copy link
Member

That's is a chicken and egg problem, where interface init code calls to a class that uses interface defined constants that are not yet initialized:
image

@iloveeclipse
Copy link
Member

So the Path constants are initialized with null values from IPath that is not yet fully initialized...
image

iloveeclipse added a commit to iloveeclipse/equinox that referenced this issue Jun 15, 2023
As long as IPath creates instances of Path in the IPath constants init
code, Path can't back reference to same IPath constants that are not
initialized yet - it will see null values and everyone who uses Path
constants will be broken.

Fixes eclipse-equinox#278
@iloveeclipse
Copy link
Member

See #279.
I plan to merge this ASAP & trigger a build.

iloveeclipse added a commit to iloveeclipse/equinox that referenced this issue Jun 15, 2023
As long as IPath creates instances of Path in the IPath constants init
code, Path can't back reference to same IPath constants that are not
initialized yet - it will see null values and everyone who uses Path
constants will be broken.

Fixes eclipse-equinox#278
@iloveeclipse
Copy link
Member

@iloveeclipse iloveeclipse self-assigned this Jun 15, 2023
@iloveeclipse iloveeclipse added bug Something isn't working regression labels Jun 15, 2023
@iloveeclipse iloveeclipse added this to the 4.29 M1 milestone Jun 15, 2023
@iloveeclipse
Copy link
Member

Triggered new build: https://ci.eclipse.org/releng/job/Builds/job/I-build-4.29/17/

See https://download.eclipse.org/eclipse/downloads/drops4/I20230615-0550/

Works fine for me locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working regression
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants