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

NPE in javadoc: Cannot invoke "com.sun.tools.javac.code.Type.isPrimitive()" because "t" is null)

    XMLWordPrintable

    Details

    • CPU:
      generic
    • OS:
      generic

      Description

      ADDITIONAL SYSTEM INFORMATION :
      Running inside a GitHub Action on Ubuntu with Java 11

      A DESCRIPTION OF THE PROBLEM :
      When I attempt to create javadocs via the command:

      javadoc -d ./javadoc-output $(find . -name "*.java") -public -splitindex -use -author -version -Xdoclint:none --ignore-source-errors -link https://docs.oracle.com/en/java/javase/11/docs/api/ -link https://xaverianteamrobotics.github.io/FtcRobotController/javadocs/libs/ftccommon/ -link https://xaverianteamrobotics.github.io/FtcRobotController/javadocs/libs/hardware/ -link https://xaverianteamrobotics.github.io/FtcRobotController/javadocs/libs/inspection/ -link https://xaverianteamrobotics.github.io/FtcRobotController/javadocs/libs/onbotjava/ -link https://xaverianteamrobotics.github.io/FtcRobotController/javadocs/libs/robotcore/

      The javadocs seem to generate fine until an internal error happens and the javadoc tool throws this exception:

      Generating ./javadoc-output/org/firstinspires/ftc/teamcode/main/utils/devices/package-tree.html...
      javadoc: error - An internal exception has occurred.
      (java.lang.NullPointerException: Cannot invoke "com.sun.tools.javac.code.Type.isPrimitive()" because "t" is null)
      Please file a bug against the javadoc tool via the Java bug reporting page
      (http://bugreport.java.com) after checking the Bug Database (http://bugs.java.com)
      for duplicates. Include error messages and the following diagnostic in your report. Thank you.
      java.lang.NullPointerException: Cannot invoke "com.sun.tools.javac.code.Type.isPrimitive()" because "t" is null
      at jdk.compiler/com.sun.tools.javac.code.Types.erasure(Types.java:2388)
      at jdk.compiler/com.sun.tools.javac.code.Types$14.visitTypeVar(Types.java:2446)
      at jdk.compiler/com.sun.tools.javac.code.Types$14.visitTypeVar(Types.java:2396)
      at jdk.compiler/com.sun.tools.javac.code.Type$TypeVar.accept(Type.java:1685)
      at jdk.compiler/com.sun.tools.javac.code.Types$DefaultTypeVisitor.visit(Types.java:4902)
      at jdk.compiler/com.sun.tools.javac.code.Types.erasure(Types.java:2391)
      at jdk.compiler/com.sun.tools.javac.code.Types.erasure(Types.java:2377)
      at jdk.compiler/com.sun.tools.javac.model.JavacTypes.erasure(JavacTypes.java:134)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.util.Utils$5.visitTypeVariable(Utils.java:1233)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.util.Utils$5.visitTypeVariable(Utils.java:1212)
      at jdk.compiler/com.sun.tools.javac.code.Type$TypeVar.accept(Type.java:1721)
      at java.compiler@16.0.2/javax.lang.model.util.AbstractTypeVisitor6.visit(AbstractTypeVisitor6.java:108)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.util.Utils.asTypeElement(Utils.java:1250)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.LinkInfoImpl.setContext(LinkInfoImpl.java:405)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.LinkInfoImpl.<init>(LinkInfoImpl.java:287)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.LinkFactoryImpl.getTypeParameterLink(LinkFactoryImpl.java:174)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.LinkFactoryImpl.getTypeParameterLinks(LinkFactoryImpl.java:157)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.util.links.LinkFactory.getLink(LinkFactory.java:195)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.HtmlDocletWriter.getLink(HtmlDocletWriter.java:722)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.HtmlDocletWriter.addPreQualifiedClassLink(HtmlDocletWriter.java:857)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.HtmlDocletWriter.addPreQualifiedStrongClassLink(HtmlDocletWriter.java:891)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.AbstractTreeWriter.addPartialInfo(AbstractTreeWriter.java:174)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.AbstractTreeWriter.addLevelInfo(AbstractTreeWriter.java:89)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.AbstractTreeWriter.addLevelInfo(AbstractTreeWriter.java:91)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.AbstractTreeWriter.addTree(AbstractTreeWriter.java:120)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.AbstractTreeWriter.addTree(AbstractTreeWriter.java:109)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.PackageTreeWriter.generatePackageTreeFile(PackageTreeWriter.java:108)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.PackageTreeWriter.generate(PackageTreeWriter.java:89)
      at jdk.javadoc/jdk.javadoc.internal.doclets.formats.html.HtmlDoclet.generatePackageFiles(HtmlDoclet.java:345)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:215)
      at jdk.javadoc/jdk.javadoc.internal.doclets.toolkit.AbstractDoclet.run(AbstractDoclet.java:115)
      at jdk.javadoc/jdk.javadoc.doclet.StandardDoclet.run(StandardDoclet.java:103)
      at jdk.javadoc/jdk.javadoc.internal.tool.Start.parseAndExecute(Start.java:555)
      at jdk.javadoc/jdk.javadoc.internal.tool.Start.begin(Start.java:399)
      at jdk.javadoc/jdk.javadoc.internal.tool.Start.begin(Start.java:348)
      at jdk.javadoc/jdk.javadoc.internal.tool.Main.execute(Main.java:63)
      at jdk.javadoc/jdk.javadoc.internal.tool.Main.main(Main.java:52)


      FREQUENCY : always


        Attachments

          Issue Links

            Activity

              People

              Assignee:
              adev ANUPAM DEV
              Reporter:
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: