Skip to content

ci: rework label-gated suites as advisory checks + fix label concurrency#379

Draft
nebasuke wants to merge 3 commits into
mainfrom
ci-label-gating-consistency
Draft

ci: rework label-gated suites as advisory checks + fix label concurrency#379
nebasuke wants to merge 3 commits into
mainfrom
ci-label-gating-consistency

Conversation

@nebasuke

@nebasuke nebasuke commented Apr 28, 2026

Copy link
Copy Markdown
Member

Summary

The four label-gated suites (coverage, integration-tests, sanitizer, slang-tests) are advisory opt-in checks, not merge gates: add the ci:* label to run a suite (e.g. the long integration tests) and read the result on the PR, but they don't block merging or run in the merge queue. This PR unifies them on one simple advisory shape and fixes a label-concurrency bug that could silently cancel an opted-in run.

Originally scoped as "unify so they can all be marked required"; we settled on advisory instead — required gating for long opt-in suites caused more flakiness than it prevented. The shared submodule-checkout composite action from the original plan landed separately in #383, so it is not part of this PR.

Changes

  • Unify + advisory (6a48dc45): drop the dummy label-check job (gate inlined onto cooldown-check); remove the pr-checks / re-actors/alls-green aggregators and their allowed-skips, the merge_group: triggers, and the now-unused checks: write on sanitizer/slang. Each suite posts its own status; absent label → clearly skipped rather than a misleading green-via-skip.
  • Per-label concurrency (8d50c89e): put the triggering label into the concurrency group, so a labeled event for an unrelated label lands in its own group and can't cancel the run started by the matching label. Fixes the "add two labels → one suite gets cancelled/skipped" flakiness. Other PR events (push/synchronize) share the main group and cancel-on-new as before.
  • release dedup (2f841114): release.yaml had no concurrency block and gates the dry-run on plain contains(labels, 'ci:release'), so every labeled event launched a fresh full multi-platform build. Add a per-PR concurrency group; cancel-in-progress is gated on pull_request so real releases (tag push / workflow_dispatch) get a per-ref group and are never cancelled.

⚠️ Branch protection — must land together with this PR

Remove PR Checks (Coverage), PR Checks (Integration), PR Checks (Sanitizer), PR Checks (Slang) from the required status checks list. sanitizer and slang previously reported in the merge queue via merge_group; if they stay required after that trigger is removed, the merge queue will block on checks that never report.

Test plan

  • Workflows parse (validated locally).
  • PR with no ci:* label: the four suites show as skipped; nothing blocks merge.
  • Add ci:integration, then ci:coverage: both real runs complete; neither cancels the other.
  • Add all ci:* labels at once: each suite's real run completes.
  • Remove a label: no re-trigger (unlabeled is not a trigger).
  • release.yaml: several ci:* labels at once → one dry-run pipeline, not several.

@nebasuke nebasuke added ci:coverage Trigger coverage workflow on PR ci:sanitizer Trigger sanitizer workflow on PR ci:integration Trigger integration tests workflow on PR and removed ci:coverage Trigger coverage workflow on PR ci:sanitizer Trigger sanitizer workflow on PR ci:integration Trigger integration tests workflow on PR labels Apr 28, 2026
nebasuke added 3 commits June 9, 2026 09:56
coverage, integration-tests, sanitizer and slang-tests are opt-in extra
coverage gated on `ci:*` labels — you add the label to run them and read
the result on the PR, but they should not block merging. Bring all four to
one simple, advisory shape:

- Drop the dummy `label-check` job; inline its label gate directly onto
  `cooldown-check` so the dependency graph has one less skipped node.
- Remove the `pr-checks` (re-actors/alls-green) aggregators and their
  `allowed-skips`. Those only existed to expose a stable *required* check
  that turned green-via-skip when the label was absent — actively
  misleading for an advisory suite (a green that means "didn't run"). The
  real job now posts its own status; absent label => clearly skipped.
- Drop the `merge_group:` triggers so these no longer run in / gate the
  merge queue.
- Drop `checks: write` on sanitizer/slang, added with the aggregator and
  now unused.
- Standardize the concurrency key across all four.

BRANCH PROTECTION: remove PR Checks (Coverage/Integration/Sanitizer/Slang)
from the required-status-checks list together with this change. sanitizer
and slang previously reported in the merge queue via merge_group; if they
stay required after the trigger is removed, the merge queue blocks on
checks that no longer report.
A `labeled` event fires once per label added, and GitHub can't filter
trigger events by label name, so each label-gated suite re-triggers on
labels it doesn't gate on. With a shared concurrency group those no-op runs
cancel the real run started by the matching label — so adding several
labels at once (or a second label while one is in flight) could kill an
opted-in run mid-test.

Put the triggering label into the concurrency group: a `labeled` event for
an unrelated label lands in its own group and can't touch the matching
label's run. Other PR events (push/synchronize) share the `main` group and
still cancel-on-new. The opted-in suite now reliably runs to completion.
release.yaml has no concurrency block and gates the PR dry-run on plain
`contains(labels, 'ci:release')`, so every `labeled` event while the label
is present launched a fresh full multi-platform build — adding several
labels at once could kick off multiple concurrent release pipelines.

Add a per-PR concurrency group that collapses the dry-runs into one run.
cancel-in-progress is gated on `pull_request` so real releases (tag push /
workflow_dispatch) get a per-ref group and are never cancelled.
@nebasuke nebasuke changed the title ci: unify label-gated workflow structure ci: rework label-gated suites as advisory checks + fix label concurrency Jun 9, 2026
@nebasuke nebasuke force-pushed the ci-label-gating-consistency branch from 260dd1c to 2f84111 Compare June 9, 2026 10:30
@nebasuke nebasuke added ci:slang Trigger slang unit tests on PR ci:release Trigger dry-run release workflow on PR labels Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:release Trigger dry-run release workflow on PR ci:slang Trigger slang unit tests on PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant