Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [Acceleo] Error launching main module as Acceleo Application
[Acceleo] Error launching main module as Acceleo Application [message #933114] Thu, 04 October 2012 18:50 Go to next message
Luís de Sousa is currently offline Luís de Sousa
Messages: 142
Registered: July 2009
Senior Member
Dear all,

I'm starting a new Acceleo project and whenever I try to launch a main module as an Acceleo application I get the following error in the log:

Quote:
Message: Couldn't load class dsl3s.templates.Main from project DSL3S

Exception Stack Trace:

An exception stack trace is not available.

Session Data:
eclipse.buildId=M20110909-1335
java.version=1.6.0_26
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_US
Framework arguments: -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product
Command-line arguments: -os linux -ws gtk -arch x86 -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product -data /media/Data/users/lads/Trabalho/Eclipse/Workspace.DSL3S -product org.eclipse.epp.package.java.product


This happens with all main modules in the project. I have verified that all packages containing main modules are exported in the MANIFEST file.

I understand there is little information here. How can I provide more useful details?

Thank you,

Luís


Re: [Acceleo] Error launching main module as Acceleo Application [message #934838 is a reply to message #933114] Sat, 06 October 2012 11:02 Go to previous messageGo to next message
Luís de Sousa is currently offline Luís de Sousa
Messages: 142
Registered: July 2009
Senior Member
Hello again,

Here in attachment goes a fresh Acceleo project that reproduces the error. If I try to launch the module test.mtl I get the error in the previous message. At the same time I'm getting also this warning:

Quote:

Message: Couldn't load class test.Test. Check that its containing package is exported.

Exception Stack Trace:

An exception stack trace is not available.

Session Data:
eclipse.buildId=M20110909-1335
java.version=1.6.0_26
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_US
Framework arguments: -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product
Command-line arguments: -os linux -ws gtk -arch x86 -product org.eclipse.epp.package.java.product -data /media/Data/users/lads/Trabalho/Eclipse/Workspace.DSL3S -product org.eclipse.epp.package.java.product


But as you can see in the project the export is there:

Export-Package: New.common


Besides this I can't provide much more information besides the software versions:

  Acceleo	3.3.0.v20120529-1042	org.eclipse.acceleo.feature.group	Eclipse Modeling Project
  MDT Papyrus - SDK: Runtime, Tools, Documentation and sources (Incubation)	0.8.1.v201109161105	org.eclipse.papyrus.sdk.feature.group	Eclipse Modeling Project

Eclipse:
Version: Indigo Service Release 1
Build id: 20110916-0149


Needless to say that I can't do any work with Acceleo right now. Please help.

Luís
Re: [Acceleo] Error launching main module as Acceleo Application [message #935833 is a reply to message #934838] Sun, 07 October 2012 11:10 Go to previous messageGo to next message
Ed Willink is currently offline Ed Willink
Messages: 4058
Registered: July 2009
Senior Member
Hi

If you look at the bottom of the auto-generated Test.java you will see
some instructions on how to register packages such as UML. Try following
them.

Regards

Ed Willink



On 06/10/2012 12:02, Luís de Sousa wrote:
> Hello again,
>
> Here in attachment goes a fresh Acceleo project that reproduces the error. If I try to launch the module test.mtl I get the error in the previous message. At the same time I'm getting also this warning:
>
> Quote:
>> Message: Couldn't load class test.Test. Check that its containing package is exported.
>>
>> Exception Stack Trace:
>> An exception stack trace is not available.
>>
>> Session Data:
>> eclipse.buildId=M20110909-1335
>> java.version=1.6.0_26
>> java.vendor=Sun Microsystems Inc.
>> BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_US
>> Framework arguments: -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product
>> Command-line arguments: -os linux -ws gtk -arch x86 -product org.eclipse.epp.package.java.product -data /media/Data/users/lads/Trabalho/Eclipse/Workspace.DSL3S -product org.eclipse.epp.package.java.product
>
> But as you can see in the project the export is there:
>
> Export-Package: New.common
>
> Besides this I can't provide much more information besides the software versions:
>
> Acceleo 3.3.0.v20120529-1042 org.eclipse.acceleo.feature.group Eclipse Modeling Project
> MDT Papyrus - SDK: Runtime, Tools, Documentation and sources (Incubation) 0.8.1.v201109161105 org.eclipse.papyrus.sdk.feature.group Eclipse Modeling Project
>
> Eclipse:
> Version: Indigo Service Release 1
> Build id: 20110916-0149
>
> Needless to say that I can't do any work with Acceleo right now. Please help.
>
> Luís
>
Re: [Acceleo] Error launching main module as Acceleo Application [message #941688 is a reply to message #933114] Fri, 12 October 2012 19:22 Go to previous messageGo to next message
Luís de Sousa is currently offline Luís de Sousa
Messages: 142
Registered: July 2009
Senior Member
Hi Ed, thank you once again for your help. For future reference here's the line I added to the registerResourceFactories method:

resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put("New.common", New.common.Test.this);


Regards.
Re: [Acceleo] Error launching main module as Acceleo Application [message #942142 is a reply to message #941688] Sat, 13 October 2012 07:01 Go to previous messageGo to next message
Ed Willink is currently offline Ed Willink
Messages: 4058
Registered: July 2009
Senior Member
Hi

Your line looks extremely suspect:

"New.common" is not an extension such as "*.common".

New.common.Test.this is unlikely to be a Resource Factory.

So you can probably delete the line because it does nothing.

Regards

Ed Willink


On 12/10/2012 20:22, Luís de Sousa wrote:
> Hi Ed, thank you once again for your help. For future reference here's
> the line I added to the registerResourceFactories method:
>
> resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put("New.common",
> New.common.Test.this);
>
> Regards.
Re: [Acceleo] Error launching main module as Acceleo Application [message #966864 is a reply to message #942142] Thu, 01 November 2012 09:49 Go to previous message
Luís de Sousa is currently offline Luís de Sousa
Messages: 142
Registered: July 2009
Senior Member
My apologies for the belated response.

Ed Willink wrote on Sat, 13 October 2012 03:01
Hi

Your line looks extremely suspect:

"New.common" is not an extension such as "*.common".

New.common.Test.this is unlikely to be a Resource Factory.

So you can probably delete the line because it does nothing.


Actually the template started running after including that, so it might do something after all...

In any case, given the project I attached here, what would be the correct content of this line?

Thank you.
Previous Topic:[Acceleo] Path in generated EMTL files differ when in debug or deployed
Next Topic:Executing a workflow (MWE) using a Model.xmi which is not part of a resource
Goto Forum:
  


Current Time: Wed Oct 01 14:35:53 GMT 2014

Powered by FUDForum. Page generated in 0.02524 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software