Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 426649

Summary: Exception setting Stereotype icons
Product: [Modeling] Papyrus Reporter: Luís de Sousa <luis.de.sousa>
Component: ViewsAssignee: Camille Letavernier <cletavernier>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 0.10.1   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on: 402525    
Bug Blocks:    

Description Luís de Sousa CLA 2014-01-25 12:29:04 EST
Hello. I am trying to add icon(s) to a Stereotype following the documentation. I'm going through Properties -> UML -> Icons -> Plus sign to get the "Create a new image" dialogue. When I select an image no extra buttons are presented in the dialogue, nor is any path selected. In the log I'm getting the message below.

Thank you.

=================================================================================

Message
-------
Unexpected Error

Exception Stack Trace
---------------------
org.eclipse.papyrus.infra.core.services.ServiceNotFoundException: Can't find the ResourceSet needed retrieve the ServiceRegistry.
	at org.eclipse.papyrus.infra.emf.utils.ServiceUtilsForResource.getServiceRegistry(ServiceUtilsForResource.java:64)
	at org.eclipse.papyrus.infra.emf.utils.ServiceUtilsForEObject.getServiceRegistry(ServiceUtilsForEObject.java:43)
	at org.eclipse.papyrus.infra.emf.utils.ServiceUtilsForEObject.getServiceRegistry(ServiceUtilsForEObject.java:1)
	at org.eclipse.papyrus.infra.core.utils.AbstractServiceUtils.getTransactionalEditingDomain(AbstractServiceUtils.java:60)
	at org.eclipse.papyrus.uml.properties.widgets.StereotypeImageEditor.browseAction(StereotypeImageEditor.java:140)
	at org.eclipse.papyrus.uml.properties.widgets.StereotypeImageEditor.widgetSelected(StereotypeImageEditor.java:203)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1392)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3742)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3363)
	at org.eclipse.jface.window.Window.runEventLoop(Window.java:826)
	at org.eclipse.jface.window.Window.open(Window.java:802)
	at org.eclipse.papyrus.views.properties.creation.PropertyEditorFactory.createObject(PropertyEditorFactory.java:95)
	at org.eclipse.papyrus.views.properties.creation.EcorePropertyEditorFactory.createObject(EcorePropertyEditorFactory.java:196)
	at org.eclipse.papyrus.infra.widgets.editors.MultipleValueEditor.addAction(MultipleValueEditor.java:404)
	at org.eclipse.papyrus.infra.widgets.editors.MultipleValueEditor.widgetSelected(MultipleValueEditor.java:383)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1392)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3742)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3363)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:138)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:610)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
	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:354)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:601)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1426)

Session Data
------------
eclipse.buildId=4.3.0.M20130911-1000
java.version=1.7.0_17
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_GB
Command-line arguments:  -os linux -ws gtk -arch x86_64
Comment 1 Camille Letavernier CLA 2014-01-29 04:49:44 EST
This is a side effect of Bug 402525

I've pushed a workaround in commit 0a212d7 (master) and 6788389 (0.10-maintenance)