Bug 537905 - Cannot modify resource set without a write transaction
Summary: Cannot modify resource set without a write transaction
Status: RESOLVED FIXED
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: 3.4.0   Edit
Hardware: PC Windows 10
: P3 critical (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 543303
  Show dependency tree
 
Reported: 2018-08-13 10:15 EDT by Jessie Jewitt CLA
Modified: 2019-01-10 03:48 EST (History)
5 users (show)

See Also:


Attachments
Error log (510.68 KB, application/octet-stream)
2018-08-13 10:15 EDT, Jessie Jewitt CLA
no flags Details
Papyrus model where bug is present (639.24 KB, application/x-zip-compressed)
2019-01-08 19:08 EST, Jessie Jewitt CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jessie Jewitt CLA 2018-08-13 10:15:19 EDT
Created attachment 275381 [details]
Error log

After updating my model, I cannot open it and keep getting the error:
"Cannot modify resource set without a write transaction"
See attached log
Comment 1 Jessie Jewitt CLA 2018-08-14 15:41:53 EDT
I am running Eclipse/Oxygen with Papyrus 3.4.0
I believe the problem is due to the following facts specific to my model:
1. I have an overall model called "model" (with 3 associated Papyrus files)
2. There are 5 sub-models in "model"
3. Each sub-model references artifacts that are in other sub-models
It appears that the problem is when it is trying to load sub-models referenced by other sub-models that are all contained within my "model". It is when I try to open "model" that I get the error message specified by this bug. Also, when I try to open the sub-models that contain references to other sub-models, they are either greyed-out or are not opened correctly. 

This is a blocking issue, please help!
Thanks,
Jessie
Comment 2 Nicolas FAUVERGUE CLA 2018-08-20 08:35:26 EDT
Hi,

I take a look on your problem and log file, and it seems to come from the sub-models and stereotypes. Can you confirm that you are using stereotypes applied on elements of sub-models ?

But i cannot reproduce this bug with a simple model. Can you share your models (as a 'zip' file) or a simplified model with your bug ?

Thanks in advance,
Nicolas.
Comment 3 Patrick Tessier CLA 2018-08-31 10:27:29 EDT
Hi A waiting for response to progress on management of the bug. can you send information
Comment 4 Vincent Lorenzo CLA 2018-12-20 08:59:19 EST
I pretty sure this bug is fixed since several month (year?) on Photon.

No new from the bug reporter. I close the bug.
Comment 5 Jessie Jewitt CLA 2019-01-08 19:08:09 EST
Created attachment 277110 [details]
Papyrus model where bug is present

This is the Papyrus model that I opened using Eclipse/Photon with associated Papyrus software. The bug is still present.
Comment 6 Jessie Jewitt CLA 2019-01-08 19:09:31 EST
Please reopen this bug as it is STILL present using Eclipse/Photon.
Comment 7 Jessie Jewitt CLA 2019-01-08 19:09:31 EST
Please reopen this bug as it is STILL present using Eclipse/Photon.
Comment 8 Jessie Jewitt CLA 2019-01-08 19:09:56 EST
Please reopen this bug as it is STILL present using Eclipse/Photon.
Comment 9 Vincent Lorenzo CLA 2019-01-09 05:06:58 EST
1. I confirm the problem on Photon 2018.12
2. After some debug, the problem seems comes from something in the Resource submodel. Removing its reference in the model.uml file, all works fine.
3. I found some strange points: 
   a.in Resource.uml files (opened in text mode), there are 3 stereotype application
OpenModel_Profile:OpenModelAttribute concerning object owned by Service.uml and not by Resource.uml.
   b. The fierst of them references an unknown object : href="Service.uml#_izo2krAVEei3l9EE3oQfMw doesn't exist
   c. After open model.uml, the Resource Package is displayed as read-only (but is is a consequence or a cause the bug?)

4. I get this stacktrace with your models: 

!ENTRY org.eclipse.emf.transaction 2 100 2019-01-09 11:05:10.911
!MESSAGE Resource was re-loaded while it was being unloaded, probably because of unintentional proxy resolution: platform:/resource/ONAP%20Information%20Model/Vnf.uml

!ENTRY org.eclipse.emf.transaction 2 100 2019-01-09 11:05:11.032
!MESSAGE Resource was re-loaded while it was being unloaded, probably because of unintentional proxy resolution: platform:/resource/ONAP%20Information%20Model/Resource.uml

!ENTRY org.eclipse.papyrus.uml.tools 4 0 2019-01-09 11:05:12.955
!MESSAGE Unexpected Error
!STACK 0
org.eclipse.papyrus.infra.core.resource.NotFoundException: No root defined in the model
	at org.eclipse.papyrus.uml.tools.model.UmlModel.lookupRoot(UmlModel.java:114)
	at org.eclipse.papyrus.uml.tools.service.ProfileDefinitionService.addRootProfileDecorationIfRequired(ProfileDefinitionService.java:140)
	at org.eclipse.papyrus.uml.tools.service.ProfileDefinitionService.startService(ProfileDefinitionService.java:121)
	at org.eclipse.papyrus.infra.core.services.internal.ServiceEntry.startService(ServiceEntry.java:154)
	at org.eclipse.papyrus.infra.core.services.internal.StartStartupEntry.startService(StartStartupEntry.java:83)
	at org.eclipse.papyrus.infra.core.services.ServicesRegistry.startServices(ServicesRegistry.java:1022)
	at org.eclipse.papyrus.infra.core.services.ServicesRegistry.startRegistry(ServicesRegistry.java:490)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.loadModelAndServices(CoreMultiDiagramEditor.java:628)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.initContents(CoreMultiDiagramEditor.java:938)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.init(CoreMultiDiagramEditor.java:485)
	at org.eclipse.ui.internal.EditorReference.initialize(EditorReference.java:365)
	at org.eclipse.ui.internal.e4.compatibility.CompatibilityPart.create(CompatibilityPart.java:345)
	at sun.reflect.GeneratedMethodAccessor77.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:58)
	at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:1001)
	at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:966)
	at org.eclipse.e4.core.internal.di.InjectorImpl.internalInject(InjectorImpl.java:139)
	at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:411)
	at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:333)
	at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:193)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.createFromBundle(ReflectionContributionFactory.java:108)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.doCreate(ReflectionContributionFactory.java:77)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.create(ReflectionContributionFactory.java:59)
	at org.eclipse.e4.ui.workbench.renderers.swt.ContributedPartRenderer.createWidget(ContributedPartRenderer.java:132)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createWidget(PartRenderingEngine.java:1015)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:675)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:781)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.access$0(PartRenderingEngine.java:752)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$2.run(PartRenderingEngine.java:746)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createGui(PartRenderingEngine.java:730)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl$1.handleEvent(PartServiceImpl.java:107)
	at org.eclipse.e4.ui.services.internal.events.UIEventHandler.lambda$0(UIEventHandler.java:38)
	at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:236)
	at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:147)
	at org.eclipse.swt.widgets.Display.syncExec(Display.java:4574)
	at org.eclipse.e4.ui.internal.workbench.swt.E4Application$1.syncExec(E4Application.java:219)
	at org.eclipse.e4.ui.services.internal.events.UIEventHandler.handleEvent(UIEventHandler.java:38)
	at org.eclipse.equinox.internal.event.EventHandlerWrapper.handleEvent(EventHandlerWrapper.java:205)
	at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:203)
	at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:1)
	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:233)
	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:151)
	at org.eclipse.equinox.internal.event.EventAdminImpl.dispatchEvent(EventAdminImpl.java:132)
	at org.eclipse.equinox.internal.event.EventAdminImpl.sendEvent(EventAdminImpl.java:75)
	at org.eclipse.equinox.internal.event.EventComponent.sendEvent(EventComponent.java:44)
	at org.eclipse.e4.ui.services.internal.events.EventBroker.send(EventBroker.java:55)
	at org.eclipse.e4.ui.internal.workbench.UIEventPublisher.notifyChanged(UIEventPublisher.java:63)
	at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:424)
	at org.eclipse.e4.ui.model.application.ui.impl.ElementContainerImpl.setSelectedElement(ElementContainerImpl.java:177)
	at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.showElementInWindow(ModelServiceImpl.java:637)
	at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.bringToTop(ModelServiceImpl.java:601)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.delegateBringToTop(PartServiceImpl.java:791)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.bringToTop(PartServiceImpl.java:404)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.showPart(PartServiceImpl.java:1241)
	at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:3319)
	at org.eclipse.ui.internal.WorkbenchPage.lambda$9(WorkbenchPage.java:3218)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:72)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3215)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3179)
	at org.eclipse.papyrus.infra.onefile.internal.ui.providers.PapyrusModelActionProvider$1.run(PapyrusModelActionProvider.java:160)
	at org.eclipse.ui.actions.RetargetAction.run(RetargetAction.java:219)
	at org.eclipse.ui.navigator.CommonNavigatorManager$1.open(CommonNavigatorManager.java:183)
	at org.eclipse.ui.OpenAndLinkWithEditorHelper$InternalListener.open(OpenAndLinkWithEditorHelper.java:49)
	at org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:853)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.ui.internal.JFaceUtil.lambda$0(JFaceUtil.java:47)
	at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:176)
	at org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:850)
	at org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1165)
	at org.eclipse.ui.navigator.CommonViewer.handleOpen(CommonViewer.java:454)
	at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:276)
	at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:271)
	at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:311)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:89)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4125)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1055)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3938)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3541)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1173)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1062)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:156)
	at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:636)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:563)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:151)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:155)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:203)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:137)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:107)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:255)
	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:659)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:595)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1501)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1474)

