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

workflow-plugin: 'env' before 'sh' will hang 'sh'

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Critical Critical
    • pipeline
    • None
    • Jenkins LTS 1.580.3
      (master) Ubuntu Trusty 14.04, all updates
      (slave) Windows Server 2012 x64
      Oracle JDK 1.7.1_71

      Using the workflow-plugin the 'sh' task hangs after an 'env' task call, even when the 'env' is on a different node. Here's a real example that hangs on the 'sh' call:

      node('windows-doc') {
          echo "On my Windows slave"
          env.PATH = "C:\\Program Files (x86)\\MadCap Software\\MadCap Flare V10\\Flare.app;%PATH%"
      }
      
      node('master') {
          echo "On master"
          sh "ls -l"
      }
      

      Remove the 'env.PATH' from that, and it will not hang.

          [JENKINS-27105] workflow-plugin: 'env' before 'sh' will hang 'sh'

          smarmit created issue -
          smarmit made changes -
          Description Original: Using the workflow-plugin the 'sh' task hangs after an 'env' task call, even when the 'env' is on a different node. Here's a real example that hangs on the 'sh' call:

          ---
          node('windows-doc') {
              echo "On my Windows slave"
              env.PATH = "C:\\Program Files (x86)\\MadCap Software\\MadCap Flare V10\\Flare.app;%PATH%"
          }

          node('master') {
              echo "On master"
              sh "ls -l"
          }
          ---

          Remove the 'env.PATH' from that, and it will not hang.
          New: Using the workflow-plugin the 'sh' task hangs after an 'env' task call, even when the 'env' is on a different node. Here's a real example that hangs on the 'sh' call:

          {code}
          node('windows-doc') {
              echo "On my Windows slave"
              env.PATH = "C:\\Program Files (x86)\\MadCap Software\\MadCap Flare V10\\Flare.app;%PATH%"
          }

          node('master') {
              echo "On master"
              sh "ls -l"
          }
          {code}

          Remove the 'env.PATH' from that, and it will not hang.
          Jesse Glick made changes -
          Link New: This issue duplicates JENKINS-26105 [ JENKINS-26105 ]
          Jesse Glick made changes -
          Link New: This issue duplicates JENKINS-26128 [ JENKINS-26128 ]
          Jesse Glick made changes -
          Resolution New: Duplicate [ 3 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 161298 ] New: JNJira + In-Review [ 196707 ]
          Andrew Bayer made changes -
          Component/s New: pipeline-general [ 21692 ]
          Andrew Bayer made changes -
          Component/s Original: workflow-plugin [ 18820 ]

            jglick Jesse Glick
            smarmit smarmit
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: