Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [papyrus-rt-dev] Bug from Papyrus

Hi, Ernesto,

See some follow-up, in-line.

cW



On 3 November, 2016 at 12:13:28, Ernesto Posse (eposse@xxxxxxxxxxxxx) wrote:

A couple of questions inline below.


On Wed, Nov 2, 2016 at 5:21 PM Christian Damus <give.a.damus@xxxxxxxxx> wrote:
Hi, Ernesto,

See some replies in-line, below.

HTH,

Christian



On 2 November, 2016 at 16:00:57, Ernesto Posse (eposse@xxxxxxxxxxxxx) wrote:

I'm not on Oxygen. I recreated the dev environment to make sure I was on Neon.1. I have installed in my dev environment a few extras such as:

a) CDT
b) CMake Editor
c) Dynamic Languages Toolkit - ShellEd IDE
d) Ecore Diagram Editor (SDK)


There has been a history of incompatibility between the ECore Diagram Editor and GMF-based applications, in particular Papyrus.  IIRC, older releases up to something like 2.0 were okay to combine with Papyrus but the latest releases, not so much.  But I don't know the details.  Issues have been raised numerous times in the EMF and/or Papyrus forum; googling may find you some useful details.

Myself, I always do my class modeling in UML, with Papyrus for diagrams.  It’s like Ecore++:  compatible with ECore, with several very useful extras.


Interesting. I didn't think of that. I'm using the ECore diagram editor to edit our XtUML-RT models. I suppose that to replace it with Papyrus one would use the UML import to create the EMF projects? How reliable is that import?  


The round-tripping between UML and Ecore that is implemented by the UML2 model importer and exporter is quite solid.


I would need migrate existing projects created with the Ecore Diagram Editor to Papyrus. This editor is based on Sirius, so I'd expect that we would have to remove the corresponding (Sirius-based) "represenations" (.aird) file.


I suppose so.  I don’t know much about Sirius.


We originally created these models in collaboration with IncQuery Labs. and Ericsson Hungary, using the Ecore Diagram Editor with its views and all that. Now, they have not been involved in it for a while, but I'm loath to make substantial modifications to plugins that may still be used by others and affect them and forcing them to switch to a different way of working with the models. If changing to Papyrus is not disruptive, I won't have a problem with it, but if it is disruptive, it might be better to avoid it. 


I use UML because the codegen extensions in UML2 for the semantics of UML class models offer advantages that I enjoy.  Obviously, importing your existing Ecore models into UML won’t take advantage of those because they aren’t in your models, yet, so I can’t say that it would be worthwhile to migrate your models.  There are a few purely codegen-related things that don’t require changing the actual model (e.g., creation methods, operations classes for multiple inheritance).  I suppose it might be useful depending on what kind of evolution you anticipate in these models.


I don't think any of these should be relevant. b) and c), strictly speaking, are not necessary, but it's a pain not to have them. But I couldn't do without a) and d). 

My launch configuration is set to use "all workspace and enabled target plug-ins".


Yeah, I never do that.  Only the features that are actually supposed to be in Papyrus(-RT).  And certainly not the tests.

I do have some unrelated projects in my workspace, but I close them before launching. I do however keep the Papyrus-RT test bundles open. These shouldn't cause any trouble, should they? I would expect that the dev environment should work as smoothly as possible with whatever we have in the repo.


I don’t know about the Papyrus-RT tests, in particular, but there are Papyrus test bundles that add all sorts of weird extensions that make for a bizarre user experience in the tool.


In any case, the error is a very Papyrus-specific error. "Registry should be started before" ??? What sort of thing can cause Papyrus to raise that?


Attempt to get a service out of the ServicesRegistry of the model editor (or other usage of a ModelSet) before the registry has been started. 


How do I do that? I don't see any options for the ServiceRegistry in either the Model Explorer or the Papyrus Preference pages.


I don’t understand.  What are you trying to do now?  I was just saying that some code seems to be requesting a service from the registry before the registry is started.  I have no idea where in the code, but I doubt it’s in the preference pages.


But what component is doing that?  Perhaps you can provide more of the stack.


See the trace at the end. It looks like it's the "ViewerSearchService". 