!ENTRY org.eclipse.papyrus.infra.ui 4 0 2019-01-09 11:05:12.961
!MESSAGE Unexpected Error
!STACK 0
org.eclipse.papyrus.infra.core.resource.ModelMultiException: Problems encountered while loading one of the models.
----- exceptions : ----------
org.eclipse.papyrus.infra.core.resource.uml.UmlModel : Cannot modify resource set without a write transaction
----------------------------- 

	at org.eclipse.papyrus.infra.core.resource.ModelSet.loadModels(ModelSet.java:589)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.loadModelAndServices(CoreMultiDiagramEditor.java:614)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.initContents(CoreMultiDiagramEditor.java:938)
	at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.init(CoreMultiDiagramEditor.java:485)
	at org.eclipse.ui.internal.EditorReference.initialize(EditorReference.java:365)
	at org.eclipse.ui.internal.e4.compatibility.CompatibilityPart.create(CompatibilityPart.java:345)
	at sun.reflect.GeneratedMethodAccessor77.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:58)
	at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:1001)
	at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:966)
	at org.eclipse.e4.core.internal.di.InjectorImpl.internalInject(InjectorImpl.java:139)
	at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:411)
	at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:333)
	at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:193)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.createFromBundle(ReflectionContributionFactory.java:108)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.doCreate(ReflectionContributionFactory.java:77)
	at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.create(ReflectionContributionFactory.java:59)
	at org.eclipse.e4.ui.workbench.renderers.swt.ContributedPartRenderer.createWidget(ContributedPartRenderer.java:132)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createWidget(PartRenderingEngine.java:1015)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:675)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:781)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.access$0(PartRenderingEngine.java:752)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$2.run(PartRenderingEngine.java:746)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createGui(PartRenderingEngine.java:730)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl$1.handleEvent(PartServiceImpl.java:107)
	at org.eclipse.e4.ui.services.internal.events.UIEventHandler.lambda$0(UIEventHandler.java:38)
	at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:236)
	at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:147)
	at org.eclipse.swt.widgets.Display.syncExec(Display.java:4574)
	at org.eclipse.e4.ui.internal.workbench.swt.E4Application$1.syncExec(E4Application.java:219)
	at org.eclipse.e4.ui.services.internal.events.UIEventHandler.handleEvent(UIEventHandler.java:38)
	at org.eclipse.equinox.internal.event.EventHandlerWrapper.handleEvent(EventHandlerWrapper.java:205)
	at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:203)
	at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:1)
	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:233)
	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:151)
	at org.eclipse.equinox.internal.event.EventAdminImpl.dispatchEvent(EventAdminImpl.java:132)
	at org.eclipse.equinox.internal.event.EventAdminImpl.sendEvent(EventAdminImpl.java:75)
	at org.eclipse.equinox.internal.event.EventComponent.sendEvent(EventComponent.java:44)
	at org.eclipse.e4.ui.services.internal.events.EventBroker.send(EventBroker.java:55)
	at org.eclipse.e4.ui.internal.workbench.UIEventPublisher.notifyChanged(UIEventPublisher.java:63)
	at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:424)
	at org.eclipse.e4.ui.model.application.ui.impl.ElementContainerImpl.setSelectedElement(ElementContainerImpl.java:177)
	at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.showElementInWindow(ModelServiceImpl.java:637)
	at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.bringToTop(ModelServiceImpl.java:601)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.delegateBringToTop(PartServiceImpl.java:791)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.bringToTop(PartServiceImpl.java:404)
	at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.showPart(PartServiceImpl.java:1241)
	at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:3319)
	at org.eclipse.ui.internal.WorkbenchPage.lambda$9(WorkbenchPage.java:3218)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:72)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3215)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3179)
	at org.eclipse.papyrus.infra.onefile.internal.ui.providers.PapyrusModelActionProvider$1.run(PapyrusModelActionProvider.java:160)
	at org.eclipse.ui.actions.RetargetAction.run(RetargetAction.java:219)
	at org.eclipse.ui.navigator.CommonNavigatorManager$1.open(CommonNavigatorManager.java:183)
	at org.eclipse.ui.OpenAndLinkWithEditorHelper$InternalListener.open(OpenAndLinkWithEditorHelper.java:49)
	at org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:853)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.ui.internal.JFaceUtil.lambda$0(JFaceUtil.java:47)
	at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:176)
	at org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:850)
	at org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1165)
	at org.eclipse.ui.navigator.CommonViewer.handleOpen(CommonViewer.java:454)
	at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:276)
	at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:271)
	at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:311)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:89)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4125)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1055)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3938)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3541)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1173)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1062)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:156)
	at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:636)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:563)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:151)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:155)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:203)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:137)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:107)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:255)
	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:659)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:595)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1501)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1474)
