Skip to content

[PR] fix(ci): non-ci:full label events no longer cancel in-flight CI runs - #3828

Merged
ranxianglei merged 1 commit into
masterfrom
2026-10-19_label-skip-concurrency
Oct 19, 2026
Merged

ranxianglei merged 1 commit into
masterfrom
2026-10-19_label-skip-concurrency

Conversation

@ranxianglei

Copy link
Copy Markdown
Owner

Closes #3772

What & why

Any labeled event on a PR for a label other than ci:full (the label-sync pipeline mirrors issue labels bug/p2/scope/... onto PRs, so this fires routinely) starts a workflow run whose gate/plan job immediately decides skip — but that run shared the per-ref concurrency group of in-flight real runs, with cancel-in-progress: true (#3331). The vacuous skip-run therefore cancelled the real matrix mid-flight and then recorded success with an empty matrix: a false green plus 40+ cancelled runs per label burst (repro timeline in #3772, from the #3770 review).

Fix (option A from the issue)

Append a -skip suffix to the concurrency group for exactly the skip-scoped events, computed at trigger time from context:

group: <existing-group>${{ (github.event_name == 'pull_request' && github.event.action == 'labeled' && github.event.label.name != 'ci:full') && '-skip' || '' }}

The suffix predicate is the same one each gate/plan job already uses to decide skip, so the group name cannot drift from the gating logic. Effects:

  • non-ci:full label runs land in their own group → can no longer cancel in-flight real runs; they finish in ~20s as a harmless trace;
  • consecutive random labels only cancel each other's pending skip-runs (harmless no-ops);
  • ci:full labeled runs stay in the base group → still supersede in-flight core runs (feat!: remove image pre-compression and the image_full tool (#3266) #3295 widening semantics unchanged);
  • schedule/dispatch/push events: suffix evaluates to '', groups byte-identical to before.

Rejected alternative (keep the base group, conditionally disable cancel-in-progress): skip-runs would queue behind in-flight runs for up to ~30min instead of finishing immediately.

Files — all 13 workflows with a labeled trigger AND a cancel-in-progress group

ci.yml, ci-image.yml, ci-e2e.yml, ci-registry.yml, ci-zcode-real.yml, ci-e2e-dsh.yml, ci-e2e-dsh-native.yml, ci-e2e-codex-persona.yml, ci-e2e-native.yml, ci-e2e-native-opencode.yml, ci-e2e-pi-ws.yml, ci-windows-codex.yml, ci-e2e-fake.yml

ci-theorem.yml deliberately untouched: it triggers on labeled but has no concurrency block, so nothing there can be cancelled.

Behavior change (disclosed per policy)

Old: a non-ci:full label event on a PR cancelled that PR's in-flight CI runs (core matrix + every matching lane) and left a vacuous skip-green behind. New: such events leave in-flight runs alone; the resulting skip-run is isolated and completes immediately. No change to what runs when — opened/synchronize/reopened/ci:full/schedule/dispatch semantics are identical.

Verification

  • All 27 workflow files YAML-parse after the edit (python yaml.safe_load).
  • Same-repo PRs run the workflow files from the PR head, so this PR's own pull_request runs exercise the fixed ci.yml: labelling this PR with a random label mid-run will now NOT cancel its in-flight core matrix — a live self-test.
  • Full-suite verdict comes from remote CI on the pushed head.

@ranxianglei ranxianglei changed the title fix(ci): non-ci:full label events no longer cancel in-flight CI runs [PR] fix(ci): non-ci:full label events no longer cancel in-flight CI runs Oct 19, 2026
@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

📦 Built Package Artifact

Branch: 2026-10-19_label-skip-concurrency (6d76e56)

Option A — Install this exact build (recommended)

npm install -g billion-context@0.0.4530-pr.3828.a424191

This exact version is immutable and reproducible. The rolling pr tag tracks the newest test build across all PRs.

Option B — Download artifact

  1. Download the artifact from the Actions run
  2. Extract the tarball and install:
tar xzf billion-context-pr3828.tgz
npm install -g package

Install instructions are refreshed on each push.

#3772)

A `labeled` event for any non-ci:full label starts a run whose gate/plan
job immediately decides skip, but it shared the per-ref concurrency group
of in-flight real runs with cancel-in-progress=true — so the vacuous
skip-run cancelled the real matrix mid-flight and then recorded success
with an empty matrix (false green + 40+ cancelled runs per label burst;
#3770 repro).

Append a `-skip` suffix to the concurrency group for exactly those
trigger-time events (pull_request + labeled + label != ci:full — the same
predicate each gate/plan job already uses), so skip-runs can never cancel
in-flight runs; they finish in ~20s as a harmless trace. ci:full labeled
runs stay in the base group and still supersede in-flight core runs
(#3295); schedule/dispatch/push events are unaffected (suffix is '').

All 13 workflows with a labeled trigger AND a cancel-in-progress group:
ci.yml, ci-image.yml, ci-e2e.yml, ci-registry.yml, ci-zcode-real.yml,
ci-e2e-dsh.yml, ci-e2e-dsh-native.yml, ci-e2e-codex-persona.yml,
ci-e2e-native.yml, ci-e2e-native-opencode.yml, ci-e2e-pi-ws.yml,
ci-windows-codex.yml, ci-e2e-fake.yml. ci-theorem.yml excluded: no
concurrency block, nothing to cancel there.
@github-actions

Copy link
Copy Markdown
Contributor

📦 Merged Build Published

This merge to master was published as 0.0.606-master.85c27f0 (rolling master tag).

npm install -g billion-context@0.0.606-master.85c27f0  # this exact build
npm install -g billion-context@master  # always the newest merged build

npm view billion-context@master prints the current version at any time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ci: any non-ci:full label on a PR cancels its in-flight matrix run and records a vacuous skip-green

1 participant