Community
Participate
Working Groups
Dear Support group, We use Eclipse 3.2 as a Java development Id in our project. However, we are facing a very frustrating issue while importing User libraries. Initially, import option works fine but after some tries, suddenly it stops working giving no response. After checking error logs, we see two errors: Severity : Error Error 1 assertion failed: Path for IClasspathEntry must be absolute org.eclipse.core.runtime.AssertionFailedException: assertion failed: Path for IClasspathEntry must be absolute at org.eclipse.core.runtime.Assert.isTrue(Assert.java:109) at org.eclipse.jdt.core.JavaCore.newLibraryEntry(JavaCore.java:3384) at org.eclipse.jdt.internal.ui.wizards.buildpaths.CPListElement.newClasspathEntry(CPListElement.java:175) at org.eclipse.jdt.internal.ui.wizards.buildpaths.CPListElement.getClasspathEntry(CPListElement.java:142) at org.eclipse.jdt.internal.ui.wizards.buildpaths.CPListElement.equals(CPListElement.java:386) at java.util.ArrayList.indexOf(Unknown Source) at java.util.ArrayList.contains(Unknown Source) at org.eclipse.jdt.internal.ui.wizards.buildpaths.CPUserLibraryElement.add(CPUserLibraryElement.java:115) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage$LoadSaveDialog.loadLibraries(UserLibraryPreferencePage.java:668) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage$LoadSaveDialog.updateShownLibraries(UserLibraryPreferencePage.java:374) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage$LoadSaveDialog.dialogFieldChanged(UserLibraryPreferencePage.java:398) at org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField.dialogFieldChanged(DialogField.java:70) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField.doModifyText(StringDialogField.java:130) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField.access$0(StringDialogField.java:126) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField$1.modifyText(StringDialogField.java:108) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:196) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:952) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:933) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:2143) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:3375) at org.eclipse.swt.widgets.Control.windowProc(Control.java:3249) at org.eclipse.swt.widgets.Display.windowProc(Display.java:4025) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java:1842) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:131) at org.eclipse.swt.widgets.Control.windowProc(Control.java:3334) at org.eclipse.swt.widgets.Text.windowProc(Text.java:1841) at org.eclipse.swt.widgets.Display.windowProc(Display.java:4025) at org.eclipse.swt.internal.win32.OS.SetWindowTextW(Native Method) at org.eclipse.swt.internal.win32.OS.SetWindowText(OS.java:2636) at org.eclipse.swt.widgets.Text.setText(Text.java:1657) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField.setText(StringDialogField.java:160) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage$LoadSaveDialog.changeControlPressed(UserLibraryPreferencePage.java:360) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField.changeControlPressed(StringButtonDialogField.java:56) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField$1.widgetSelected(StringButtonDialogField.java:113) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:90) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968) at org.eclipse.jface.window.Window.runEventLoop(Window.java:820) at org.eclipse.jface.window.Window.open(Window.java:796) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage.doLoad(UserLibraryPreferencePage.java:1121) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage.doCustomButtonPressed(UserLibraryPreferencePage.java:1014) at org.eclipse.jdt.internal.ui.preferences.UserLibraryPreferencePage$UserLibraryAdapter.customButtonPressed(UserLibraryPreferencePage.java:1279) at org.eclipse.jdt.internal.ui.wizards.dialogfields.TreeListDialogField.buttonPressed(TreeListDialogField.java:167) at org.eclipse.jdt.internal.ui.wizards.dialogfields.TreeListDialogField.doButtonSelected(TreeListDialogField.java:385) at org.eclipse.jdt.internal.ui.wizards.dialogfields.TreeListDialogField.access$2(TreeListDialogField.java:381) at org.eclipse.jdt.internal.ui.wizards.dialogfields.TreeListDialogField$2.widgetSelected(TreeListDialogField.java:346) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:90) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968) at org.eclipse.jface.window.Window.runEventLoop(Window.java:820) at org.eclipse.jface.window.Window.open(Window.java:796) at org.eclipse.ui.internal.OpenPreferencesAction.run(OpenPreferencesAction.java:65) at org.eclipse.jface.action.Action.runWithEvent(Action.java:499) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:539) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1914) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336) at org.eclipse.core.launcher.Main.basicRun(Main.java:280) at org.eclipse.core.launcher.Main.run(Main.java:977) at org.eclipse.core.launcher.Main.main(Main.java:952) Session Data: eclipse.buildId=M20060629-1905 Error 2 Unhandled event loop exception An exception stack trace is not available. Session Data: eclipse.buildId=M20060629-1905 Kindly help us to remove the bug as it is a solid tool having a lot of support available in the form of various plug ins. Regards Naveen Jain
Could you please attach the file you are trying to import to this bug ?
Created attachment 77961 [details] It contains User libraries It is not specific for importing a particular file. Normally, it works fine but when it stops working, it does not work for any of the user library file.
Reproduced using latest I-build. It looks like the attached user libraries file has the wrong version: <eclipse-userlibraries version="2"> Changing it to <eclipse-userlibraries version="1"> makes the import work. What version of Eclipse did you use to export the user libraries ? Moving to JDT/UI for further investigation.
Hi, We are using Eclipse 3.2.0 version. Moreover, I draw your kind attention to the fact that import button stops responding, giving errors n error console. It is different from the argument that jars do not get imported properly when selected a file. In that case, I can think of invalid version in file. However, I face a scenario where import button becomes inactive. Please clarify. Regards Naveen Jain
Is it possible that the file from comment 2 has been manually edited? It seems as if a extra library was added at the end, but its using the wrong path delimiters. As workaround, I suggest you to change this to <library name="remoteTea" systemlibrary="false"> <archive path="Y:/km_cmg/biip/3pp/remotetea/jrpcgen.jar" /> <archive path="Y:/km_cmg/biip/3pp/remotetea/oncrpc.jar" /> <archive path="Y:/km_cmg/biip/3pp/remotetea/portmap.jar" /> </library> (You can keep the version to 2, as it is now) We can add more tolerance to the importer code, but this will be for 3.4 or 3.3.1 maximum. I'm not sure if that helps. What you observe is correct: once you tried to import the malformed file, you cannot even press 'Import' the next time. The reason is that the path of the previous file is stored and it is attempted to be loaded when the dialog is opened.
fixed in 3.4 > 20070911
Martin, Thanks for your observations. Yes, I added last library block in the file manually. However, it worked fine for 2-3 times since I was able to import it fine. Suddenly, while setting up a new project, it stopped working. It is just for your information as I am quite convinced that your solution will work for me. I am unable to understand following line: We can add more tolerance to the importer code, but this will be for 3.4 or 3.3.1 maximum. I'm not sure if that helps. Do you mean upgrade to higher version of Eclipse? We are using many plugins so we can not upgrade Eclipse to 3.3 or 3.4 immediately. Can you provide some kind of patch for 3.2 itself?
Yes, we're now working on 3.4 and 3.3.x. Requesting patches and rebuilds for 3.2 is a lengthy process. If you want that, I can find out who you have to ask to. But as you were manually editing the file, which is not really supported, I'd rather suggest you to fix your libraries file. Is that possible?
Martin, Surely, I will do so as I understand it is not easy to provide fixes for previous releases. You can close the bug from my end. Thanks very much. Regards Naveen Jain