Caused by: java.lang.IllegalStateException: Cannot modify resource set without a write transaction
	at org.eclipse.emf.transaction.impl.TransactionChangeRecorder.assertWriting(TransactionChangeRecorder.java:349)
	at org.eclipse.emf.transaction.impl.TransactionChangeRecorder.appendNotification(TransactionChangeRecorder.java:303)
	at org.eclipse.papyrus.infra.emf.readonly.PapyrusROTransactionalEditingDomain$1.appendNotification(PapyrusROTransactionalEditingDomain.java:107)
	at org.eclipse.emf.transaction.impl.TransactionChangeRecorder.processResourceNotification(TransactionChangeRecorder.java:273)
	at org.eclipse.emf.transaction.impl.TransactionChangeRecorder.notifyChanged(TransactionChangeRecorder.java:239)
	at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:424)
	at org.eclipse.emf.common.notify.impl.NotifyingListImpl.dispatchNotification(NotifyingListImpl.java:261)
	at org.eclipse.emf.common.notify.impl.NotifyingListImpl.addUnique(NotifyingListImpl.java:294)
	at org.eclipse.emf.common.util.AbstractEList.add(AbstractEList.java:304)
	at org.eclipse.uml2.uml.util.UMLUtil$StereotypeApplicationHelper.addToContainmentList(UMLUtil.java:398)
	at org.eclipse.uml2.uml.util.UMLUtil$StereotypeApplicationHelper.applyStereotype(UMLUtil.java:437)
	at org.eclipse.uml2.uml.util.UMLUtil.applyStereotype(UMLUtil.java:12284)
	at org.eclipse.uml2.uml.internal.operations.ElementOperations.applyAllStereotypes(ElementOperations.java:1380)
	at org.eclipse.uml2.uml.internal.operations.ElementOperations.applyAllStereotypes(ElementOperations.java:1406)
	at org.eclipse.uml2.uml.internal.operations.ElementOperations.applyAllRequiredStereotypes(ElementOperations.java:1477)
	at org.eclipse.uml2.uml.internal.impl.ElementImpl.eBasicSetContainer(ElementImpl.java:950)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eInverseAdd(BasicEObjectImpl.java:1417)
	at org.eclipse.emf.ecore.util.EcoreEList.inverseAdd(EcoreEList.java:286)
	at org.eclipse.emf.ecore.util.EcoreEList.resolve(EcoreEList.java:176)
	at org.eclipse.emf.ecore.util.EObjectContainmentEList$Resolving.resolve(EObjectContainmentEList.java:105)
	at org.eclipse.emf.common.util.BasicEList.get(BasicEList.java:348)
	at org.eclipse.emf.ecore.util.EContentsEList$FeatureIteratorImpl.hasNext(EContentsEList.java:514)
	at org.eclipse.emf.ecore.util.EContentsEList$FeatureIteratorImpl.next(EContentsEList.java:595)
	at org.eclipse.emf.ecore.util.ECrossReferenceAdapter.setTarget(ECrossReferenceAdapter.java:921)
	at org.eclipse.emf.ecore.util.ECrossReferenceAdapter.setTarget(ECrossReferenceAdapter.java:893)
	at org.eclipse.emf.ecore.impl.MinimalEObjectImpl$1ArrayDelegatingAdapterList.didAdd(MinimalEObjectImpl.java:488)
	at org.eclipse.emf.ecore.impl.MinimalEObjectImpl$1ArrayDelegatingAdapterList.didAdd(MinimalEObjectImpl.java:1)
	at org.eclipse.emf.common.util.ArrayDelegatingEList.addUnique(ArrayDelegatingEList.java:389)
	at org.eclipse.emf.common.util.AbstractEList.add(AbstractEList.java:304)
	at org.eclipse.emf.ecore.util.ECrossReferenceAdapter.addAdapter(ECrossReferenceAdapter.java:1084)
	at org.eclipse.emf.ecore.util.ECrossReferenceAdapter.selfAdapt(ECrossReferenceAdapter.java:723)
	at org.eclipse.emf.ecore.util.ECrossReferenceAdapter.notifyChanged(ECrossReferenceAdapter.java:643)
	at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:424)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1583)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1342)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
	at org.eclipse.papyrus.infra.core.resource.ModelSet.demandLoad(ModelSet.java:380)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
	at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:220)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$ResourceLocator.basicGetResource(ResourceSetImpl.java:751)
	at org.eclipse.papyrus.infra.emf.resource.ShardResourceLocator.getResource(ShardResourceLocator.java:109)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:352)
	at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:220)
	at org.eclipse.papyrus.infra.core.resource.AbstractBaseModel.loadModel(AbstractBaseModel.java:189)
	at org.eclipse.papyrus.infra.core.resource.ModelSet.loadModels(ModelSet.java:584)
	... 96 more
