Skip to content
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

9.0.0.0.rc1 build fails with esoteric maven error #3045

Closed
hakanai opened this issue Jun 15, 2015 · 8 comments
Closed

9.0.0.0.rc1 build fails with esoteric maven error #3045

hakanai opened this issue Jun 15, 2015 · 8 comments

Comments

@hakanai
Copy link

hakanai commented Jun 15, 2015

As is typical of any project relying on Maven to build anything, eventually an error occurs and there is no obvious way to diagnose the problem. This time it's JRuby, where I'm just trying to build 9.0.0.0.rc1 so that I can see about porting in a workaround I have made.

$ mvn -Pcomplete
[INFO] Scanning for projects...
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]   
[ERROR]   The project org.jruby:jruby-parent:9.0.0.0.rc1 (/Users/x/Documents/jruby/pom.xml) has 1 error
[ERROR]     Child module /Users/x/Documents/jruby/maven/pom.xml of /Users/x/Documents/jruby/pom.xml does not exist
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/ProjectBuildingException

The same command builds JRuby 1.7.20 successfully. I did check pom.xml to ensure that the "complete" profile still exists.

It's right about maven/pom.xml not existing, though I don't see any place in the root pom.xml referencing a file with this path, so I give up.

@hakanai
Copy link
Author

hakanai commented Jun 15, 2015

Thought I would try it without the -Pcomplete to see what happens, but that fails too.

$ mvn
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO] 
[INFO] JRuby
[INFO] JRuby Core
[INFO] JRuby Truffle
[INFO] JRuby Lib Setup
[INFO] 
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building JRuby 9.0.0.0.rc1
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (enforce-maven) @ jruby-parent ---
[INFO] 
[INFO] --- maven-install-plugin:2.4:install (default-install) @ jruby-parent ---
[INFO] Installing /Users/x/Documents/jruby/pom.xml to /Users/x/.m2/repository/org/jruby/jruby-parent/9.0.0.0.rc1/jruby-parent-9.0.0.0.rc1.pom
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building JRuby Core 9.0.0.0.rc1
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (enforce-maven) @ jruby-core ---
[INFO] 
[INFO] --- buildnumber-maven-plugin:1.2:create (jruby-revision) @ jruby-core ---
[INFO] Checking for local modifications: skipped.
[INFO] Updating project files from SCM: skipped.
[INFO] ShortRevision tag detected. The value is '7'.
[INFO] Executing: /bin/sh -c cd /Users/x/Documents/jruby/core && git rev-parse --verify --short=7 HEAD
[INFO] Working directory: /Users/x/Documents/jruby/core
[INFO] Storing buildNumber: 9f9c112 at timestamp: 1434327431693
[INFO] ShortRevision tag detected. The value is '7'.
[INFO] Executing: /bin/sh -c cd /Users/x/Documents/jruby/core && git rev-parse --verify --short=7 HEAD
[INFO] Working directory: /Users/x/Documents/jruby/core
[INFO] Storing buildScmBranch: UNKNOWN
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ jruby-core ---
[INFO] Using 'utf-8' encoding to copy filtered resources.
[INFO] Copying 36 resources
[INFO] Copying 1 resource
[INFO] Copying 1 resource to /Users/x/Documents/jruby/core/src/main/java
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (anno) @ jruby-core ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ jruby-core ---
[INFO] Compiling 1 source file to /Users/x/Documents/jruby/core/target/classes
[INFO] 
[INFO] --- build-helper-maven-plugin:1.8:add-source (add-populators) @ jruby-core ---
[INFO] Source directory: /Users/x/Documents/jruby/core/target/generated-sources added.
[INFO] 
[INFO] --- exec-maven-plugin:1.2.1:exec (invoker-generator) @ jruby-core ---
Exception in thread "main" java.lang.NoSuchFieldError: classLoader
    at org.jruby.internal.runtime.methods.DumpingInvocationMethodFactory.endClass(DumpingInvocationMethodFactory.java:64)
    at org.jruby.internal.runtime.methods.InvocationMethodFactory.getAnnotatedMethodClass(InvocationMethodFactory.java:853)
    at org.jruby.anno.InvokerGenerator.main(InvokerGenerator.java:83)
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] JRuby ............................................. SUCCESS [  0.349 s]
[INFO] JRuby Core ........................................ FAILURE [  2.474 s]
[INFO] JRuby Truffle ..................................... SKIPPED
[INFO] JRuby Lib Setup ................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.997 s
[INFO] Finished at: 2015-06-15T10:17:13+10:00
[INFO] Final Memory: 11M/310M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (invoker-generator) on project jruby-core: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/MojoExecutionException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :jruby-core

@headius
Copy link
Member

headius commented Jun 15, 2015

Hmmm...any thoughts on this @mkristian?

@enebo
Copy link
Member

enebo commented Jun 15, 2015

What version of Maven? 3.3.x is required now without using ./mvnw right?

@mkristian
Copy link
Member

for the first error: looks like it is not using mvn-3.3.x or ./mvnw from the root directory

the second error with the missing filed I did see before. mvn clean install should help.

@hakanai
Copy link
Author

hakanai commented Jun 16, 2015

Sounds spot-on.

$ mvn -v
Apache Maven 3.2.1 (ea8b2b07643dbb1b84b6d16e1f08391b666bc1e9; 2014-02-15T04:37:52+10:00)

Guess I'm updating. Nice of Maven not to just fail outright when it can't handle a build. :/

@hakanai
Copy link
Author

hakanai commented Jun 16, 2015

Yep, that was it, plus the mvn clean install worked to fix the other issue. Thanks!

@hakanai hakanai closed this as completed Jun 16, 2015
@enebo enebo added this to the Invalid or Duplicate milestone Jul 6, 2015
@enebo
Copy link
Member

enebo commented Jul 6, 2015

@mkristian Although we closed this it might be nice to get some error message if < 3.3 is being used somehow.

@mkristian
Copy link
Member

I added an enforces rule for the maven version via 7c7dfb0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants