Skip to content

Commit 2ccc38e

Browse files
committed
ci(codeql): don't cancel superseded runs of a required scan
CodeQL is a REQUIRED code-scanning tool in the estate branch rulesets — a result must upload for the head commit before merge. With cancel-in-progress: true a re-push cancels the in-flight scan, which uploads nothing, leaving branch protection stuck "expecting 1 result from CodeQL for <sha>" forever (the ghost check that blocks estate PRs for hours/days). Queue instead of cancel so the latest commit always completes + uploads. This is the canonical template; consumer repos inherit it on next sync.
1 parent f4a1e56 commit 2ccc38e

1 file changed

Lines changed: 11 additions & 5 deletions

File tree

.github/workflows/codeql.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,19 @@ on:
1414
# cut only changes the scheduled-baseline cadence.
1515
- cron: '0 6 1 * *'
1616

17-
# Estate guardrail: cancel superseded runs so re-pushes / rebased PR
18-
# updates do not pile up queued runs against the shared account-wide
19-
# Actions concurrency pool. Applied only to read-only check workflows
20-
# (no publish/mutation), so cancelling a superseded run is always safe.
17+
# Estate guardrail: serialise superseded runs so re-pushes / rebased PR
18+
# updates do not pile up against the shared account-wide Actions pool.
19+
#
20+
# cancel-in-progress is DELIBERATELY false: CodeQL is a REQUIRED
21+
# code-scanning tool in the estate branch rulesets (a result must upload
22+
# for the head commit before a PR can merge). A cancelled run uploads
23+
# nothing, leaving branch protection stuck "expecting 1 result from CodeQL
24+
# for <sha>" indefinitely — the ghost check that blocks PRs for hours/days.
25+
# Queue rather than cancel so the latest commit's scan always completes and
26+
# uploads. (Non-required read-only workflows may still cancel-in-progress.)
2127
concurrency:
2228
group: ${{ github.workflow }}-${{ github.ref }}
23-
cancel-in-progress: true
29+
cancel-in-progress: false
2430

2531
permissions:
2632
contents: read

0 commit comments

Comments
 (0)