Trunk build of Jenkins, latest plugins:

      java.lang.NullPointerException
      	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.saveOwner(CpsFlowExecution.java:1754)
      	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.setResumeBlocked(CpsFlowExecution.java:348)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.onLoad(WorkflowRun.java:633)
      	at ...
      

      after restarting when there was a build of a project which I marked not for resumption.

          [JENKINS-49961] NPE from CpsFlowExecution.saveOwner

          Jesse Glick created issue -

          Jesse Glick added a comment -

          The code seems wrong. WorkflowRun.onLoad sets the owner after calling setResumeBlocked. So of course it will throw an exception.

          Jesse Glick added a comment - The code seems wrong. WorkflowRun.onLoad sets the owner   after calling setResumeBlocked . So of course it will throw an exception.
          Jesse Glick made changes -
          Link New: This issue blocks JENKINS-33761 [ JENKINS-33761 ]
          Jesse Glick made changes -
          Labels New: regression
          Sam Van Oort made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Sam Van Oort made changes -
          Remote Link New: This issue links to "PR 210 (Web Link)" [ 20231 ]
          Andrew Bayer made changes -
          Link New: This issue is duplicated by JENKINS-49751 [ JENKINS-49751 ]

          Code changed in jenkins
          User: Sam Van Oort
          Path:
          pom.xml
          src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java
          src/test/java/org/jenkinsci/plugins/workflow/cps/FlowDurabilityTest.java
          http://jenkins-ci.org/commit/workflow-cps-plugin/0ebe94916353f873715c06b642fb744969f1db0c
          Log:
          Fix JENKINS-49961 by avoiding an unsafe save operation when toggling ResumeEnabled if the FlowExecutionOwner is not yet set

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Sam Van Oort Path: pom.xml src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java src/test/java/org/jenkinsci/plugins/workflow/cps/FlowDurabilityTest.java http://jenkins-ci.org/commit/workflow-cps-plugin/0ebe94916353f873715c06b642fb744969f1db0c Log: Fix JENKINS-49961 by avoiding an unsafe save operation when toggling ResumeEnabled if the FlowExecutionOwner is not yet set

          Code changed in jenkins
          User: Andrew Bayer
          Path:
          pom.xml
          src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java
          src/test/java/org/jenkinsci/plugins/workflow/cps/FlowDurabilityTest.java
          http://jenkins-ci.org/commit/workflow-cps-plugin/a63e6848d642b65f21e32ea7d15a8a853de8761a
          Log:
          Merge pull request #210 from svanoort/fix-JENKINS-49961

          Fix JENKINS-49961 by avoiding an unsafe save operation when toggling ResumeEnabled if the FlowExecutionOwner is not yet set

          Compare: https://github.com/jenkinsci/workflow-cps-plugin/compare/78b137d8743e...a63e6848d642

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: pom.xml src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java src/test/java/org/jenkinsci/plugins/workflow/cps/FlowDurabilityTest.java http://jenkins-ci.org/commit/workflow-cps-plugin/a63e6848d642b65f21e32ea7d15a8a853de8761a Log: Merge pull request #210 from svanoort/fix- JENKINS-49961 Fix JENKINS-49961 by avoiding an unsafe save operation when toggling ResumeEnabled if the FlowExecutionOwner is not yet set Compare: https://github.com/jenkinsci/workflow-cps-plugin/compare/78b137d8743e...a63e6848d642
          Andrew Bayer made changes -
          Status Original: In Progress [ 3 ] New: In Review [ 10005 ]

            svanoort Sam Van Oort
            jglick Jesse Glick
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: