From dc6e452d0c53db084751b90cd6d78520ffe620ee Mon Sep 17 00:00:00 2001 From: Self-Managing Codebase Manager <7004983+WillTaylor22@users.noreply.github.com> Date: Tue, 26 May 2026 10:15:54 +0000 Subject: [PATCH] memory: closed PR can receive REQUEST_CHANGES after dup-close --- .claude/memory/MEMORY.md | 1 + ...6-05-26-closed-pr-receives-review-after-close.md | 13 +++++++++++++ 2 files changed, 14 insertions(+) create mode 100644 .claude/memory/learnings/2026-05-26-closed-pr-receives-review-after-close.md diff --git a/.claude/memory/MEMORY.md b/.claude/memory/MEMORY.md index 9f678d0..81bc8ef 100644 --- a/.claude/memory/MEMORY.md +++ b/.claude/memory/MEMORY.md @@ -8,6 +8,7 @@ Keep this file under 200 lines — anything longer is content bloat, not memory. - [learnings/vercel-blocks-unknown-author-email](learnings/2026-05-26-vercel-blocks-unknown-author-email.md) — Vercel preview deploys block when commit author email has no GitHub account; use the noreply alias - [learnings/sandbox-cant-clone-private-repo](learnings/2026-05-26-sandbox-cant-clone-private-repo.md) — Don't `git clone` from sandbox bash; the `github_repository` resource is auth'd, raw `git clone` is not - [learnings/github-mcp-strips-html-comments](learnings/2026-05-26-github-mcp-strips-html-comments.md) — `update_pull_request` silently strips `` from PR bodies; session-id marker can't be set by agent (ENG-25) +- [learnings/closed-pr-receives-review-after-close](learnings/2026-05-26-closed-pr-receives-review-after-close.md) — Closed PR can still get a REQUEST_CHANGES review seconds after dup-close; don't reopen, surface to sibling PR + Linear (PR #18 vs #20 ENG-25 race) ## Decisions - [decisions/mcp-for-small-writes-checkout-for-big](decisions/2026-05-26-mcp-for-small-writes-checkout-for-big.md) — Single-file writes go through GitHub MCP; multi-file or test-needing changes use the mounted checkout + `git push` diff --git a/.claude/memory/learnings/2026-05-26-closed-pr-receives-review-after-close.md b/.claude/memory/learnings/2026-05-26-closed-pr-receives-review-after-close.md new file mode 100644 index 0000000..f436945 --- /dev/null +++ b/.claude/memory/learnings/2026-05-26-closed-pr-receives-review-after-close.md @@ -0,0 +1,13 @@ +# Closed PR can receive `AGENT_REVIEW: REQUEST_CHANGES` seconds after close (race) + +PR #18 (ENG-25) was closed at 10:10:16Z as a duplicate of PR #20. A second reviewer-agent pass posted `AGENT_REVIEW: REQUEST_CHANGES` at 10:10:45Z — ~30s after the close, presumably from a reviewer session that started before the dedup-close fired. The dispatcher's review-feedback webhook still kicked off a manager session for PR #18 even though the PR was closed. + +What to do when this happens: +1. **Don't reopen** to "follow the kickoff literally" — that undoes the prior session's intentional dedup decision and creates two open PRs again. +2. **Don't push to the closed branch** — pushes to a closed PR's branch don't trigger re-review and aren't visible anywhere useful. +3. **Don't push to the sibling live PR's branch** unless that PR is owned by the same session id — each session owns its own branch; cross-session pushes step on work. +4. **Do** post a clear comment on the closed PR explaining the race and pointing to the live sibling. +5. **Do** cross-post the substantive feedback on the live sibling PR so its session sees it. +6. **Do** capture the feedback on the Linear ticket too, so a future session picks it up if both PRs stall. + +Round-limit accounting: a `REQUEST_CHANGES` on a closed PR doesn't count toward the 3-round limit on the live sibling (different PR, different review thread). But the substantive ask still has to land somewhere; surfacing on the ticket is what keeps it from rotting.