Unverified Commit 56614f32 authored by Rhett Ying's avatar Rhett Ying Committed by GitHub
Browse files

[BugFix] fix job status in master CI (#3962)

* [BugFix] fix job status in master CI

* finalize
parent 529fd107
...@@ -490,10 +490,12 @@ pipeline { ...@@ -490,10 +490,12 @@ pipeline {
def comment = sh(returnStdout: true, script: "python3 status.py").trim() def comment = sh(returnStdout: true, script: "python3 status.py").trim()
echo(comment) echo(comment)
if ((env.BRANCH_NAME).startsWith('PR-')) {
pullRequest.comment(comment) pullRequest.comment(comment)
} }
} }
} }
}
node('windows') { node('windows') {
bat(script: "rmvirtualenv ${BUILD_TAG}", returnStatus: true) bat(script: "rmvirtualenv ${BUILD_TAG}", returnStatus: true)
} }
......
...@@ -8,7 +8,7 @@ job_link = os.environ["BUILD_URL"] ...@@ -8,7 +8,7 @@ job_link = os.environ["BUILD_URL"]
response = requests.get('{}wfapi'.format(job_link)).json() response = requests.get('{}wfapi'.format(job_link)).json()
status = "✅ CI test succeeded" status = "✅ CI test succeeded"
for v in response['stages']: for v in response['stages']:
if 'FAILED' in v['status']: if v['status'] not in ['SUCCESS', 'IN_PROGRESS']:
status = "❌ CI test failed in Stage [{}].".format(v['name']) status = "❌ CI test failed in Stage [{}].".format(v['name'])
break break
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment