• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • warnings-plugin
    • None
    • Debian 3.2.65-1+deb7u2
      Oracle JRE 1.8.0_45-b14
      Jenkins 1.634
      warnings 4.51
      Jenkins gets started by java -jar jenkins.war

      Although JavaDoc finds errors and these are displayed in the console for that build, the warnings plugin does not show them in its report.

      There are five successful builds in the history before I triggerd the job again. Below i will paste some output from the console:

      [...]
      [javadoc] Generating Javadoc
      [javadoc] Javadoc execution
      [javadoc] Loading source files for package XXX...
      [javadoc] Constructing Javadoc information...
      [javadoc] Standard Doclet version 1.8.0_45
      [javadoc] Building tree for all the packages and classes...
      [javadoc] /home/XXX/.jenkins/jobs/SDK/workspace/Commons/src/de/XXX/XXX/commons/JBossDatasourceController.java:12: error: package org.jboss.as.cli does not exist
      [javadoc] import org.jboss.as.cli.CommandContext;
      [javadoc]                        ^
      [... more Javadoc errors are displayed ...]
      [javadoc] 9 errors
      BUILD SUCCESSFUL
      Total time: 4 seconds
      [... TASKS plugin output ...]
      [WARNINGS] Parsing warnings in console log with parser Java Compiler (javac)
      [WARNINGS] Parsing warnings in console log with parser JavaDoc Tool
      [WARNINGS] Computing warning deltas based on reference build #57
      [WARNINGS] Ignore new warnings since this is the first valid build
      [WARNINGS] Plug-in Resultat: Erfolgreich - Kein Grenzwert wurde überschritten
      

      As you can see, there are errors but they are either ignored or not found.

      As a side note, many other plugins like TASKS, CHECKSTYLE and FINDBUGS also print "Ignore new warnings since this is the first valid build" during the post build process, so maybe the root of this problem is not the warnings plugin?

          [JENKINS-32298] JavaDoc console warnings are irgnored

          Ulli Hafner added a comment -

          Seems that the JavaDoc Tool did change the output format: supported format. Currently only warnings are actually parsed. Are there no 'warning' messages in the console anymore, only 'error' messages?

          I'm not sure if one regexp can be used to parse both formats. Maybe a new parser is required. Interested in providing a pull request?

          Ulli Hafner added a comment - Seems that the JavaDoc Tool did change the output format: supported format . Currently only warnings are actually parsed. Are there no 'warning' messages in the console anymore, only 'error' messages? I'm not sure if one regexp can be used to parse both formats. Maybe a new parser is required. Interested in providing a pull request?

          Benny Prange added a comment -

          After further investigation, JavaDoc did not change the output.
          Because of some missing imports, JavaDoc was just unable to generate the docs. That's why errors instead of warnings were returned. In my opinion these errors should not be parsed by this plugin but our build scripts should have failed.
          Therefore I think this issue can be closed, thank you for your support.

          Benny Prange added a comment - After further investigation, JavaDoc did not change the output. Because of some missing imports, JavaDoc was just unable to generate the docs. That's why errors instead of warnings were returned. In my opinion these errors should not be parsed by this plugin but our build scripts should have failed. Therefore I think this issue can be closed, thank you for your support.

          Bob Jacobsen added a comment -

          I think there has been a change to the JavaDoc warning format in Java 1.8. The following aren't being seen by the plugin:

          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/Apps.java:683: warning: no description for @param
          [javadoc] * @param wi
          [javadoc] ^
          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:85: warning: no description for @param
          [javadoc] * @param menuBar
          [javadoc] ^
          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:86: warning: no description for @param
          [javadoc] * @param wi
          [javadoc] ^
          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:190: warning: no description for @param
          [javadoc] * @param menuBar

          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottle.java:25: error: bad use of '>'
          [javadoc] * <li> MT-L757<;>L757 On T throttle, remove loco L757. (Still has L1234)
          [javadoc] ^
          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottleController.java:26: error: malformed HTML
          [javadoc] * Includes a separator - <;>
          [javadoc] ^
          [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottleController.java:26: error: bad use of '>'
          [javadoc] * Includes a separator - <;>

          Bob Jacobsen added a comment - I think there has been a change to the JavaDoc warning format in Java 1.8. The following aren't being seen by the plugin: [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/Apps.java:683: warning: no description for @param [javadoc] * @param wi [javadoc] ^ [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:85: warning: no description for @param [javadoc] * @param menuBar [javadoc] ^ [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:86: warning: no description for @param [javadoc] * @param wi [javadoc] ^ [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/apps/AppsLaunchFrame.java:190: warning: no description for @param [javadoc] * @param menuBar [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottle.java:25: error: bad use of '>' [javadoc] * <li> MT-L757<;>L757 On T throttle, remove loco L757. (Still has L1234) [javadoc] ^ [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottleController.java:26: error: malformed HTML [javadoc] * Includes a separator - <;> [javadoc] ^ [javadoc] /var/lib/jenkins/jobs/Development/jobs/JavaDoc check/workspace/java/src/jmri/jmrit/withrottle/MultiThrottleController.java:26: error: bad use of '>' [javadoc] * Includes a separator - <;>

          Ulli Hafner added a comment -

          Are there warnings that get shown and warnings that are not shown? Or are no warnings shown at all in 1.8. (The regexp currently scans for a dash after the warning label, your log file does use a colon as separator.

          Ulli Hafner added a comment - Are there warnings that get shown and warnings that are not shown? Or are no warnings shown at all in 1.8. (The regexp currently scans for a dash after the warning label, your log file does use a colon as separator.

          Code changed in jenkins
          User: Ulli Hafner
          Path:
          src/main/java/hudson/plugins/warnings/parser/JavaDocParser.java
          src/test/java/hudson/plugins/warnings/parser/JavaDocParserTest.java
          src/test/resources/hudson/plugins/warnings/parser/issue32298.txt
          warnings.iml
          http://jenkins-ci.org/commit/warnings-plugin/5d40b252f24ddd4ee688dfe7452cc9d57938daaa
          Log:
          [FIXED JENKINS-32298] Update of regexp for JavaDoc 1.8 warnings.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: src/main/java/hudson/plugins/warnings/parser/JavaDocParser.java src/test/java/hudson/plugins/warnings/parser/JavaDocParserTest.java src/test/resources/hudson/plugins/warnings/parser/issue32298.txt warnings.iml http://jenkins-ci.org/commit/warnings-plugin/5d40b252f24ddd4ee688dfe7452cc9d57938daaa Log: [FIXED JENKINS-32298] Update of regexp for JavaDoc 1.8 warnings.

          Ulli Hafner added a comment -

          Note that the message consists of several lines now. This information is not shown since the parsers scans only a single line.

          Ulli Hafner added a comment - Note that the message consists of several lines now. This information is not shown since the parsers scans only a single line.

          Code changed in jenkins
          User: Ulli Hafner
          Path:
          src/test/java/hudson/plugins/warnings/parser/ParserRegistryTest.java
          http://jenkins-ci.org/commit/warnings-plugin/cadfb2a071bf1045b9c74af45b9ea1cf57958e74
          Log:
          JENKINS-32298 Update of testcase due to new parser regexp.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: src/test/java/hudson/plugins/warnings/parser/ParserRegistryTest.java http://jenkins-ci.org/commit/warnings-plugin/cadfb2a071bf1045b9c74af45b9ea1cf57958e74 Log: JENKINS-32298 Update of testcase due to new parser regexp.

          Bob Jacobsen added a comment -

          Thanks for looking at this!

          Warnings like this line do come through OK:

          [javadoc] javadoc: warning - Warning: node c7261778, port p unrecognized

          That's from a custom doclet that we use to create UML diagrams. That message (and similar ones) comes through fine.

          Bob Jacobsen added a comment - Thanks for looking at this! Warnings like this line do come through OK: [javadoc] javadoc: warning - Warning: node c7261778, port p unrecognized That's from a custom doclet that we use to create UML diagrams. That message (and similar ones) comes through fine.

          Code changed in jenkins
          User: Ulli Hafner
          Path:
          src/main/java/hudson/plugins/warnings/parser/JavaDocParser.java
          src/test/java/hudson/plugins/warnings/parser/JavaDocParserTest.java
          http://jenkins-ci.org/commit/warnings-plugin/81c697a5d0479843c75fed907f94c9bd9bb6c696
          Log:
          JENKINS-32298 Fixed false positives after upgrade to JavaDoc 8.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: src/main/java/hudson/plugins/warnings/parser/JavaDocParser.java src/test/java/hudson/plugins/warnings/parser/JavaDocParserTest.java http://jenkins-ci.org/commit/warnings-plugin/81c697a5d0479843c75fed907f94c9bd9bb6c696 Log: JENKINS-32298 Fixed false positives after upgrade to JavaDoc 8.

          Bob Jacobsen added a comment -

          Confirming that this is now fixed in plugin 4.54.

          Thank you!

          Bob Jacobsen added a comment - Confirming that this is now fixed in plugin 4.54. Thank you!

            drulli Ulli Hafner
            bennyprange Benny Prange
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: