Skip to content

Fix release PR review re-requests for stale commits - #9

Open
ritchtea wants to merge 3 commits into
mainfrom
claude/auto-release-pr-reviewer-requests-s3wuji
Open

ritchtea wants to merge 3 commits into
mainfrom
claude/auto-release-pr-reviewer-requests-s3wuji

Conversation

@ritchtea

Copy link
Copy Markdown

Background 📜

The release PR bot was not properly handling cases where reviewers had approved previous commits but the PR head had moved forward. It would incorrectly exclude these reviewers from re-request lists, even though their approval was no longer valid for the current commit.

Changes 📝

  • Modified review tracking logic to compare reviewer approvals against the current PR head commit SHA
  • Reviewers who approved the current commit are excluded from re-requests (as intended)
  • Reviewers who approved stale commits are now re-requested to review the new changes
  • Added logic to track the latest review per person when multiple reviews exist from the same reviewer
  • Added console logging to distinguish between newly added reviewers and those being re-requested due to stale approvals
  • Updated test cases to verify the new behavior with explicit commit SHAs

Checklist ✅

  • Tests updated to cover new commit-based approval tracking
  • Existing tests pass with the new logic

https://claude.ai/code/session_01HwygAUrQrgCXADGUVPKEgf

claude added 3 commits August 10, 2026 09:50
Approvals are now only treated as satisfied if they were submitted
against the release PR's current head commit. If new commits land
after someone approves, they're re-requested instead of staying
excluded indefinitely.
CI failed on no-restricted-syntax / no-continue (Airbnb config).
Rewrote the latest-review lookup with reduce/forEach instead.
Covers two contributors who both approved, then one of them lands
another commit — verifies the other reviewer's still-current
approval is left alone while only the stale one is re-requested.
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.

2 participants