1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-27 11:07:44 +00:00

fix ruff warnings

This commit is contained in:
Sylvestre Ledru 2025-03-18 20:36:38 +01:00
parent 663a9202e5
commit b1c3175387
5 changed files with 12 additions and 9 deletions

View file

@ -1,8 +1,8 @@
#!/usr/bin/env python3
"""
Compare the current results to the last results gathered from the main branch to highlight
if a PR is making the results better/worse.
Compare the current results to the last results gathered from the main branch to
highlight if a PR is making the results better/worse.
Don't exit with error code if all failing tests are in the ignore-intermittent.txt list.
"""
@ -28,13 +28,15 @@ skip_d = int(current["skip"]) - int(last["skip"])
# Get an annotation to highlight changes
print(
f"::warning ::Changes from '{REPO_DEFAULT_BRANCH}': PASS {pass_d:+d} / FAIL {fail_d:+d} / ERROR {error_d:+d} / SKIP {skip_d:+d} "
f"""::warning ::Changes from '{REPO_DEFAULT_BRANCH}': PASS {pass_d:+d} /
FAIL {fail_d:+d} / ERROR {error_d:+d} / SKIP {skip_d:+d}"""
)
# If results are worse, check if we should fail the job
if pass_d < 0:
print(
f"::error ::PASS count is reduced from '{REPO_DEFAULT_BRANCH}': PASS {pass_d:+d} "
f"""::error ::PASS count is reduced from
'{REPO_DEFAULT_BRANCH}': PASS {pass_d:+d}"""
)
# Check if all failing tests are intermittent based on the environment variable