[llvm] [CI] Detect step failures in metrics job (PR #122564)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 10 18:25:01 PST 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {darker}-->
:warning: Python code formatter, darker found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
darker --check --diff -r 99d0780f050c830c046c6f8790821880ab7c71f5...8a9c3eb9edcd803d354774e451a092c45c906439 .ci/metrics/metrics.py
``````````
</details>
<details>
<summary>
View the diff from darker here.
</summary>
``````````diff
--- metrics.py 2025-01-11 02:19:02.000000 +0000
+++ metrics.py 2025-01-11 02:24:29.015505 +0000
@@ -79,21 +79,21 @@
started_at = workflow_jobs[0].started_at
completed_at = workflow_jobs[0].completed_at
job_result = int(workflow_jobs[0].conclusion == "success")
if job_result:
- # We still might want to mark the job as a failure if one of the steps
- # failed. This is required due to use setting continue-on-error in
- # the premerge pipeline to prevent sending emails while we are
- # testing the infrastructure.
- # TODO(boomanaiden154): Remove this once the premerge pipeline is no
- # longer in a testing state and we can directly assert the workflow
- # result.
- for step in workflow_jobs[0].steps:
- if step.conclusion != "success":
- job_result = 0
- break
+ # We still might want to mark the job as a failure if one of the steps
+ # failed. This is required due to use setting continue-on-error in
+ # the premerge pipeline to prevent sending emails while we are
+ # testing the infrastructure.
+ # TODO(boomanaiden154): Remove this once the premerge pipeline is no
+ # longer in a testing state and we can directly assert the workflow
+ # result.
+ for step in workflow_jobs[0].steps:
+ if step.conclusion != "success":
+ job_result = 0
+ break
queue_time = started_at - created_at
run_time = completed_at - started_at
if run_time.seconds == 0:
``````````
</details>
https://github.com/llvm/llvm-project/pull/122564
More information about the llvm-commits
mailing list