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

Unable to understand when AbortError is created by user`s action like pressing button Stop

XMLWordPrintable

      This doesn't help and actually looks like a veeery huge hack:

      try {
              sh "bash do_magic.sh"
              do_another_magic()
      } catch (hudson.AbortException e) {
              if (e.getMessage().contains('script returned exit code 143')) {
                       echo "aborted by user"
                       throw e
              } else {
                       echo "aborted by error, continuing next stage"
              }
      }
      

            Unassigned Unassigned
            kamikaze Oleg Korsak
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: