Repository navigation
fix: release scenario settled-rerun fails - #880
Conversation
The draft pull request opens before any code: the Spec as its checklist.
|
The pull request's board
🤖 AI-generated · Claude Opus 5.5 (Anthropic) |
A comment in the pull request's conversation that settled a finding the review had raised inline fitted neither case the reply recorded, so nothing re-ran the review and the release scenario settled-rerun never held. On an issue_comment, review-reply.yml now shows the reply the bot's open review threads, lets settles name any finding of the review's summary, and resolves the finding's thread (matched on its first line, as claude-review.yml writes it) along with the dx-settled mark that re-runs the review. Closes #871 Assisted-by: Claude Opus 5.5 (Anthropic)
|
The autopilot ticked every criterion but ended without finishing. The checks ( 🤖 AI-generated · Claude Opus 5.5 (Anthropic) |
|
The autopilot ended without a result. The agent finished without marking the pull request ready or saying why it stopped. Nothing was marked ready and the agent left no stop comment, so a person takes it from here ( 🤖 AI-generated · Claude Opus 5.5 (Anthropic) |
|
@soydiloreto: a person takes it from here ( 🤖 AI-generated · Claude Opus 5.5 (Anthropic) |
Claude review · risk high · complexity medium · type fixNothing that must be fixed · 3 minor · 1 pre-existing, not this pull request's First review of this pull request (no earlier commits or threads). The diff does what the description says. On an
Policy floor: high (touches high-risk paths: .github/workflows/claude-review.yml, .github/workflows/review-reply.yml, docs/agents.md, tests/workflows/test_settled_finding_rerun.py). Reviewed 37a53f0 (whole pull request; review 2 of 5 automatic). Author trusted for auto-merge: false. 🤖 AI review · claude-sonnet-5-5 (Anthropic) · $0.32, 12 turns |
|
@soydiloreto: a person takes it from here ( 🤖 AI-generated · Claude Opus 5.5 (Anthropic) |
📝 What changes
The cause is in
review-reply.yml.settled-rerunsettles the token finding with a comment in the pull request's conversation. The review posts a confirmed blocker inline, as a thread of its own (claude-review.yml, "each a thread to resolve"). The reply records a settlement, and with it re-runs the review, in only two cases. One isresolveon apull_request_review_commentinside the bot's own thread. The other issettleson anissue_commentnaming a finding "with no thread of its own", which is what the reply's prompt asks for. A conversation comment that settles a finding that has a thread fits neither case. Sosettledstays empty, nothing re-runs the review, and the scenario'srerunnever holds. The reply's model also cannot see those threads: on anissue_comment,thread.jsonholds only the conversation. docs/agents.md says the same rule ("its thread resolved, or adx-settledmark for a finding with no thread").The fix, in
review-reply.yml:issue_comment,thread.jsonalso lists the bot's open review threads (id, path, line, first comment), from the same GraphQL query the review-comment branch uses, and those threads are saved for the post step.settlesmay name any finding the review's summary lists, whether or not it has a thread.issue_commentwith a non-emptysettles, the workflow writes thedx-settledmark as before (settled=true), so the existing "Re-run the review on a settled finding" step runs: it still checks who decides, that the review blocked at the head, and that a review run finished there. The match is deterministic: a thread matches when its first comment starts with**<severity>**: <title>, which is how claude-review.yml writes it.One choice is a maintainer's: what happens to the finding's open thread.
settlesmatches one of the bot's open threads, the reply also resolves that thread through the existing "Resolve the thread" step (its id inresolve.txt,resolve=true), with the token minted after the model ran. The settlement is then visible on the finding where it was raised, exactly as when someone answers inside the thread, so the two ways of settling give the same result.resolved_threads, so it depends on the model doing that.Either way, no permission, secret, lane or limit is widened: the steps, tokens and permissions are the ones already there (
pull-requests: writeresolves a thread today,actions: writere-runs today). The gates and what they check do not change. The release scenario stays as it is. The header comments of review-reply.yml and claude-review.yml (#699 C5), and docs/agents.md and docs/pull-requests.md, change to say that a conversation answer can settle a finding that has a thread.💡 Why
Closes #871. The autopilot works it here in the open: one commit per criterion, each box ticked once its commit is pushed.
🎯 Acceptance criteria
settled-rerunin the test repository, then it passes and the lane releases it.Test: tests/workflows/test_settled_finding_rerun.py (runs review-reply.yml's "Pull request and thread" step on an
issue_comment, withghstubbed, and asserts thatthread.jsonlists the bot's open review threads. Runs its "Post the reply" step on anissue_commentwhosesettlesnames a finding that has an open bot thread, and assertssettled=true, thedx-settledmark in the reply and, with option A,resolve=truewith that thread's id. At the base both fail on an assertion. Also asserts that asettlesthat matches no thread still settles with no resolve, which must not change.)🧭 Decisions
🙌 Credits
🧪 How I tested it
The required checks ran at 165cfb6 and passed: Scripts (self-tests), Test first (the test fails at the base and passes at the head), actionlint and the conventions, in https://github.com/DiluxOne/.github/actions/runs/44599936545. A maintainer marked this pull request ready: the autopilot at
v7(v7.18.0) refuses to finish a release lane's bug, because it reads a reproduction test from the PRD and this issue has only the lane's scenario. Reading the scenario as the evidence (scenario_evidence) is on main since #836, not in v7.18.0, and it ships in the release this fix unblocks.🤖 AI-generated · Claude Opus 5.5 (Anthropic)