New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generator: Path to model files has to be converted into a proper EMF file URI - otherwise on Windows the drive letter is misinterpreted as opaque scheme (again :-( ) #148

Closed
arpanm opened this Issue Sep 7, 2014 · 3 comments

Comments

Projects
None yet
2 participants
@arpanm

arpanm commented Sep 7, 2014

While following the helloworld tutorial with latest versions, getting following error. It looks same as #39 but happening in latest build.
Environment: Windows 8.1, Java jdk-8u20-windows-x64 , Maven apache-maven-3.2.3

The error is seen from both eclipse and command line mvn clean install -X:

[DEBUG] Executing workflow with model from 'C:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'
[DEBUG] Updating configuration with {outputSlot.path.TO_GEN_SRC_TEST=C:\dev\ayuravati\ayuravati\src\test\generated\java, outputSlot.path.TO_SRC=C:\dev\ayur
avati\ayuravati\src\main\java, outputSlot.path.TO_GEN_RESOURCES=C:\dev\ayuravati\ayuravati\src\generated\resources, outputSlot.path.TO_RESOURCES=C:\dev\ayu
ravati\ayuravati\src\main\resources, outputSlot.path.TO_RESOURCES_TEST=C:\dev\ayuravati\ayuravati\src\test\resources, outputSlot.path.TO_GEN_SRC=C:\dev\ayu
ravati\ayuravati\src\generated\java, outputSlot.path.TO_GEN_RESOURCES_TEST=C:\dev\ayuravati\ayuravati\src\test\generated\resources, outputSlot.path.TO_DOC=
C:\dev\ayuravati\ayuravati\src\site, outputSlot.path.TO_SRC_TEST=C:\dev\ayuravati\ayuravati\src\test\java, outputSlot.path.TO_WEBROOT=C:\dev\ayuravati\ayur
avati\src\main\webapp}
[DEBUG] Reading model from 'C:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 25.390 s
[INFO] Finished at: 2014-09-08T00:17:57+05:30
[INFO] Final Memory: 20M/228M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.sculptorgenerator:sculptor-maven-plugin:3.0.5:generate (code-generation) on project ayuravati: Execution code-generation
 of goal org.sculptorgenerator:sculptor-maven-plugin:3.0.5:generate failed: Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\mod
el.btdesign'; a registered resource factory is needed -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.sculptorgenerator:sculptor-maven-plugin:3.0.5:generate (code-generation)
 on project ayuravati: Execution code-generation of goal org.sculptorgenerator:sculptor-maven-plugin:3.0.5:generate failed: Cannot create a resource for 'c
:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'; a registered resource factory is needed
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
        at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
        at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
        at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:347)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:154)
        at org.apache.maven.cli.MavenCli.execute(MavenCli.java:582)
        at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
        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:483)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution code-generation of goal org.sculptorgenerator:sculptor-maven-plugin:3.0.5:generate f
ailed: Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'; a registered resource factory is needed
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:143)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
        ... 19 more
Caused by: java.lang.RuntimeException: Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'; a registered resource f
actory is needed
        at org.eclipse.xtext.resource.XtextResourceSet.getResource(XtextResourceSet.java:198)
        at org.eclipse.xtext.resource.SynchronizedXtextResourceSet.getResource(SynchronizedXtextResourceSet.java:24)
        at org.sculptor.generator.workflow.SculptorGeneratorWorkflow.readModel(SculptorGeneratorWorkflow.java:181)
        at org.sculptor.generator.workflow.SculptorGeneratorWorkflow.run(SculptorGeneratorWorkflow.java:106)
        at org.sculptor.generator.SculptorGeneratorRunner.run(SculptorGeneratorRunner.java:48)
        at org.sculptor.maven.plugin.GeneratorMojo.doRunGenerator(GeneratorMojo.java:474)
        at org.sculptor.maven.plugin.GeneratorMojo.executeGenerator(GeneratorMojo.java:439)
        at org.sculptor.maven.plugin.GeneratorMojo.execute(GeneratorMojo.java:223)
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
        ... 20 more
[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException

@arpanm arpanm changed the title from annot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\mod el.btdesign'; a registered resource factory is needed to Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\mod el.btdesign'; a registered resource factory is needed Sep 7, 2014

@tjuerge tjuerge self-assigned this Sep 7, 2014

@tjuerge tjuerge changed the title from Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\mod el.btdesign'; a registered resource factory is needed to Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'; a registered resource factory is needed Sep 7, 2014

@tjuerge tjuerge changed the title from Cannot create a resource for 'c:\dev\ayuravati\ayuravati\src\main\resources\model.btdesign'; a registered resource factory is needed to Generator: Path to model files has to be converted into a proper EMF file URI - otherwise on Windows the drive letter is misinterpreted as opaque scheme (again :-( ) Sep 7, 2014

@tjuerge

This comment has been minimized.

Show comment
Hide comment
@tjuerge

tjuerge Sep 7, 2014

Member

Indeed, this is a regression of #39. During conversion of the MWE2 workflow script into a Xtend class in #8 the necessary conversion of the given file (via URI.createFileURI(modelFile).toString()) slipped.

Thanx for spotting this. Please use Sculptor version 3.0.4 until a new version is released.

Member

tjuerge commented Sep 7, 2014

Indeed, this is a regression of #39. During conversion of the MWE2 workflow script into a Xtend class in #8 the necessary conversion of the given file (via URI.createFileURI(modelFile).toString()) slipped.

Thanx for spotting this. Please use Sculptor version 3.0.4 until a new version is released.

@tjuerge tjuerge added this to the 3.0.6 milestone Sep 8, 2014

@tjuerge tjuerge closed this in 96a0adf Sep 8, 2014

@tjuerge tjuerge added 3 - Done and removed 2 - Working labels Sep 8, 2014

@arpanm

This comment has been minimized.

Show comment
Hide comment
@arpanm

arpanm Sep 9, 2014

What is the sculptor version in mvn repository to use, if I want the fix?

arpanm commented Sep 9, 2014

What is the sculptor version in mvn repository to use, if I want the fix?

@tjuerge

This comment has been minimized.

Show comment
Hide comment
@tjuerge
Member

tjuerge commented Sep 9, 2014

The hotfix release 3.0.6 is available on Maven Central.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment