Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 330136 - Unable to start e4: NPE in MenuManagerRenderer
Summary: Unable to start e4: NPE in MenuManagerRenderer
Status: RESOLVED INVALID
Alias: None
Product: e4
Classification: Eclipse Project
Component: UI (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-12 15:26 EST by Oleg Besedin CLA
Modified: 2010-11-12 15:57 EST (History)
2 users (show)

See Also:


Attachments
Full stack (7.84 KB, text/plain)
2010-11-12 15:26 EST, Oleg Besedin CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Besedin CLA 2010-11-12 15:26:10 EST
Created attachment 183041 [details]
Full stack

Using the current code from Head when trying to lauch e4 SDK instance results in NPE:

MenuManagerRenderer.processRenderedItem(MenuManager, MRenderedMenuItem) line: 649	
MenuManagerRenderer.modelProcessSwitch(MenuManager, MMenuElement) line: 611	
MenuManagerRenderer.processMenu(MenuManager, MMenu) line: 596	
MenuManagerRenderer.modelProcessSwitch(MenuManager, MMenuElement) line: 626	
MenuManagerRenderer.processMenu(MenuManager, MMenu) line: 596	
MenuManagerRenderer.modelProcessSwitch(MenuManager, MMenuElement) line: 626	
MenuManagerRenderer.processContents(MElementContainer<MUIElement>) line: 568	
PartRenderingEngine.createGui(MUIElement, Object, IEclipseContext) line: 490	
WorkbenchWindow.setup() line: 535
Comment 1 Oleg Besedin CLA 2010-11-12 15:33:41 EST
Here is what happens in the MenuManagerRenderer#processRenderedItem():

void processRenderedItem(MenuManager parentManager, MRenderedMenuItem itemModel) {
	<<<= itemModel is org.eclipse.debug.ui.actions.BreakpointTypesContribution
	...
	ici = null 
	...
	Object obj = itemModel.getContributionItem(); <<<= obj here is ExtensionPointProxy 
	if (obj instanceof IContextFunction) { <<<= false
		ici = ...
	} else if (obj instanceof IContributionItem) { <<<= false
		ici = ...
	}
	ici.setVisible(itemModel.isVisible()); <<<= NPE here
	...
}
Comment 2 Oleg Besedin CLA 2010-11-12 15:37:22 EST
The debug output:
Failed to load MRenderedMenuItem org.eclipse.e4.ui.model.application.ui.menu.impl.RenderedMenuItemImpl@dc6007 (elementId: org.eclipse.debug.ui.actions.BreakpointTypesContribution, tags: null) (widget: null, renderer: null, toBeRendered: true, onTop: false, visible: true, containerData: null, accessibilityPhrase: null) (label: null, iconURI: null, tooltip: null, localLabel: null, localTooltip: null, localImage: null, enabled: true, selected: false, type: Push) (mnemonics: null) (contributionItem: org.eclipse.e4.ui.internal.workbench.ExtensionPointProxy@1c118ae)
	org.eclipse.e4.ui.internal.workbench.ExtensionPointProxy@1c118ae
Comment 3 Paul Webster CLA 2010-11-12 15:45:28 EST
OK, we're having some ... PDE hiccups :-)

PW
Comment 4 Oleg Besedin CLA 2010-11-12 15:57:05 EST
Sorry, turns out somehow I got in a state where org.eclipse.ui.workbench was not picked up from my workspace.