Repository navigation
feat(pr-review): self-host pin via trigger stub — reusable-only (#497/#506) - #523
Conversation
…#506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 29 minutes and 49 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (3)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Note Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported. |
There was a problem hiding this comment.
💡 Codex Review
https://github.com/petry-projects/.github-private/blob/017721cb8069d31096c0238d7e041f62b9b66d01/.github/workflows/pr-review.yml#L3-L4
Keep deployed PR-review workflow runnable
In this repo I checked .github/workflows/deploy-pr-review.yml:46 and .github/workflows/force-deploy-pr-review.yml:37; both still copy .github/workflows/pr-review.yml into target repos as their PR-review workflow. After this change that file only exposes workflow_call, so the next deploy would overwrite those repos' event/manual triggers with a reusable-only workflow and PR review would stop running there. Please either update the deploy jobs to ship a trigger stub or keep the deployed workflow triggerable.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| jobs: | ||
| review: | ||
| uses: petry-projects/.github-private/.github/workflows/pr-review.yml@pr-review/stable |
There was a problem hiding this comment.
Point health checks at the trigger workflow
The daily health script still hard-codes WORKFLOW_FILE="pr-review.yml" and queries actions/workflows/${WORKFLOW_FILE}/runs in scripts/pr_review_health.sh, but these events now create runs for the caller workflow (pr-review-trigger.yml) while the reusable workflow's jobs are nested inside that run. Once this lands, failed PR-review executions will be recorded under the trigger workflow, so the health check can report success after inspecting zero/stale pr-review.yml runs. Please update the health check to query the new trigger workflow (or both files).
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Fixed in scripts/pr_review_health.sh: changed WORKFLOW_FILE from pr-review.yml to pr-review-trigger.yml. Now that pr-review.yml is reusable-only, all event-triggered runs are recorded under the trigger stub, so the health check queries the right workflow and will no longer inspect a stale/empty run list.
Dev-Lead — review-changes (applied)Changes committed and pushed. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
There was a problem hiding this comment.
Pull request overview
This PR breaks the self-hosting circular dependency for .github-private’s PR review automation by moving event triggers into a thin “trigger stub” workflow that calls the actual review workflow pinned to the pr-review/stable channel tag, ensuring both the workflow logic and the checked-out agent scripts run from the same pinned ref.
Changes:
- Converted
.github/workflows/pr-review.ymlto reusable-only (workflow_callonly) by removing its direct event triggers. - Added
.github/workflows/pr-review-trigger.yml, which owns the event triggers and callspr-review.yml@pr-review/stablewithagent_ref: pr-review/stable. - Preserved manual and mention-triggered entrypoints (
workflow_dispatch,repository_dispatch) via the new stub.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| .github/workflows/pr-review.yml | Removes event triggers to make the workflow reusable-only and callable from a pinned ref. |
| .github/workflows/pr-review-trigger.yml | New trigger stub that carries event triggers and invokes the reusable workflow pinned to pr-review/stable, forwarding key inputs. |
…506) (#523) * feat(pr-review): self-host pin via trigger stub (reusable-only) (#497, #506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * chore: apply manual instructions [skip ci-relay] --------- Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
…506) (#523) * feat(pr-review): self-host pin via trigger stub (reusable-only) (#497, #506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * chore: apply manual instructions [skip ci-relay] --------- Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
…506) (#523) * feat(pr-review): self-host pin via trigger stub (reusable-only) (#497, #506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * chore: apply manual instructions [skip ci-relay] --------- Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
…506) (#523) * feat(pr-review): self-host pin via trigger stub (reusable-only) (#497, #506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * chore: apply manual instructions [skip ci-relay] --------- Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
…506) (#523) * feat(pr-review): self-host pin via trigger stub (reusable-only) (#497, #506) Flip .github-private's own pr-review to run the pinned known-good version, breaking the self-hosting circular dependency for ring 0. - pr-review.yml: now reusable-only (event triggers removed). Its job is unchanged and still reads github.event.* (inherited) + inputs.* (forwarded). - pr-review-trigger.yml (new): thin stub carrying the review event triggers (check_suite, pull_request_review, pull_request, workflow_dispatch, repository_dispatch=pr-review-mention) that calls pr-review.yml@pr-review/stable with agent_ref=pr-review/stable, so BOTH the workflow and the agent scripts run at the pinned channel (#506) regardless of what is on the branch under review. Squash-merge flips both atomically (no review-coverage gap). Promotion is a pr-review/stable tag move; this stub never changes. Mention flow preserved via the repository_dispatch trigger. Part of #497 · epic #495. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * chore: apply manual instructions [skip ci-relay] --------- Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>



The ring-0 self-host pin. Flips .github-private's own pr-review to run the pinned
pr-review/stableversion, breaking the self-hosting circular dependency.pr-review.yml→ reusable-only (event triggers removed; job logic unchanged — reads inheritedgithub.event.*+ forwardedinputs.*).pr-review-trigger.yml(new stub) → carries the triggers, callspr-review.yml@pr-review/stablewithagent_ref: pr-review/stableso workflow and scripts ([Phase 2] Reusable workflow must run scripts at the caller's channel ref (no silent version mismatch) #506) run pinned.Squash-merge flips both atomically (no review-coverage gap). Mention flow preserved (repository_dispatch). After merge I'll validate the stub fires + reviews at
@stable, and revert if not. Part of #497 · epic #495.