Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-12182

Publisher - Code Analysis - NullPointerException

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: analysis-core-plugin
    • Labels:
    • Environment:
      - Static Code Analysis Plug-ins (id: analysis-core, wersja: 1.36)
      - Static Analysis Collector Plug-in 1.19
      - Jenkins 1.444
    • Similar Issues:

      Description

      Again in latest version there is a bug during publishing with analysis-core plugin.

      Cause:
      In section "Post-build Actions" of job configuration (type: maven), when "Publish combined analysis results" checked, the value of "Health priorities" (e.g. All priorities) is not remembered after save action (probably only in a form, no in stored a job configuration - there is ok).

      To reproduce (changes in job configuration):

      • check "Post-build Actions" -> "Publish combined analysis results"
      • use advanced settings and select "Health priorities" -> "All priorities"
      • use save action
      • build (should be BUILD SUCCESSFUL, config_correct.xml)
      • edit configuration again, there should be any value selected in path: "Post-build Actions" -> "Publish combined analysis results" -> "Health priorities" (bug_analysis_core_nullpointerexception.jpg)
      • use save action
      • build (should be FAILURE, config_wrong.xml)

      ERROR: Publisher hudson.plugins.analysis.collector.AnalysisPublisher aborted due to exception
      java.lang.NullPointerException: Name is null
      at java.lang.Enum.valueOf(Enum.java:195)
      at hudson.plugins.analysis.util.model.Priority.valueOf(Priority.java:18)
      at hudson.plugins.analysis.core.HealthAwarePublisher.getMinimumPriority(HealthAwarePublisher.java:618)
      at hudson.plugins.analysis.core.AbstractHealthDescriptor.<init>(AbstractHealthDescriptor.java:36)
      at hudson.plugins.analysis.collector.AnalysisHealthDescriptor.<init>(AnalysisHealthDescriptor.java:25)
      at hudson.plugins.analysis.collector.AnalysisResultAction.<init>(AnalysisResultAction.java:31)
      at hudson.plugins.analysis.collector.AnalysisPublisher.perform(AnalysisPublisher.java:256)
      at hudson.plugins.analysis.core.HealthAwarePublisher.perform(HealthAwarePublisher.java:338)
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
      at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:692)
      at hudson.model.AbstractBuild$AbstractRunner.performAllBuildSteps(AbstractBuild.java:667)
      at hudson.maven.MavenModuleSetBuild$RunnerImpl.post2(MavenModuleSetBuild.java:1014)
      at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:614)
      at hudson.model.Run.run(Run.java:1429)
      at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481)
      at hudson.model.ResourceController.execute(ResourceController.java:88)
      at hudson.model.Executor.run(Executor.java:238)

        Attachments

        1. bug_analysis_core_nullpointerexception.jpg
          bug_analysis_core_nullpointerexception.jpg
          43 kB
        2. bug_analysis_core_nullpointerexception.jpg
          bug_analysis_core_nullpointerexception.jpg
          42 kB
        3. config_correct.xml
          11 kB
        4. config_wrong.xml
          11 kB
        5. installed.html
          29 kB
        6. installed2.html
          26 kB

          Issue Links

            Activity

            thinking Marcin Drozdowski created issue -
            thinking Marcin Drozdowski made changes -
            Field Original Value New Value
            Labels jenkins plugin
            Attachment bug_analysis_core_nullpointerexception.jpg [ 21343 ]
            Attachment config_correct.xml [ 21344 ]
            Attachment config_wrong.xml [ 21345 ]
            Affects Version/s current [ 10162 ]
            Environment - Static Code Analysis Plug-ins (id: analysis-core, wersja: 1.36)
            - Jenkins 1.444
            Description Again in latest version there is a bug during publishing with analysis-core plugin.

            Cause:
               In section "Post-build Actions" of job configuration (type: maven), when "Publish combined analysis results" checked, the value of "Health priorities" (e.g. All priorities) is not remembered after save action (probably only in a form, no in stored a job configuration - there is ok).

            To reproduce (changes in job configuration):
               - check "Post-build Actions" -> "Publish combined analysis results"
               - use advanced settings and select "Health priorities" -> "All priorities"
               - use save action
               - build (shoud be BUILD SUCCESSFUL, config_correct.xml)
               - edit configuration again, there shoud be any value selected in path: "Post-build Actions" -> "Publish combined analysis results" -> "Health priorities" (bug_analysis_core_nullpointerexception.jpg)
               - use save action
               - build (shoud be FAILURE, config_wrong.xml)

            ERROR: Publisher hudson.plugins.analysis.collector.AnalysisPublisher aborted due to exception
            java.lang.NullPointerException: Name is null
            at java.lang.Enum.valueOf(Enum.java:195)
            at hudson.plugins.analysis.util.model.Priority.valueOf(Priority.java:18)
            at hudson.plugins.analysis.core.HealthAwarePublisher.getMinimumPriority(HealthAwarePublisher.java:618)
            at hudson.plugins.analysis.core.AbstractHealthDescriptor.<init>(AbstractHealthDescriptor.java:36)
            at hudson.plugins.analysis.collector.AnalysisHealthDescriptor.<init>(AnalysisHealthDescriptor.java:25)
            at hudson.plugins.analysis.collector.AnalysisResultAction.<init>(AnalysisResultAction.java:31)
            at hudson.plugins.analysis.collector.AnalysisPublisher.perform(AnalysisPublisher.java:256)
            at hudson.plugins.analysis.core.HealthAwarePublisher.perform(HealthAwarePublisher.java:338)
            at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
            at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:692)
            at hudson.model.AbstractBuild$AbstractRunner.performAllBuildSteps(AbstractBuild.java:667)
            at hudson.maven.MavenModuleSetBuild$RunnerImpl.post2(MavenModuleSetBuild.java:1014)
            at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:614)
            at hudson.model.Run.run(Run.java:1429)
            at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481)
            at hudson.model.ResourceController.execute(ResourceController.java:88)
            at hudson.model.Executor.run(Executor.java:238)
            thinking Marcin Drozdowski made changes -
            thinking Marcin Drozdowski made changes -
            Description Again in latest version there is a bug during publishing with analysis-core plugin.

            Cause:
               In section "Post-build Actions" of job configuration (type: maven), when "Publish combined analysis results" checked, the value of "Health priorities" (e.g. All priorities) is not remembered after save action (probably only in a form, no in stored a job configuration - there is ok).

            To reproduce (changes in job configuration):
               - check "Post-build Actions" -> "Publish combined analysis results"
               - use advanced settings and select "Health priorities" -> "All priorities"
               - use save action
               - build (shoud be BUILD SUCCESSFUL, config_correct.xml)
               - edit configuration again, there shoud be any value selected in path: "Post-build Actions" -> "Publish combined analysis results" -> "Health priorities" (bug_analysis_core_nullpointerexception.jpg)
               - use save action
               - build (shoud be FAILURE, config_wrong.xml)

            ERROR: Publisher hudson.plugins.analysis.collector.AnalysisPublisher aborted due to exception
            java.lang.NullPointerException: Name is null
            at java.lang.Enum.valueOf(Enum.java:195)
            at hudson.plugins.analysis.util.model.Priority.valueOf(Priority.java:18)
            at hudson.plugins.analysis.core.HealthAwarePublisher.getMinimumPriority(HealthAwarePublisher.java:618)
            at hudson.plugins.analysis.core.AbstractHealthDescriptor.<init>(AbstractHealthDescriptor.java:36)
            at hudson.plugins.analysis.collector.AnalysisHealthDescriptor.<init>(AnalysisHealthDescriptor.java:25)
            at hudson.plugins.analysis.collector.AnalysisResultAction.<init>(AnalysisResultAction.java:31)
            at hudson.plugins.analysis.collector.AnalysisPublisher.perform(AnalysisPublisher.java:256)
            at hudson.plugins.analysis.core.HealthAwarePublisher.perform(HealthAwarePublisher.java:338)
            at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
            at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:692)
            at hudson.model.AbstractBuild$AbstractRunner.performAllBuildSteps(AbstractBuild.java:667)
            at hudson.maven.MavenModuleSetBuild$RunnerImpl.post2(MavenModuleSetBuild.java:1014)
            at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:614)
            at hudson.model.Run.run(Run.java:1429)
            at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481)
            at hudson.model.ResourceController.execute(ResourceController.java:88)
            at hudson.model.Executor.run(Executor.java:238)
            Again in latest version there is a bug during publishing with analysis-core plugin.

            Cause:
               In section "Post-build Actions" of job configuration (type: maven), when "Publish combined analysis results" checked, the value of "Health priorities" (e.g. All priorities) is not remembered after save action (probably only in a form, no in stored a job configuration - there is ok).

            To reproduce (changes in job configuration):
               - check "Post-build Actions" -> "Publish combined analysis results"
               - use advanced settings and select "Health priorities" -> "All priorities"
               - use save action
               - build (should be BUILD SUCCESSFUL, config_correct.xml)
               - edit configuration again, there should be any value selected in path: "Post-build Actions" -> "Publish combined analysis results" -> "Health priorities" (bug_analysis_core_nullpointerexception.jpg)
               - use save action
               - build (should be FAILURE, config_wrong.xml)

            ERROR: Publisher hudson.plugins.analysis.collector.AnalysisPublisher aborted due to exception
            java.lang.NullPointerException: Name is null
            at java.lang.Enum.valueOf(Enum.java:195)
            at hudson.plugins.analysis.util.model.Priority.valueOf(Priority.java:18)
            at hudson.plugins.analysis.core.HealthAwarePublisher.getMinimumPriority(HealthAwarePublisher.java:618)
            at hudson.plugins.analysis.core.AbstractHealthDescriptor.<init>(AbstractHealthDescriptor.java:36)
            at hudson.plugins.analysis.collector.AnalysisHealthDescriptor.<init>(AnalysisHealthDescriptor.java:25)
            at hudson.plugins.analysis.collector.AnalysisResultAction.<init>(AnalysisResultAction.java:31)
            at hudson.plugins.analysis.collector.AnalysisPublisher.perform(AnalysisPublisher.java:256)
            at hudson.plugins.analysis.core.HealthAwarePublisher.perform(HealthAwarePublisher.java:338)
            at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
            at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:692)
            at hudson.model.AbstractBuild$AbstractRunner.performAllBuildSteps(AbstractBuild.java:667)
            at hudson.maven.MavenModuleSetBuild$RunnerImpl.post2(MavenModuleSetBuild.java:1014)
            at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:614)
            at hudson.model.Run.run(Run.java:1429)
            at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481)
            at hudson.model.ResourceController.execute(ResourceController.java:88)
            at hudson.model.Executor.run(Executor.java:238)
            thinking Marcin Drozdowski made changes -
            Environment - Static Code Analysis Plug-ins (id: analysis-core, wersja: 1.36)
            - Jenkins 1.444
            - Static Code Analysis Plug-ins (id: analysis-core, wersja: 1.36)
            - Static Analysis Collector Plug-in 1.19
            - Jenkins 1.444
            drulli Ulli Hafner made changes -
            Link This issue is related to JENKINS-8185 [ JENKINS-8185 ]
            thinking Marcin Drozdowski made changes -
            Attachment installed.html [ 21347 ]
            thinking Marcin Drozdowski made changes -
            Attachment installed2.html [ 21357 ]
            drulli Ulli Hafner made changes -
            Link This issue is related to JENKINS-12692 [ JENKINS-12692 ]
            drulli Ulli Hafner made changes -
            Status Open [ 1 ] Resolved [ 5 ]
            Resolution Fixed [ 1 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 142504 ] JNJira + In-Review [ 190137 ]

              People

              • Assignee:
                drulli Ulli Hafner
                Reporter:
                thinking Marcin Drozdowski
              • Votes:
                1 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: