#513 Could not acquire children... NPE in the navigator

closed-fixed
Lars
5
2009-12-10
2009-11-20
No

Hi.

I encountered this issue several times with the last version (3.0.1) of SoapUI.
This is the first version I installed on my Eclipse distribution.
Therefore, I don't have any old version that may have caused this.

java.lang.NullPointerException
at org.eclipse.ui.internal.navigator.NavigatorContentService.rememberContribution(NavigatorContentService.java:725)
at org.eclipse.ui.internal.navigator.extensions.SafeDelegateTreeContentProvider.getElements(SafeDelegateTreeContentProvider.java:97)
at org.eclipse.ui.internal.navigator.NavigatorContentServiceContentProvider.getElements(NavigatorContentServiceContentProvider.java:156)
at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.computeSaveables(NavigatorSaveablesService.java:235)
at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.init(NavigatorSaveablesService.java:211)
at org.eclipse.ui.navigator.CommonNavigator.createPartControl(CommonNavigator.java:227)
at org.eclipse.ui.navigator.resources.ProjectExplorer.createPartControl(ProjectExplorer.java:75)
at org.eclipse.ui.internal.ViewReference.createPartHelper(ViewReference.java:367)
at org.eclipse.ui.internal.ViewReference.createPart(ViewReference.java:226)
at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:595)
at org.eclipse.ui.internal.PartPane.setVisible(PartPane.java:313)
at org.eclipse.ui.internal.ViewPane.setVisible(ViewPane.java:529)
at org.eclipse.ui.internal.presentations.PresentablePart.setVisible(PresentablePart.java:180)
at org.eclipse.ui.internal.presentations.util.PresentablePartFolder.select(PresentablePartFolder.java:270)
at org.eclipse.ui.internal.presentations.util.LeftToRightTabOrder.select(LeftToRightTabOrder.java:65)
at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation.selectPart(TabbedStackPresentation.java:473)
at org.eclipse.ui.internal.PartStack.refreshPresentationSelection(PartStack.java:1256)
at org.eclipse.ui.internal.PartStack.createControl(PartStack.java:668)
at org.eclipse.ui.internal.PartStack.createControl(PartStack.java:576)
at org.eclipse.ui.internal.PartSashContainer.createControl(PartSashContainer.java:568)
at org.eclipse.ui.internal.PerspectiveHelper.activate(PerspectiveHelper.java:272)
at org.eclipse.ui.internal.Perspective.onActivate(Perspective.java:982)
at org.eclipse.ui.internal.WorkbenchPage.onActivate(WorkbenchPage.java:2626)
at org.eclipse.ui.internal.WorkbenchWindow$27.run(WorkbenchWindow.java:2965)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
at org.eclipse.ui.internal.WorkbenchWindow.setActivePage(WorkbenchWindow.java:2946)
at org.eclipse.ui.internal.WorkbenchWindow$21.runWithException(WorkbenchWindow.java:2263)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3855)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3476)
at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:803)
at org.eclipse.ui.internal.Workbench$28.runWithException(Workbench.java:1384)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3855)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3476)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2316)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
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:368)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
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.equinox.launcher.Main.invokeFramework(Main.java:559)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
at org.eclipse.equinox.launcher.Main.run(Main.java:1311)

Steps to reproduce:
1. Install the last version of SOAP UI (3.0.1). Make sure no older version is installed.
2. Go into a workspace with no SoapUI project.
3. Open the project explorer.
4. Go into the error log. You should see 3 logged errors.

This error occurs because the navigator framework goes through all the elements returned by extensions and that there is no check on whether the array of elements is null or not.

To solve this error, go into com.eviware.soapui.eclipse.browser.AbstractContentProvider
and update the body of the method #getElements( Object ).

Instead of "return null;" put "return new Object[ 0 ];"

Discussion

  • Lars

    Lars - 2009-12-10

    Fixed. It will be available in the next nightly build.
    Thanks for reporting and for the solution!
    /Lars, eviware.com

     
  • Lars

    Lars - 2009-12-10
    • status: open --> closed-fixed
     

Log in to post a comment.