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

Stage input runs before when conditional

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      The input step in below example will run even if the pipeline isn't building a matching tag

      But the steps won't execute, so the input is kinda void anyway.

      pipeline {
          agent any
          stages {
              stage ("First") {
                  steps {
                      echo "Hello"
                  }
              }
              stage ("Second") {
                  options {
                      timeout 15
                  }
                  when {
                      tag "release-*"
                  }
                  input {
                      message 'Deploy to production?'
                      ok 'Fire zee missiles!'
                  }
                  steps {
                      echo "World"
                  }
              }
          }
      }
      

        Attachments

          Issue Links

            Activity

            Hide
            msneller Matt Sneller added a comment -

            When will this fix be released?

            Show
            msneller Matt Sneller added a comment - When will this fix be released?

              People

              Assignee:
              abayer Andrew Bayer
              Reporter:
              rsandell rsandell
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: