• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • warnings-plugin
    • None
    • Jenkins 1.505
      Warnings-Plugin 4.32

      It seems if there is no reference build the result of build is not set according specified status thresholds.
      In configuration of job I have set

      Status thresholds (Totals) All priorities Priority high Priority normal Priority low
      yellow 0      
      red        

      and
      Compute new warnings (based on reference build)

      Status thresholds (New warnings) All priorities Priority high Priority normal Priority low
      yellow        
      red 0      

      Use delta for new warnings

      Currently 782 warnings are found but build result is stable, expected unstable.

      Excerpt from console:
      [WARNINGS] Parsing warnings in files 'ccg.txt' with parser TTCN3_SCT_VALIDATOR
      [WARNINGS] Finding all files that match the pattern ccg.txt
      [WARNINGS] Parsing 1 files in /var/fpwork/xxx/jenkins/workspace/job_ccg
      [WARNINGS] Successfully parsed file /var/fpwork/xxx/jenkins/workspace/job_ccg/ccg.txt of module with 782 warnings.
      [WARNINGS] Skipping warning delta computation since no reference build is found

      Please find configuration in attachment (warnings_config.jpg and warnings_config.xml ).

          [JENKINS-19614] Result of build not always set correct

          Code changed in jenkins
          User: Ulli Hafner
          Path:
          src/main/java/org/jenkinsci/test/acceptance/plugins/AbstractCodeStylePluginPostBuildStep.java
          src/main/java/org/jenkinsci/test/acceptance/po/Build.java
          src/test/java/plugins/AbstractCodeStylePluginHelper.java
          src/test/java/plugins/PmdPluginTest.java
          http://jenkins-ci.org/commit/acceptance-test-harness/6307047ce0b5653ae64277c35d6d85c110eb1672
          Log:
          JENKINS-19614 Added a test case that tries to expose the bug.

          Compare: https://github.com/jenkinsci/acceptance-test-harness/compare/0f30abdaa894...6307047ce0b5

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: src/main/java/org/jenkinsci/test/acceptance/plugins/AbstractCodeStylePluginPostBuildStep.java src/main/java/org/jenkinsci/test/acceptance/po/Build.java src/test/java/plugins/AbstractCodeStylePluginHelper.java src/test/java/plugins/PmdPluginTest.java http://jenkins-ci.org/commit/acceptance-test-harness/6307047ce0b5653ae64277c35d6d85c110eb1672 Log: JENKINS-19614 Added a test case that tries to expose the bug. Compare: https://github.com/jenkinsci/acceptance-test-harness/compare/0f30abdaa894...6307047ce0b5

          Ulli Hafner added a comment -

          The test case for the PMD plugin basically does the same thing. However, the test does not fail. Seems that either the warnings plugin works differently or the bug already is fixed.

          Can you please check if the problem still occurs in the latest version of the warnings plug-in?

          Ulli Hafner added a comment - The test case for the PMD plugin basically does the same thing. However, the test does not fail. Seems that either the warnings plugin works differently or the bug already is fixed. Can you please check if the problem still occurs in the latest version of the warnings plug-in?

          Hello Ulli,

          I have installed version 4.40 of warnings plugin. Jenins version is 1.544.
          Problem still occuring:

          [WARNINGS] Parsing warnings in files 'xxx.warn' with parser SCT_VALIDATOR
          [WARNINGS] Finding all files that match the pattern xxx.warn
          [WARNINGS] Parsing 1 files in ..../workspace
          [WARNINGS] Successfully parsed file .../workspace/xxx.warn of module with 865 warnings.
          [WARNINGS] Skipping warning delta computation since no reference build is found
          Finished: SUCCESS

          Hans-Juergen Hafner added a comment - Hello Ulli, I have installed version 4.40 of warnings plugin. Jenins version is 1.544. Problem still occuring: [WARNINGS] Parsing warnings in files 'xxx.warn' with parser SCT_VALIDATOR [WARNINGS] Finding all files that match the pattern xxx.warn [WARNINGS] Parsing 1 files in ..../workspace [WARNINGS] Successfully parsed file .../workspace/xxx.warn of module with 865 warnings. [WARNINGS] Skipping warning delta computation since no reference build is found Finished: SUCCESS

          Ulli Hafner added a comment -

          Thanks for checking. Then this bug seems to be only in the warnings plug-in but not in the base library.

          Ulli Hafner added a comment - Thanks for checking. Then this bug seems to be only in the warnings plug-in but not in the base library.

          Code changed in jenkins
          User: Ulli Hafner
          Path:
          src/test/java/plugins/WarningsPluginTest.java
          http://jenkins-ci.org/commit/acceptance-test-harness/533383e1c0b1fd79dcfc4161cf065e381e35a25b
          Log:
          [FIXED JENKINS-19614] Added test that verifies that wrong build status is already fixed in latest plugin release.

          Compare: https://github.com/jenkinsci/acceptance-test-harness/compare/6897db158591...533383e1c0b1

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: src/test/java/plugins/WarningsPluginTest.java http://jenkins-ci.org/commit/acceptance-test-harness/533383e1c0b1fd79dcfc4161cf065e381e35a25b Log: [FIXED JENKINS-19614] Added test that verifies that wrong build status is already fixed in latest plugin release. Compare: https://github.com/jenkinsci/acceptance-test-harness/compare/6897db158591...533383e1c0b1

          Ulli Hafner added a comment -

          Seems that I fixed that bug in the latest release. Can you please verify?

          Ulli Hafner added a comment - Seems that I fixed that bug in the latest release. Can you please verify?

          For me it works with Jenkins 1.583 and Warnings Plugin 4.45:

          [WARNINGS] Parsing warnings in files 'xxx.warn' with parser SCT_VALIDATOR
          [WARNINGS] Finding all files that match the pattern xxx.warn
          [WARNINGS] Parsing 1 file in .../workspace
          [WARNINGS] Successfully parsed file .../workspace/xxx.warn with 865 unique warnings and 0 duplicates.
          [WARNINGS] Ignore new warnings since this is the first valid build
          [WARNINGS] Plug-in Result: Unstable - <a href="warningsResult">865 warnings</a> exceed the threshold of 0 by 865
          Build step 'Scan for compiler warnings' changed build result to UNSTABLE

          Hans-Juergen Hafner added a comment - For me it works with Jenkins 1.583 and Warnings Plugin 4.45: [WARNINGS] Parsing warnings in files 'xxx.warn' with parser SCT_VALIDATOR [WARNINGS] Finding all files that match the pattern xxx.warn [WARNINGS] Parsing 1 file in .../workspace [WARNINGS] Successfully parsed file .../workspace/xxx.warn with 865 unique warnings and 0 duplicates. [WARNINGS] Ignore new warnings since this is the first valid build [WARNINGS] Plug-in Result: Unstable - <a href="warningsResult">865 warnings</a> exceed the threshold of 0 by 865 Build step 'Scan for compiler warnings' changed build result to UNSTABLE

            drulli Ulli Hafner
            hjhafner Hans-Juergen Hafner
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: