Repository navigation
fix(apply-review-hold): carry no cost decision past a deleted comment - #879
Conversation
The decided head is the newest cost hold marker before the decision. If that marker was deleted, an older one became the decided head, so a decision could carry to a diff the owner never saw. carryDecision now reads the pull request timeline's COMMENT_DELETED_EVENT items after the marker's edit check and carries nothing when any comment was deleted at or after the marker was posted, or when the list cannot show none was (failed read, filteredCount above the listed nodes, no list or integer count, or a time that does not parse). This is the rule merge-holds.mjs deletedSince applies in melodic-software/claude-code-plugins#9569. Refs: melodic-software/claude-code-plugins#9436 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Claude finished @kyle-sexton's task in 2m 6s —— View job Security review complete
Scope: Analysis: The fix adds Failure modes are handled fail-closed, not fail-open: a failed GraphQL read, a missing/non-array node list, a non-integer No security-relevant gaps found in this diff. No CRITICAL/IMPORTANT/SUGGESTION findings to report. critical-findings: 0 claude-lane-summary: lane=claude-security-review sha=0f171b3d338c5cc53317f175c319990d322a8b91 run=40104734217 |
|
Claude finished @kyle-sexton's task in 3m 34s —— View job Code review
No blocking or advisory findings. What I checked:
Reviewed as the code-review lane; security-relevant concerns (none found) would be left to the separate security lane per Findings reported: 0 claude-lane-summary: lane=claude-review sha=0f171b3d338c5cc53317f175c319990d322a8b91 run=40104734217 |
|
claude-security-review has reviewed this pull request through 1a570ec; a later push is reviewed from there. |
|
claude-review has reviewed this pull request through 1a570ec; a later push is reviewed from there. |
comment-hygiene flags an owner/repo#number reference in a code comment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Claude finished @kyle-sexton's task in 22s —— View job Code review (incremental)
Scope: Skip gate applied: the incremental change is a comment-only reword — it drops the No blocking or advisory findings. claude-lane-summary: lane=claude-review sha=1a570ecf75dff314dcddd642089e5144eaaf64cd run=40105205946 |
|
Claude finished @kyle-sexton's task in 24s —— View job Security review complete
Scope: incremental review since -// one the decided head (owner decision Q18 d on
-// melodic-software/claude-code-plugins#9436, as merge-holds.mjs deletedSince
-// reads it): any comment deleted at or after the decided-head marker was
-// posted carries nothing. The pull request timeline's COMMENT_DELETED_EVENT
+// one the decided head (as merge-holds.mjs deletedSince reads it): any
+// comment deleted at or after the decided-head marker was posted carries
+// nothing. The pull request timeline's COMMENT_DELETED_EVENTThis drops a cross-repo issue-tracker reference from a code comment above a test case. No test logic, assertion, fixture, or behavior changed — only prose in a comment. It touches no instruction surface ( Skip gate: triggered — this diff has no security-relevant surface (gate item 2). No findings to report for this increment. manifest: no manifest files changed. critical-findings: 0 claude-lane-summary: lane=claude-security-review sha=1a570ecf75dff314dcddd642089e5144eaaf64cd run=40105205946 |
…contract (#874) Refs: melodic-software/ci-workflows#879 ## Summary Registers the `pr-review-cli.yml` reusable-workflow contract at ci-workflows [v0.65.6](https://github.com/melodic-software/ci-workflows/releases/tag/v0.65.6) (`914264587c35692c15e05c965103426eec18d1f0`), so callers pinned to that release pass runner-policy. ## Fix Copies the v0.65.5 entry (`@f1096608192c54cfb3dc252e36670e6f86700b9b`) forward in `components/runner-policy/policy.json` and adds the matching copy-forward test in `runner-policy.test.mjs`, as #870 and #871 did. Earlier pins stay as history. `gh api compare v0.65.5...v0.65.6` on ci-workflows lists three changed files; the `pr-review-cli.yml` patch is comment-only (ci-workflows#879: a cost decision carries no further once a pull request comment was deleted since its hold marker), so inputs, secrets and permissions are unchanged. ## Verification - `node components/runner-policy/runner-policy.mjs --root <worktree>`: Runner policy passed. - `node --test components/runner-policy/runner-policy.test.mjs`: 348 tests, 348 pass, 0 fail. ## Related - melodic-software/ci-workflows#879 (the fix released as v0.65.6) - #871 (the v0.65.5 contract) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Refs: melodic-software/claude-code-plugins#9436
Summary
The hold step carries a recorded cost decision onto a later head from the
decided head: the
sha=of this lane's newest cost hold marker posted beforethe decision. If that newest marker was deleted, an older marker became the
decided head, so a decision could carry to a diff the owner never saw. This
applies the rule merge-holds.mjs
deletedSinceapplies inmelodic-software/claude-code-plugins#9569 (owner decision Q18 d on #9436), so
both readers refuse the same carries.
Fix
carryDecision()reads the pull request timeline'sCOMMENT_DELETED_EVENTitems (GraphQL,
last: 100, withfilteredCount) after the marker's editcheck and before the head check, so deleting a newer marker cannot promote an
older head.
created_at, logged as "a comment was deleted since the decided-head markerwas posted".
decided-head marker was posted", when the read fails, the answer has no node
list,
filteredCountis not an integer,filteredCountexceeds the listednodes, or a deletion time does not parse.
(no older one stands in), an unusable base name, 300 or more compared files, a
missing patch, a duplicate filename, a failed compare.
pr-review-cli.ymlhold-step contract comment states the rule.Verification
node --test .github/scripts/apply-review-hold.test.cjs: 42 pass (38 before).New cases: a deletion after the newest marker, with an older marker at the
head's sha left, holds with no compare; a deletion at the marker's own time
holds and one before it carries; eight unreadable deletion lists (failed read,
null timeline, no node list, no count, a string count, 101 counted with 100
listed, an unparsable time, an event with no time) hold; an edited marker reads
no deletion list. Three call-sequence tests now expect the deletion read.
Against main's
hold.cjs, 6 fail: the 3 new behavior cases and the 3 updatedcall-sequence cases.
node --test .github/scripts/pr-review-cli-api-calls.test.cjs: 10 pass.node --test .github/scripts/pr-review-cli.test.cjs: 24 pass.biome ci --error-on-warningson the test file with biome 2.5.15 locally (CIpins 2.5.11): clean. The workflow change is comment-only; CI's actionlint job
covers it.
Related
same rule.
designed.
🤖 Generated with Claude Code