[shrinkwrap-issues] [JBoss JIRA] (SHRINKWRAP-521) Can't compile without compile without JAVA_HOME set, due to NPE in JavacCompiler
Jan-Willem Gmelig Meyling (JIRA)
issues at jboss.org
Mon Jul 9 11:52:00 EDT 2018
Jan-Willem Gmelig Meyling created SHRINKWRAP-521:
----------------------------------------------------
Summary: Can't compile without compile without JAVA_HOME set, due to NPE in JavacCompiler
Key: SHRINKWRAP-521
URL: https://issues.jboss.org/browse/SHRINKWRAP-521
Project: ShrinkWrap
Issue Type: Bug
Reporter: Jan-Willem Gmelig Meyling
Priority: Trivial
If JAVA_HOME is not set, the Plexus JavacCompiler will fallback to "which javac". However, this statement is logged without a proper check that checks whether logging is enabled (see my pull request https://github.com/codehaus-plexus/plexus-compiler/pull/52 ). Because Shrinkwrap does not attach a logger to the JavacCompiler, and this issue in Plexus Compiler, the JavacCompiler will throw a null pointer exception during compilation causing the test run to fail.
I've already proposed a PR to Plexus Compiler, but perhaps it is a good idea to attach a logger anyway so that compilation output can be printed to the logging output, which will also resolve this issue.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the shrinkwrap-issues
mailing list