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

Bug 353473

Summary: Epsilon does not find a model type if it is registered via EPackage.Descriptor
Product: [Modeling] Epsilon Reporter: Andrey Skorikov <proskorik>
Component: CoreAssignee: Dimitris Kolovos <dkolovos>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard: interim
Attachments:
Description Flags
Possible fix dkolovos: iplog+

Description Andrey Skorikov CLA 2011-07-31 16:07:14 EDT
Build Identifier: 20110615-0604

When i try to execute a transformation in ETL from a EMF model to another EMF model, i get following exception:

Type 'DSPN!Place' not found (3:16)
	at org.eclipse.epsilon.eol.execute.TypeExecutor.execute(TypeExecutor.java:96)
	at org.eclipse.epsilon.eol.execute.ExecutorFactory.executeAST(ExecutorFactory.java:208)
	at org.eclipse.epsilon.eol.EolFormalParameter.getType(EolFormalParameter.java:73)
	at org.eclipse.epsilon.etl.strategy.FastTransformationStrategy.transformModels(FastTransformationStrategy.java:121)
	at org.eclipse.epsilon.etl.EtlModule.execute(EtlModule.java:126)
	at test.TestCommand.execute(TestCommand.java:33)
	at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:293)
	at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
	at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
	at org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerService.java:169)
	at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241)
	at org.eclipse.ui.menus.CommandContributionItem.handleWidgetSelection(CommandContributionItem.java:829)
	at org.eclipse.ui.menus.CommandContributionItem.access$19(CommandContributionItem.java:815)
	at org.eclipse.ui.menus.CommandContributionItem$5.handleEvent(CommandContributionItem.java:805)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1258)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3588)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3209)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)
	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at de.essarel.core.rcp.intro.Application.start(Application.java:133)
	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:344)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1386)

It happens every time I use an InMemoryEmfModel, but only if the EPackage is registered via an EPackage.Descriptor.

Reproducible: Always

Steps to Reproduce:
1. Create two EMF metamodels and register the packages via extension point org.eclipse.emf.ecore.generated_package.
2. Set up two InMemoryEmfModels and define some rules in ETL.
2. Run the transformation.
Comment 1 Andrey Skorikov CLA 2011-07-31 16:10:05 EDT
Created attachment 200635 [details]
Possible fix

This patch fixes the problem for me.
I changed the code so it does not skip the packages registered via EPackage.Descriptor.
Comment 2 Dimitris Kolovos CLA 2012-01-09 03:05:01 EST
This has been fixed in the SVN and will appear in the next interim version.
Comment 3 Dimitris Kolovos CLA 2012-07-03 06:34:53 EDT
This has been fixed in the latest interim version.
Comment 4 Dimitris Kolovos CLA 2012-11-08 16:43:38 EST
Fixed in 1.0