Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8296390

Incremental build failed with a NPE

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • 20
    • 20
    • tools
    • None
    • b26

    Description

      An incremental build involving modified source files, but not modified module-info.java, from java.management, failed with:
      ---
      Building target 'default (exploded-image)' in configuration 'linux-x86_64-server-release'
      Compiling up to 56 files for java.sql.rowset
      Compiling up to 97 files for jdk.jshell
      Compiling up to 30 files for jdk.security.auth
      Compiling up to 941 files for jdk.hotspot.agent
      An exception has occurred in the compiler (20-internal). Please file a bug against the Java compiler via the Java bug reporting page (https://bugreport.java.com) after checking the Bug Database (https://bugs.java.com) for duplicates. Include your program, the following diagnostic, and the parameters passed to the Java compiler in your report. Thank you.
      java.lang.NullPointerException: Cannot invoke "java.util.Map.get(Object)" because "msym.visiblePackages" is null
              at jdk.compiler.interim/com.sun.tools.javac.code.Symtab.lookupPackage(Symtab.java:713)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symtab.lookupPackage(Symtab.java:694)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.lookupPackage(Resolve.java:2140)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.findIdentInternal(Resolve.java:2440)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.findIdent(Resolve.java:2419)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.resolveIdent(Resolve.java:2712)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitIdent(Attr.java:4268)
              at jdk.compiler.interim/com.sun.tools.javac.tree.JCTree$JCIdent.accept(JCTree.java:2664)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:662)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitSelect(Attr.java:4345)
              at jdk.compiler.interim/com.sun.tools.javac.tree.JCTree$JCFieldAccess.accept(JCTree.java:2530)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:662)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitSelect(Attr.java:4345)
              at jdk.compiler.interim/com.sun.tools.javac.tree.JCTree$JCFieldAccess.accept(JCTree.java:2530)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:662)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribImportQualifier(Attr.java:396)
              at jdk.compiler.interim/com.sun.tools.javac.comp.TypeEnter$ImportsPhase.doImport(TypeEnter.java:416)
              at jdk.compiler.interim/com.sun.tools.javac.comp.TypeEnter$ImportsPhase.resolveImports(TypeEnter.java:365)
              at jdk.compiler.interim/com.sun.tools.javac.comp.TypeEnter.lambda$ensureImportsChecked$0(TypeEnter.java:167)
              at jdk.compiler.interim/com.sun.tools.javac.comp.TypeEnter.finishImports(TypeEnter.java:219)
              at jdk.compiler.interim/com.sun.tools.javac.comp.TypeEnter.ensureImportsChecked(TypeEnter.java:167)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Enter.complete(Enter.java:626)
              at jdk.compiler.interim/com.sun.tools.javac.main.JavaCompiler.readSourceFile(JavaCompiler.java:822)
              at jdk.compiler.interim/com.sun.tools.javac.main.JavaCompiler.readSourceFile(JavaCompiler.java:779)
              at jdk.compiler.interim/com.sun.tools.javac.main.JavaCompiler.lambda$new$0(JavaCompiler.java:342)
              at jdk.compiler.interim/com.sun.tools.javac.code.ClassFinder.fillIn(ClassFinder.java:378)
              at jdk.compiler.interim/com.sun.tools.javac.code.ModuleFinder$1.complete(ModuleFinder.java:387)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symbol.complete(Symbol.java:682)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symbol$ClassSymbol.complete(Symbol.java:1410)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Modules$1.complete(Modules.java:641)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symbol.complete(Symbol.java:682)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Modules.completeModule(Modules.java:1512)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Modules.lambda$completeModule$19(Modules.java:1474)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symbol.complete(Symbol.java:682)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Modules.enter(Modules.java:272)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Modules.initModules(Modules.java:233)
              at jdk.compiler.interim/com.sun.tools.javac.main.JavaCompiler.initModules(JavaCompiler.java:1022)
              at jdk.compiler.interim/com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:920)
              at jdk.compiler.interim/com.sun.tools.javac.main.Main.compile(Main.java:317)
              at jdk.compiler.interim/com.sun.tools.sjavac.comp.SjavacImpl.compile(SjavacImpl.java:117)
              at jdk.compiler.interim/com.sun.tools.sjavac.comp.PooledSjavac.lambda$compile$0(PooledSjavac.java:63)
              at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
              at java.base/java.lang.Thread.run(Thread.java:1589)
      printing javac parameters to: /home/jlahoda/src/jdk/jdk/make/javac.20221104_105809.args
      gmake[3]: *** [CompileJavaModules.gmk:95: /home/jlahoda/src/jdk/jdk/build/linux-x86_64-server-release/jdk/modules/java.management/_the.java.management_batch] Error 4
      gmake[2]: *** [make/Main.gmk:193: java.management-java] Error 2
      gmake[2]: *** Waiting for unfinished jobs....
      Updating support/modules_libs/java.desktop/libsplashscreen.so due to 6 file(s)

      ERROR: Build failed for target 'default (exploded-image)' in configuration 'linux-x86_64-server-release' (exit code 2)
      Stopping sjavac server

      === Output from failing command(s) repeated here ===
      * For target jdk_modules_java.management__the.java.management_batch:
      An exception has occurred in the compiler (20-internal). Please file a bug against the Java compiler via the Java bug reporting page (https://bugreport.java.com) after checking the Bug Database (https://bugs.java.com) for duplicates. Include your program, the following diagnostic, and the parameters passed to the Java compiler in your report. Thank you.
      java.lang.NullPointerException: Cannot invoke "java.util.Map.get(Object)" because "msym.visiblePackages" is null
              at jdk.compiler.interim/com.sun.tools.javac.code.Symtab.lookupPackage(Symtab.java:713)
              at jdk.compiler.interim/com.sun.tools.javac.code.Symtab.lookupPackage(Symtab.java:694)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.lookupPackage(Resolve.java:2140)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.findIdentInternal(Resolve.java:2440)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.findIdent(Resolve.java:2419)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Resolve.resolveIdent(Resolve.java:2712)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitIdent(Attr.java:4268)
              at jdk.compiler.interim/com.sun.tools.javac.tree.JCTree$JCIdent.accept(JCTree.java:2664)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:662)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitSelect(Attr.java:4345)
              at jdk.compiler.interim/com.sun.tools.javac.tree.JCTree$JCFieldAccess.accept(JCTree.java:2530)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:662)
              at jdk.compiler.interim/com.sun.tools.javac.comp.Attr.visitSelect(Attr.java:4345)
         ... (rest of output omitted)

      * All command lines available in /home/jlahoda/src/jdk/jdk/build/linux-x86_64-server-release/make-support/failure-logs.
      === End of repeated output ===

      No indication of failed target found.
      HELP: Try searching the build log for '] Error'.
      HELP: Run 'make doctor' to diagnose build problems.

      make[1]: *** [/home/jlahoda/src/jdk/jdk/make/Init.gmk:320: main] Error 2
      make: *** [/home/jlahoda/src/jdk/jdk/make/Init.gmk:186: default] Error 2
      ---

      Attachments

        Issue Links

          Activity

            People

              jlahoda Jan Lahoda
              jlahoda Jan Lahoda
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: