Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 362244 - NPE in DebugContextManager clicking in global toolbar
Summary: NPE in DebugContextManager clicking in global toolbar
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 4.2   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-Debug-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-27 17:06 EDT by John Arthorne CLA
Modified: 2019-11-14 03:32 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Arthorne CLA 2011-10-27 17:06:20 EDT
I20111014-1625 (4.2 stream)

I got this NPE by clicking the button to the left of the "stop" button in the workbench (global) debug toolbar.

Caused by: java.lang.NullPointerException
	at org.eclipse.debug.internal.ui.contexts.DebugContextManager.createService(DebugContextManager.java:136)
	at org.eclipse.debug.internal.ui.contexts.DebugContextManager.getContextService(DebugContextManager.java:195)
	at org.eclipse.debug.ui.actions.DebugCommandAction.getDebugContextService(DebugCommandAction.java:291)
	at org.eclipse.debug.ui.actions.DebugCommandAction.getContext(DebugCommandAction.java:236)
	at org.eclipse.debug.ui.actions.DebugCommandAction.run(DebugCommandAction.java:253)
	at org.eclipse.debug.internal.ui.commands.actions.DebugCommandActionDelegate.run(DebugCommandActionDelegate.java:70)
	at org.eclipse.debug.internal.ui.commands.actions.DebugCommandActionDelegate.runWithEvent(DebugCommandActionDelegate.java:79)
	at org.eclipse.ui.internal.handlers.ActionDelegateHandlerProxy.execute(ActionDelegateHandlerProxy.java:285)
	at org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:68)
	at sun.reflect.GeneratedMethodAccessor24.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56)
Comment 1 Pawel Piech CLA 2011-10-27 18:17:16 EDT
Thank you for the trace.  It implies that the action was either initialized with a null IWorkbenchWindow, or was ran after being disposed.  Did this occur in context of starting or shutting down the IDE?
Comment 2 Pawel Piech CLA 2011-10-27 18:18:59 EDT
BTW, it's the "disconnect" action, which applies only to remote debugging in java, though it's more useful with CDT.  Do you think it should be hidden by default?
Comment 3 John Arthorne CLA 2011-10-31 14:34:23 EDT
It wasn't at startup or shutdown, but it was immediately after I enabled the global debug toolbar for the first time. 

And yes it was the "Disconnect" action. For some reason tooltips weren't working at the time, but I see the tooltips now.
Comment 4 Lars Vogel CLA 2019-11-14 03:32:29 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.