Uploaded image for project: 'ShrinkWrap'
  1. ShrinkWrap
  2. SHRINKWRAP-521

Can't compile without compile without JAVA_HOME set, due to NPE in JavacCompiler

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Trivial Trivial
    • None
    • None
    • None
    • None

      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.

            Unassigned Unassigned
            jan-willem-1 Jan-Willem Gmelig Meyling (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: