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

Stage still shown with NaNy NaNd when condition returns false

    Details

    • Similar Issues:

      Description

      Conditional stages when false are not hidden anymore. It worked before so the problem was introduce with latest updates.

      This is the Jenkinsfile code we use, which worked for previous versions and is ok according to the when pipeline syntax.

      pipeline {
          agent any
      
          stages {
              stage('Checkout dev') {
                  when {
                      expression { env.GIT_BRANCH == 'origin/dev' }
                  }
                  steps {
                      echo "\u001B[32mCheckout dev OK\u001B[m"
                  }
              }
              stage('Checkout master') {
                  when {
                      expression { env.GIT_BRANCH == 'origin/master' }
                  }
                  steps {
                      echo "\u001B[32mCheckout master OK\u001B[m"
                  }
              }
      ...
      

       

        Attachments

          Activity

          Hide
          thinkingmonster Akashdeep Thakur added a comment -

          This issue needs to be fixed. NaNy NaNd does not look good on build dashboard

          Show
          thinkingmonster Akashdeep Thakur added a comment - This issue needs to be fixed. NaNy NaNd does not look good on build dashboard
          Hide
          kvanhoorn Kevin van Hoorn added a comment -

          This is also happening when you have jobs in parallel:

           

          pipeline { 
            agent any 
            stages { 
              stage('Prepare ur angus') { 
                parallel { 
                  stage('Prepare ur angus') { 
                    steps { 
                      echo 'Quite simple' 
                    } 
                  } 
                  stage('Bake the angus') { 
                    steps { 
                      sleep 12 
                    } 
                  } 
                } 
              }
            }
          }
          

          Show
          kvanhoorn Kevin van Hoorn added a comment - This is also happening when you have jobs in parallel:   pipeline { agent any stages { stage( 'Prepare ur angus' ) { parallel { stage( 'Prepare ur angus' ) { steps { echo 'Quite simple' } } stage( 'Bake the angus' ) { steps { sleep 12 } } } } } }
          Hide
          jansohn Robin Jansohn added a comment -

          Sam Van Oort are there any plans to get this fixed?

          Show
          jansohn Robin Jansohn added a comment - Sam Van Oort are there any plans to get this fixed?
          Hide
          basil Basil Crow added a comment -
          Show
          basil Basil Crow added a comment - Likely fixed by jenkinsci/pipeline-stage-view-plugin#68 .

            People

            • Assignee:
              svanoort Sam Van Oort
              Reporter:
              philip_sultanescu Philip Sultanescu
            • Votes:
              20 Vote for this issue
              Watchers:
              17 Start watching this issue

              Dates

              • Created:
                Updated: