Jenkinsfile - Pipeline - npm run hangs

22 views
Skip to first unread message

Shaun Thompson

unread,
Feb 2, 2018, 4:50:57 PM2/2/18
to Jenkins Users
I have the following Jenkinsfile

pipeline {
   agent any
   stages {
       stage('Checkout') {
           steps {
               git 'project'
           }
       }
       
       stage('Install') {
           steps {
               sh 'npm install'
           }
       }

        stage('Test') {
           steps {
               sh "npm run cucumber"
               step([$class: 'CucumberReportPublisher', jsonReportDirectory: '/target', fileIncludePattern: '*.json'])
           }
       }
   }
   post {
       always {
           step([$class: 'Mailer', notifyEveryUnstableBuild: true, recipients: emailextrecipients([[$class: 'CulpritsRecipientProvider'], [$class: 'RequesterRecipientProvider']])])
       }
   }
}

The cucumber tests complete but then hangs.

3 steps ( [31m1 failed [39m, [36m1 skipped [39m, [32m1 passed [39m
0m05.023s

Creating a thread dump shows the following

Thread #8
        at DSL
.sh(awaiting process completion in project@tmp/durable-42df74ba; recurrence period: 15000ms; check task scheduled; cancelled? false done? false)
        at
WorkflowScript.run(WorkflowScript:18)
        at org
.jenkinsci.plugins.pipeline.modeldefinition.ModelInterpreter.delegateAndExecute(jar:file:/plugins/pipeline-model-

Reply all
Reply to author
Forward
0 new messages