Oh.  That looks like you’re opening a context menu when this exception happens.  It sounded like this was an exception that were seeing when Papyrus start up.

Which menu on what thing in the UI?  None of the navigation-oriented context menus or menu-bar menus that I can find in Papyrus cause this exception.  Maybe it’s not a Papyrus menu?


I may change my launch configuration as you suggest, but that has the drawback that if something new is added, you have to remember to manually update the launch configuration, and in the past I fell for that. It's very easy to forget to update this.


That’s why assembling the launch config from features is so handy.  Unless there’s a whole new feature to add, you can’t just forget a bundle here or there.  And because, unlike Papyrus, Papyrus-RT doesn’t define features for the tests, you can probably just let the launch config find all features in your workspace and target, which gives you the best of both worlds.

Well, except that I already installed other stuff, so I have to either go through the list of features and make sure I select only the Papyrus-RT features, or start a new dev environment from scratch (again). In the past I tried it and things where still missing. Perhaps it's better now, but I just tried it, and did the following: 1) deselected all features (so that I wouldn't have the extras); 2) selected the oeprt feature; 3) clickes on "Select Required", and it only added the oeprt.common, .common.ui, .core, .cpp, .profile and .tooling features. It didn't add the .codegen, .rts, xtumlrt or compare features, or anything down the line, in particular it didn't add the Papyrus features or event the eclipse platform. Addint the oeprt.rcp feature resulted in no changes. What's more, even if I select all features, and I click on "Validate Plug-ins", it shows a bunch of validation errors, related mostly to oep.infra.gmfdiag.common and dependencies to something called 'org.apache.batik.*".


Yes, I think the 'Select Required' only works with manifest dependencies.  It won’t know about Papyrus features because we only have dependencies to Papyrus bundles.  I guess it finds some Papyrus-RT features because we have features that contain and/or import other features.

In my launch configs, I do have to add the Batik bundles as extras because there is no feature anywhere that includes them.  Likewise org.eclipse.equinox.ds.  The Batik dependencies are the cause of the org.eclipse.papyrus.infra.gmfdiag.* issues.







 




--
Ernesto Posse
Zeligsoft


org.eclipse.papyrus.infra.core.services.BadStateException: Registry should be started before. (Service= 'org.eclipse.papyrus.infra.services.viewersearch.impl.ViewerSearchService', state= registered)
at org.eclipse.papyrus.infra.core.services.ServicesRegistry.getService(ServicesRegistry.java:406)
at org.eclipse.papyrus.infra.core.utils.AbstractServiceUtils.getService(AbstractServiceUtils.java:117)
at org.eclipse.papyrus.infra.gmfdiag.navigation.ui.DynamicNavigate.getViewsToSelect(DynamicNavigate.java:120)
at org.eclipse.papyrus.infra.gmfdiag.navigation.ui.ModelExplorerDynamicNavigate.fill(ModelExplorerDynamicNavigate.java:50)
at org.eclipse.ui.internal.menus.DynamicMenuContributionItem.fill(DynamicMenuContributionItem.java:147)
at org.eclipse.jface.action.MenuManager.doItemFill(MenuManager.java:728)
at org.eclipse.jface.action.MenuManager.update(MenuManager.java:810)
at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:472)
at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:465)
at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:497)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:256)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4248)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1501)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1524)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1505)
at org.eclipse.swt.widgets.Menu.menuWillOpen(Menu.java:805)
at org.eclipse.swt.widgets.Display.windowProc(Display.java:5779)
at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method)
at org.eclipse.swt.internal.cocoa.NSMenu.popUpContextMenu(NSMenu.java:77)
at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:267)
at org.eclipse.swt.widgets.Display.runPopups(Display.java:4149)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3691)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1121)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1022)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:150)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:687)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:604)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:138)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
at org.eclipse.equinox.launcher.Main.run(Main.java:1519)
at org.eclipse.equinox.launcher.Main.main(Main.java:1492)

 
_______________________________________________ 
papyrus-rt-dev mailing list 
papyrus-rt-dev@xxxxxxxxxxx 
To change your delivery options, retrieve your password, or unsubscribe from this list, visit 
https://dev.eclipse.org/mailman/listinfo/papyrus-rt-dev 

Back to the top