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

MultiJob fails with NPE in MultiJobBuilder.getScmChange() evaluating 'lastBuild.getWorkspace().exists()'

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Postponed
    • Component/s: multijob-plugin
    • Labels:
      None
    • Environment:
      Jenkins 2.38
      MultiJob plugin 1.25
      Debian 8.6 Jessie, x86_64
      OpenJDK 64-bit 7u131-2.6.9-2~deb8u1
    • Similar Issues:

      Description

      Jenkins build fails with:

      ```
      >> Job status: [JOB_NAME] subjob last build result is worse than unstable.
      Triggering JOB_NAME. Condition was evaluated to true.
      Starting build job JOB_NAME.
      ERROR: Build step failed with exception
      java.lang.NullPointerException
      at com.tikal.jenkins.plugins.multijob.MultiJobBuilder.getScmChange(MultiJobBuilder.java:178)
      at com.tikal.jenkins.plugins.multijob.MultiJobBuilder.perform(MultiJobBuilder.java:269)
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
      at hudson.model.Build$BuildExecution.build(Build.java:205)
      at hudson.model.Build$BuildExecution.doRun(Build.java:162)
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
      at com.tikal.jenkins.plugins.multijob.MultiJobBuild$MultiJobRunnerImpl.run(MultiJobBuild.java:136)
      at hudson.model.Run.execute(Run.java:1729)
      at com.tikal.jenkins.plugins.multijob.MultiJobBuild.run(MultiJobBuild.java:73)
      at hudson.model.ResourceController.execute(ResourceController.java:98)
      at hudson.model.Executor.run(Executor.java:404)
      ```

      which seems to be this line:
      ```
      if ( !lastBuild.getWorkspace().exists() ) {
      ```

      Have no idea what's changed.. It used to work.
      Probably new nodes which lack workspaces for the JOB_NAME were added

        Attachments

          Activity

          Hide
          marcelskalicky Marcel Skalicky added a comment -

          Same happens for us. Probably it was caused by rename of node where lastBuild was run.

          Show
          marcelskalicky Marcel Skalicky added a comment - Same happens for us. Probably it was caused by rename of node where lastBuild was run.
          Hide
          yorammi Yoram Michaeli added a comment -

          Closing issue as part of tikal-multijob-plugin issues cleanup.
          If still relevant, please open a matching issue in https://github.com/jenkinsci/tikal-multijob-plugin/issues (you can refer to this issue in its description)

          Show
          yorammi Yoram Michaeli added a comment - Closing issue as part of tikal-multijob-plugin issues cleanup. If still relevant, please open a matching issue in https://github.com/jenkinsci/tikal-multijob-plugin/issues (you can refer to this issue in its description)

            People

            • Assignee:
              Unassigned
              Reporter:
              afunix Pavel Malyshev
            • Votes:
              2 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: