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

Errors in agent instantiation and checkout not surfaced if post has node-requiring steps

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      If there's an error in the top-level agent instantiation (say, due to a checkout failing or non-existent Docker image, etc), and the post for the build includes steps that require running on a node (such as deleteDir() or emailext), those post steps will fail and end up being the only reported errors, preventing any visibility into what actually went wrong in the agent. We need to handle those error cases better.

        Attachments

          Issue Links

            Activity

            Show
            abayer Andrew Bayer added a comment - PR up at https://github.com/jenkinsci/pipeline-model-definition-plugin/pull/113
            Hide
            abayer Andrew Bayer added a comment -

            Merged. Will be in 1.0.2 release.

            Show
            abayer Andrew Bayer added a comment - Merged. Will be in 1.0.2 release.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Andrew Bayer
            Path:
            pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
            pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java
            pipeline-model-definition/src/test/resources/nonExistentDockerImage.groovy
            http://jenkins-ci.org/commit/pipeline-model-definition-plugin/de9286d6e917e156a6b629bfc595dba1dd3b444b
            Log:
            [FIXED JENKINS-41950] Properly report errors outside stages

            And treat errors in post-build the same whether we're running
            post-build within the agent block or not.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java pipeline-model-definition/src/test/resources/nonExistentDockerImage.groovy http://jenkins-ci.org/commit/pipeline-model-definition-plugin/de9286d6e917e156a6b629bfc595dba1dd3b444b Log: [FIXED JENKINS-41950] Properly report errors outside stages And treat errors in post-build the same whether we're running post-build within the agent block or not.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Andrew Bayer
            Path:
            pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
            pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java
            pipeline-model-definition/src/test/resources/nonExistentDockerImage.groovy
            http://jenkins-ci.org/commit/pipeline-model-definition-plugin/afaea38ea3a4c7ededb49a69c3104623372dde66
            Log:
            Merge pull request #113 from abayer/jenkins-41950

            [FIXED JENKINS-41950] Properly report errors outside stages

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java pipeline-model-definition/src/test/resources/nonExistentDockerImage.groovy http://jenkins-ci.org/commit/pipeline-model-definition-plugin/afaea38ea3a4c7ededb49a69c3104623372dde66 Log: Merge pull request #113 from abayer/jenkins-41950 [FIXED JENKINS-41950] Properly report errors outside stages

              People

              • Assignee:
                abayer Andrew Bayer
                Reporter:
                abayer Andrew Bayer
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: