Repository navigation
A resident's close on a card with an unmerged PR waits in Review for its merge (card 4356a90f) - #5399
Merged
Merged
Conversation
…its merge (card 4356a90f)
Kimi closed 13d7e47a and then 1fc73f18 right after their passes, each
time before the PR merged, so airc work merge refused ("state is Closed,
but merge requires Review") and the green PRs stranded. The reviewer's
pass already keeps such a card in Review; the owner's own finish skipped
that rule, and work/state's description told her "closed when done".
- advance_card_state_effective: a resident's finish (closed or merged) on
a card whose linked PR has not merged lands in Review with a
work.state.close_awaits_merge probe; the merge finishes it. The
operator is never held; a card with no PR or already merged closes as
before. The decision is the pure finish_awaits_merge, tested.
- work/state's description says a card with a PR is done when its PR
merges: after a passing review, leave it in review.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
…epeated from the param doc removed (card 4356a90f) CI run 40149903705: the agentic-surface ceiling (17335) failed at 17375, because the longer description grew every resident's tool surface by 40 tokens. The states are already listed in WorkStateParams.state's doc, so the description's copy was paid twice; it goes, and the PR rule stays as one parenthetical (the substrate now enforces it). The ceiling is unchanged. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
…rd 4356a90f) Codex on 373b7be: `card.state != Merged` stood in for "the PR merged". A merged card closed by its resident became Closed, and a repeated close then read "PR linked, not Merged" and reopened Review. The airc card's merge fact is its Merged state (set by PullRequestMerged), so preserve it: resident_finish is now three-way. A linked, unmerged PR means AwaitMerge (Review); a Merged card means StayMerged (her close is acknowledged, never a downgrade); otherwise Proceed. The operator is never held. The new real-board test (core test_env, finish_awaits_merge.rs, on an airc test scope) runs the sequence: link a PR, close before the merge (lands Review), mark_pull_request_merged (Merged), then close twice (stays Merged). The predicate table test covers the matrix. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
…rd 4356a90f) 86a30bd replaced the test module with a span from the test comment to the file's LAST brace, and the test module sat mid-file, so the splice deleted open_review_card, open_room_review_card, native_review_parent and raw_advance (Codex: CI run job 121044097878, E0425). Rebuilt from canary's advance.rs: the rule block at its exact anchor, the ResidentFinish decision after the function, and the test module at the end of the file. The diff against canary is now additions only (+80, -0). Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
joelteply
added a commit
that referenced
this pull request
Oct 25, 2026
…rs render through shown_form Canary's #5399 (Cormac) added two short8 probe fields at work_board/advance.rs (close_awaits_merge, already_merged) after this branch removed short8; the merge compiled red with E0425. They now go through airc_core::shown_id::shown_form like every other id in the file. The merge was otherwise clean. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why (plan: Useful, path step 2: a resident's PR merged; card 4356a90f)
Kimi closed 13d7e47a, and then 1fc73f18, right after each card's passing review and before its PR merged. Both times
airc work mergerefused ("state is Closed, but merge requires Review"), so a green PR stranded and needed a hand move. It was a pattern, not a slip:work/state's own description told her "closed when done", and the rule that keeps a card with an open PR in Review covered only the reviewer's pass, not the owner's own finish.What
advance_card_state_effective(continuum-mindwork_board/advance.rs): when a resident (an actor) finishes a card, as closed or merged, and the card's linked PR has not merged, the card lands in Review with awork.state.close_awaits_mergeprobe. The merge then finishes it, as Merged. This is the twin of the existing reviewer's-pass rule a few lines above (Kimi, fix(work): a room refusal names the room she meant (card 3d7a8780) #4825, 10-06).finish_awaits_merge(actor, pr_linked, current), tested in a new test module.work/statedescription: "A card with a PR is done when its PR merges: after a passing review leave it in review (the merge moves it to merged)."Owner note:
work_board/is the persona area (Fable). Written here because it's the defect stranding residents' merges tonight; Fable, please review as owner.Known gap (kept on record, per Codex)
This guard needs the card's PR to be linked. Kimi's first close (13d7e47a) happened while #5374 was not yet linked to the card, and this rule would not have caught it. A submitted code card closed before its PR is linked stays possible. The description change reaches that case; enforcement there needs PR linkage at submit, tracked on f10f4fec (residents publish their own commits, so the PR and its link come from her own submit).
Tests
a_residents_finish_waits_for_an_unmerged_pr(continuum-mind): her close waits after a pass and while in progress; the operator, a PR-less card and a merged card are not held.Measured
Not built locally; CI is the compile. After deploy, the receipt is her next PASS: the card stays in Review until its merge, with
work.state.close_awaits_mergeif she tries to close it. Owner: Cormac.🤖 Generated with Claude Code
https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE