Skip to content

feat(pr-pipeline): pause admissions at 10 held lane PRs and floor docs/adr/** - #8803

Merged
kyle-sexton merged 5 commits into
mainfrom
feat/held-cap-pause
Oct 21, 2026
Merged

kyle-sexton merged 5 commits into
mainfrom
feat/held-cap-pause

Conversation

@kyle-sexton

Copy link
Copy Markdown
Member

Closes #8795

Hold: a human merges this. It touches .github/** and docs/conventions/** (HIGH floor) and changes when the issue lane pauses.

Summary

wip.held-cap was 60 and only alerted (check-wip-cap.mjs paused on wipOver alone), so held lane PRs (needs-human, do-not-merge, Hold line) could pile up while the lane kept admitting work. docs/adr/** was not in floor-paths, so a lane PR could change an ADR and merge unattended. Owner decision (2026-10-21 /planning:interview, relayed by Issue Triage): held-cap 10 pauses admissions, keep held-alarm-hours 24, add docs/adr/** to the floor.

Fix

  • wipStatus(): paused is true on or after pause-from when over the WIP cap or the held cap; new field pause_reason (wip, held-cap, wip,held-cap, else null).
  • main(): on every pause, ::notice title=admission paused::admission paused: reason=<r> countable=<n> wip_cap=<n> held=<n> held_cap=<n> plus the same line in the step summary (GitHub Support asked for a countable pause marker; its after-measure counts these instead of inferring pauses from run durations).
  • pr-pipeline.yaml: held-cap: 10; docs/adr/** first in floor-paths. The schema/limits.mjs default stays 60 for other repos.
  • README, action.yml and schema text updated: the held cap pauses too.
  • work-unblock reads status.paused through checkWip (label-unblocked.mjs:650), so its re-fire waits under both caps with no change.

Verification

  • node --test .github/actions/check-wip-cap/check-wip-cap.test.mjs: 22 pass. New or changed: held cap alone pauses only on or after pause-from with pause_reason=held-cap, 9 held does not; both caps give wip,held-cap; failed reads give null; main against this repo's config pauses at 10 held and logs the exact notice line; the summary carries the line on a pause and not otherwise; before pause-from the warning says it is not reached.
  • resolve.test.mjs 136 pass; label-unblocked.test.mjs 96 pass.
  • scripts/check-affected.sh: 9 passed, 4 skipped.
  • No test pins the docs/adr/** entry itself: floor matching is tested generically, and a test restating the list would only detect the change.

Related

🤖 Generated with Claude Code

https://claude.ai/code/session_01DZUxjJX2Sbu4ASZUPcwC3M

…s/adr/**

The held cap only alerted, so held lane PRs could pile up while the lane
kept admitting work. At or over wip.held-cap, on or after pause-from, the
lane now pauses like it does over the WIP cap; this repository sets 10.
Every pause logs one machine-readable `admission paused: reason=...` line
and check-wip-cap publishes pause_reason. docs/adr/** joins floor-paths.

Closes #8795

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01DZUxjJX2Sbu4ASZUPcwC3M
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 21, 2026 03:47
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-21T03:48:39.050519Z dbd77e6 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 5916a3df76aa494b81e8946eae42a897787185f8: 0 finding(s), 0 as inline comments.

Security review: PR 8803 at 5916a3d

No security findings.

The PR makes the held-lane-PR cap pause admissions in check-wip-cap. It adds a pause_reason output and an admission paused: log line, and it lowers held-cap from 60 to 10. It also adds docs/adr/** to floor-paths.

  • Log and summary injection: The new ::notice line goes through the existing escape() helper. The step-summary line is built from a fixed-set pause_reason plus numeric values that come from the base checkout's schema-validated config and from counts. No attacker-controlled text reaches the workflow command stream or the summary.
  • Pause trigger: The held count still uses the existing isHeld check on lane PRs: the needs-human or do-not-merge labels, or the body line Hold: a human merges this. I did not find a new path for an unprivileged outsider to reach that. Applying the labels needs write access, and changing a lane PR's body needs that PR's author. The worst case is a lane pause, which fails closed and is the intended behaviour. A failed read still never caps.
  • Instruction-surface lens: Nothing in the diff deletes or softens a guardrail. docs/adr/** joining floor-paths tightens the control, because lane PRs that change an ADR now score HIGH and wait for a human. A test covers this. I did not read docs/conventions/instruction-exception-register/README.md, because no removed rule needed checking against it.
  • Actions hardening: The diff changes no workflow triggers, permissions:, or action pins, so it falls outside this lane under the zizmor deferral.

Comment thread docs/conventions/pr-pipeline.yaml Resolved
@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed 5916a3df76aa494b81e8946eae42a897787185f8: 0 finding(s), 0 as inline comments.

I found no blocking defects in this PR and posted no inline comments. I read the diff and the PR context, and grepped for stale text; I did not run any tests. The test results in the PR body (22, 136 and 96 passing, check-affected.sh) are the author's claims, unverified by me.

Closing issue #8795, acceptance criteria

  • held-cap: 10 pauses admissions and held-alarm-hours stays 24. This is met in docs/conventions/pr-pipeline.yaml and in wipStatus(), where paused is now pausing && reasons.length > 0. heldOver uses >= (check-wip-cap.mjs:113), so reaching 10 pauses, and the new tests cover 9 and 10 held.
  • docs/adr/** is in floor-paths, and test_an_adr_waits_for_a_human asserts it scores HIGH. This is met.
  • Tests cover the held-cap pause, the new floor path and the pause line, so the third criterion is met too.
  • The observability request is met: a ::notice annotation plus a step-summary line, both with reason, counts and caps.

Non-blocking, not on a changed line

  • .github/workflows/work-resolve-issue.yml:118-119 still says "over the WIP cap on or after wip.pause-from; the held cap only alerts". This PR makes that false. The comment sits next to the pause logic this PR changes, and the PR updated every other copy of that sentence (action.yml, README, schema, script headers). Update the comment to "over the WIP cap or the held cap". Link:
    # When the WIP cap check pauses the lane (over the WIP cap on or after

Other notes

  • The PR body says a human merges it (Hold: a human merges this), which fits the HIGH floor on .github/** and docs/conventions/**.
  • The PR body and the issue text contained no instructions aimed at the lane.

Security & Cost low on #8803: the ::notice line skipped escape(), unlike the
::warning beside it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01DZUxjJX2Sbu4ASZUPcwC3M
@kyle-sexton
kyle-sexton added this pull request to the merge queue Oct 21, 2026
Merged via the queue into main with commit 311e74c Oct 21, 2026
27 checks passed
@kyle-sexton
kyle-sexton deleted the feat/held-cap-pause branch October 21, 2026 04:38
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.

feat(pr-pipeline): pause admissions at 10 held lane PRs and floor docs/adr/**

1 participant