Skip to content

ci: Claude review always reports, approves when sure, matches openpoker - #46

Merged
Jish2 merged 3 commits into
mainfrom
claude/wizardly-hopper-b3c1x4
Oct 7, 2026
Merged

Jish2 merged 3 commits into
mainfrom
claude/wizardly-hopper-b3c1x4

Conversation

@Jish2

@Jish2 Jish2 commented Oct 7, 2026 •

Copy link
Copy Markdown
Owner

Brings the review workflow in line with Jish2/openpoker (same file apart from the list of sensitive paths) and adds reporting and auto-approval.

From openpoker

  • Skip fork PRs, which can't read repo secrets. Manual runs still go ahead.
  • Review every push without repeating settled points. The plugin used to stop once Claude had commented, so later pushes were never reviewed. It now reads earlier inline comments, summaries and reviews first, and only re-raises a point the author answered if new commits bring it back.

Always reports

  • Every run ends with one summary comment. Its first line says the review was skipped (and why), found no issues, or found N issues. It also says whether Claude approved, and if not, which condition failed.
  • Small or trivial PRs are reviewed too, instead of being skipped by the plugin.
  • A last step checks for that summary using a per-run marker. If it's missing because the review crashed or stopped early, the step posts "did not finish" with a link to the run.
  • New claude-review-skip-notice.yml covers the PRs the review job never starts for. It comments when a PR opens or reopens as a draft or is converted to draft ("will run once marked ready"), and when a PR comes from a fork (with a link to run the review by hand). It uses pull_request_target so it can comment on fork PRs, and it never checks out PR code. Because pull_request_target runs from the base branch, it only takes effect after this merges.

Auto-approve

  • Claude approves (gh pr review --approve) only when all of these hold:
    • nothing was found in this run
    • no earlier finding is still open
    • it read and understood the whole diff
    • it would be comfortable with the PR merging unread
    • nothing under .github/ or install.sh changed
  • If Claude approved an earlier push and can't approve this one, it withdraws that approval with a change request. It never requests changes otherwise.
  • The allowed tools only permit gh pr review on this PR, with --approve or --request-changes.

This PR changes .github/, so Claude won't approve it itself.

🤖 Generated with Claude Code

https://claude.ai/code/session_01EaxBdAMckGCpk8mbWqaU13

claude added 2 commits October 7, 2026 23:33
Port the features the openpoker repo's review workflow has:
- skip fork PRs, which cannot read the repo secrets
- review every push without repeating settled points: read earlier
  inline comments and summaries first, and only re-raise a point the
  author answered if new commits reintroduce it. The code-review plugin
  otherwise stops once Claude has commented, so later pushes were never
  reviewed. Allows the read-only PR comments API call this needs.

The PR number now comes from a job-level PR_NUMBER shared by both
triggers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EaxBdAMckGCpk8mbWqaU13
- Every run ends with one summary comment: skipped (and why), no issues
  found, or N issues found, plus whether it approved. A follow-up step
  posts a "did not finish" comment if that summary is missing, so a
  crash or early stop is never silent.
- Review small and trivial PRs too, instead of the plugin skipping them.
- Approve only when nothing was found, no earlier finding is still open,
  Claude would be comfortable with it merging unread, and no sensitive
  path changed. If Claude approved an earlier push and cannot approve
  this one, it withdraws the approval with a change request.

Never auto-approves changes to .github/ or install.sh.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EaxBdAMckGCpk8mbWqaU13
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown

Claude review: did not finish (step outcome: success). Nothing was reviewed or approved for this push. See the run log.

@Jish2 Jish2 changed the title ci: bring Claude review up to par with the openpoker workflow ci: Claude review always reports, approves when sure, matches openpoker Oct 7, 2026
Drafts and fork PRs never start the review job, so they got no word
from it. A small pull_request_target workflow now comments when a PR
opens or reopens as a draft, is converted to draft, or comes from a
fork (with how to run the review by hand). It never checks out PR code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EaxBdAMckGCpk8mbWqaU13
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown

Claude review: did not finish (step outcome: success). Nothing was reviewed or approved for this push. See the run log.

@Jish2
Jish2 merged commit 219055a into main Oct 7, 2026
1 check passed
@Jish2
Jish2 deleted the claude/wizardly-hopper-b3c1x4 branch October 7, 2026 23:49
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