PR Review-Fix Loop

pr-review-loop Sop

sop active workflow

PR Review-Fix Loop (mandatory)

Every PR goes through an automated review-fix cycle before the user sees it.

Process

  • Fresh review agent — spawn a new agent to review the PR diff. Fresh context every time, no carry-over bias.
  • If any issues found (blocking, nits, anything) — spawn a fix agent to address them, push to the PR branch, and post a PR comment explaining the changes.
  • Fresh review agent again — spawn a NEW review agent on the updated PR. Never reuse a prior reviewer.
  • Repeat until the review agent finds zero issues — no blockers, no nits, nothing.
  • Present to user — only after a clean review pass, present the PR link and the final review summary. User makes the merge decision.
This loop is non-negotiable. No PR is presented as "ready" until it survives a clean review pass.

Key Rules

  • Each review agent is fresh — no context from previous reviews
  • Fix agents push to the PR branch, not a new branch
  • Post PR comments explaining each fix round
  • The user NEVER sees the PR until a clean pass
  • PR body should follow template: get_note(slug="template-pr-body")
  • pr-lifecycle — see Stage 4 for how this fits into the full lifecycle
  • /review-pr skill — orchestrates this loop