Uploaded image for project: 'Aptana Studio'
  1. Aptana Studio
  2. APSTUD-4797

PHP Autocomplete throws an NPE and shows error dialog

    Details

    • Story Points:
      3

      Description

      Trying to resolve APSTUD-190, I copied the original (incorrect) block from the description into a php file and tried to invoke content assist after "parent::". I get an error dialog complaining of an NPE. Here's the stack trace from the log:

      !ENTRY org.eclipse.ui 4 4 2012-05-08 15:33:42.293
      !MESSAGE "Content Assist" did not complete normally.  Please see the log for more information.
       
      !ENTRY org.eclipse.ui 4 0 2012-05-08 15:33:42.294
      !MESSAGE java.lang.NullPointerException
      !STACK 0
      java.lang.NullPointerException
      	at com.aptana.editor.php.internal.indexer.UnpackedElementIndex.getEntries(UnpackedElementIndex.java:390)
      	at com.aptana.editor.php.internal.indexer.ModuleSubstitutionIndex.getEntries(ModuleSubstitutionIndex.java:64)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.getClassEntries(PHPContentAssistProcessor.java:1209)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.computeStaticDereferenceLeftEntries(PHPContentAssistProcessor.java:1121)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.computeStaticDereferenceEntries(PHPContentAssistProcessor.java:822)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.dereferencingStaticCompletion(PHPContentAssistProcessor.java:772)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.computeCompletionProposalInternal(PHPContentAssistProcessor.java:555)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.computeCompletionProposals(PHPContentAssistProcessor.java:485)
      	at com.aptana.editor.php.internal.contentAssist.PHPContentAssistProcessor.computeCompletionProposals(PHPContentAssistProcessor.java:306)
      	at com.aptana.editor.common.CommonContentAssistProcessor.doComputeCompletionProposals(CommonContentAssistProcessor.java:500)
      	at com.aptana.editor.common.CommonContentAssistProcessor.computeCompletionProposals(CommonContentAssistProcessor.java:417)
      	at com.aptana.editor.common.contentassist.ContentAssistant.computeCompletionProposals(ContentAssistant.java:2221)
      	at com.aptana.editor.common.contentassist.CompletionProposalPopup.computeProposals(CompletionProposalPopup.java:394)
      	at com.aptana.editor.common.contentassist.CompletionProposalPopup.access$7(CompletionProposalPopup.java:388)
      	at com.aptana.editor.common.contentassist.CompletionProposalPopup$1.run(CompletionProposalPopup.java:331)
      	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
      	at com.aptana.editor.common.contentassist.CompletionProposalPopup.showProposals(CompletionProposalPopup.java:325)
      	at com.aptana.editor.common.contentassist.ContentAssistant.showPossibleCompletions(ContentAssistant.java:2008)
      	at org.eclipse.jface.text.source.SourceViewer.doOperation(SourceViewer.java:930)
      	at org.eclipse.jface.text.source.projection.ProjectionViewer.doOperation(ProjectionViewer.java:1535)
      	at org.eclipse.ui.texteditor.ContentAssistAction$1.run(ContentAssistAction.java:82)
      	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
      	at org.eclipse.ui.texteditor.ContentAssistAction.run(ContentAssistAction.java:80)
      	at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
      	at org.eclipse.ui.commands.ActionHandler.execute(ActionHandler.java:185)
      	at org.eclipse.ui.internal.handlers.LegacyHandlerWrapper.execute(LegacyHandlerWrapper.java:109)
      	at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
      	at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
      	at org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerService.java:169)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard.executeCommand(WorkbenchKeyboard.java:468)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard.press(WorkbenchKeyboard.java:786)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard.processKeyEvent(WorkbenchKeyboard.java:885)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard.filterKeySequenceBindings(WorkbenchKeyboard.java:567)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard.access$3(WorkbenchKeyboard.java:508)
      	at org.eclipse.ui.internal.keys.WorkbenchKeyboard$KeyDownFilter.handleEvent(WorkbenchKeyboard.java:123)
      	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
      	at org.eclipse.swt.widgets.Display.filterEvent(Display.java:1069)
      	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4127)
      	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1457)
      	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1480)
      	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1465)
      	at org.eclipse.swt.widgets.Widget.sendKeyEvent(Widget.java:1494)
      	at org.eclipse.swt.widgets.Widget.sendKeyEvent(Widget.java:1490)
      	at org.eclipse.swt.widgets.Canvas.sendKeyEvent(Canvas.java:493)
      	at org.eclipse.swt.widgets.Control.doCommandBySelector(Control.java:1060)
      	at org.eclipse.swt.widgets.Display.windowProc(Display.java:5563)
      	at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method)
      	at org.eclipse.swt.internal.cocoa.NSResponder.interpretKeyEvents(NSResponder.java:68)
      	at org.eclipse.swt.widgets.Composite.keyDown(Composite.java:587)
      	at org.eclipse.swt.widgets.Display.windowProc(Display.java:5473)
      	at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method)
      	at org.eclipse.swt.widgets.Widget.callSuper(Widget.java:220)
      	at org.eclipse.swt.widgets.Widget.windowSendEvent(Widget.java:2095)
      	at org.eclipse.swt.widgets.Shell.windowSendEvent(Shell.java:2253)
      	at org.eclipse.swt.widgets.Display.windowProc(Display.java:5535)
      	at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method)
      	at org.eclipse.swt.widgets.Display.applicationSendEvent(Display.java:4989)
      	at org.eclipse.swt.widgets.Display.applicationProc(Display.java:5138)
      	at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method)
      	at org.eclipse.swt.internal.cocoa.NSApplication.sendEvent(NSApplication.java:128)
      	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3610)
      	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2701)
      	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2665)
      	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2499)
      	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:679)
      	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
      	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:668)
      	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
      	at com.aptana.rcp.IDEApplication.start(IDEApplication.java:125)
      	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
      	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)
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                sgibly Shalom Gibly
                Reporter:
                cwilliams Christopher Williams
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Git Integration