Skip to content

Commit 3be1860

Browse files
committed
fix(ci): remove !cancelled() from required-check gates to prevent cancel bypass
The lint, typecheck, and examples aggregate jobs used `always() && !cancelled() && ...` which causes a cancelled workflow to produce a 'skipped' conclusion instead of 'cancelled'. Since GitHub treats skipped required checks as successful, cancelling CI could satisfy branch protection without lint or typecheck ever running. Remove !cancelled() from these three required-check aggregate jobs, matching the pattern already used by the test aggregate. Leaf shard jobs retain !cancelled() because they do actual work and are not required-check gates.
1 parent 5a4af66 commit 3be1860

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -499,7 +499,7 @@ jobs:
499499
needs: release_change
500500
# A skipped job reports success, including when it is a required check. The
501501
# classifier only takes this path for the exact bot-owned metadata commit.
502-
if: ${{ always() && !cancelled() && needs.release_change.outputs.is_release_pr != 'true' }}
502+
if: ${{ always() && needs.release_change.outputs.is_release_pr != 'true' }}
503503
runs-on: ubuntu-latest
504504

505505
steps:
@@ -639,7 +639,7 @@ jobs:
639639
typecheck:
640640
name: typecheck
641641
needs: release_change
642-
if: ${{ always() && !cancelled() && needs.release_change.outputs.is_release_pr != 'true' }}
642+
if: ${{ always() && needs.release_change.outputs.is_release_pr != 'true' }}
643643
runs-on: ubuntu-latest
644644

645645
steps:
@@ -706,7 +706,7 @@ jobs:
706706
examples:
707707
name: examples
708708
needs: [release_change, example_shard]
709-
if: ${{ always() && !cancelled() && needs.release_change.outputs.is_release_pr != 'true' }}
709+
if: ${{ always() && needs.release_change.outputs.is_release_pr != 'true' }}
710710
runs-on: ubuntu-latest
711711

712712
steps:

0 commit comments

Comments
 (0)