Comment 10 Vincent Lorenzo CLA 2019-01-09 08:55:43 EST
Hello Jessie, 
  thank you for your model. I have no idea how you get this state, but I foudn how to fix your model easily.

1. Open the Resource file with Papyrus. Setect the property "Resource::Associations::PnfdHasPnfExtCpd::_pnfd".

2. Apply the missing required stereotype "OpenModelAttribute". 
3. Save and Close
4. Now, the model file can be open without error with Papyrus. Right ? 


I open the bug 543303 which explain the real problem you met.
In the same time, I discovered that a recent patch break the behavior of the edition of Extension#IsRequired in the Papyrus Property View, so I reopen the bug 540815. 


Can I close this bug ? 

Regards,
-- 
Vincent
Comment 11 Jessie Jewitt CLA 2019-01-09 14:30:08 EST
(In reply to vincent lorenzo from comment #10)
> Hello Jessie, 
>   thank you for your model. I have no idea how you get this state, but I
> foudn how to fix your model easily.
> 
> 1. Open the Resource file with Papyrus. Setect the property
> "Resource::Associations::PnfdHasPnfExtCpd::_pnfd".
> 
> 2. Apply the missing required stereotype "OpenModelAttribute". 
> 3. Save and Close
> 4. Now, the model file can be open without error with Papyrus. Right ? 
> 
> 
> I open the bug 543303 which explain the real problem you met.
> In the same time, I discovered that a recent patch break the behavior of the
> edition of Extension#IsRequired in the Papyrus Property View, so I reopen
> the bug 540815. 
> 
> 
> Can I close this bug ? 
> 
> Regards,
> -- 
> Vincent

Vincent-
     I have no clue how you found the problem, but indeed in applying the OpenModelAttribute to _pnfd the problem is fixed. I guess the question I have is how did a stereotype that is to automatically be applied to every attribute not get applied? And why did this cause a Papyrus issue. If bug 543303 addresses the real problem, then I am ok closing this bug.
Jessie