You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When praisonai-triage-agent[bot] opens a PR via claude.yml (gh pr create), the pull_request: opened event sometimes does not trigger downstream GitHub Actions. The full review chain (CodeRabbit → Copilot → FINAL @claude) never starts.
Example:PR #2245 — opened 2026-06-24 13:34:57 alongside #2243 and #2244 within ~11 seconds. #2243/#2244 got Auto PR Comment + full chain; #2245 got zero pull_request workflow runs and only a Greptile comment.
flowchart TD
A[claude.yml creates PR via App token / GITHUB_TOKEN] --> B{pull_request opened fires?}
B -->|Yes| C[bot-pr-trigger-reviews in auto-pr-comment.yml]
C --> D["@coderabbitai + /review as MervinPraison PAT"]
D --> E["@copilot → FINAL @claude"]
B -->|No / dropped in burst| F[No workflows run]
F --> G[Only external apps e.g. Greptile comment]
G --> H[No @claude ever posted]
Loading
Contributing factors:
GitHub limitation: Events triggered by GITHUB_TOKEN (including GitHub App tokens used by claude-code-action for gh pr create) may not trigger new workflow runs on pull_request: opened.
Burst bot PR creation: When multiple bot PRs open within seconds, GitHub can drop/suppress events for later PRs in the batch (observed: 3rd PR in burst missed all workflows).
No fallback in claude.yml: After gh pr create, nothing uses GH_TOKEN PAT to kick the review chain.
Greptile is not wired into chain:auto-pr-comment.yml only chains off CodeRabbit/Qodo/Copilot — not Greptile alone.
1. Post-PR-create hook in claude.yml (primary fix)
After Claude runs gh pr create for issue fixes, add a final workflow step (only when a new PR was created) that uses secrets.GH_TOKEN (PAT as MervinPraison) to:
- name: Kick review chain for bot-created PRif: steps.check_fork.outputs.is_pr != 'true' # issue flow that created PRenv:
GH_TOKEN: ${{ secrets.GH_TOKEN }}run: | PR_NUM=$(gh pr list --head "$BRANCH" --json number -q '.[0].number') # Same as bot-pr-trigger-reviews gh pr comment "$PR_NUM" --body '@coderabbitai review' gh pr comment "$PR_NUM" --body '/review'
Or consolidate into a shared actions/github-script step matching bot-pr-trigger-reviews logic (dedupe if comments already exist).
Also: use GH_TOKEN PAT for gh pr create itself (not App token) where possible — PAT-created PRs are more likely to trigger downstream workflows.
2. Idempotent review-chain helper in auto-pr-comment.yml
Extract bot-pr-trigger-reviews body into a reusable composite action or callable workflow (workflow_call) so both:
pull_request: opened (existing path)
claude.yml post-create step
workflow_dispatch with pr_number input (manual recovery)
…can invoke the same logic without duplication.
3. Scheduled / recovery scanner (belt-and-braces)
Add a lightweight cron job (e.g. every 15 min) or extend existing merge-conflict scanner to find open bot PRs where:
Author is praisonai-triage-agent[bot] or github-actions[bot]
Opened > 10 min ago
No@coderabbitai review comment from MervinPraison
No FINAL @claude comment from MervinPraison
→ Post review-chain kick via PAT.
4. Optional: claude-fallback-timeout improvement
Current claude-fallback-timeout waits 15 min on pull_request: opened — useless if opened never fired. Change trigger to also run from recovery scanner or repository_dispatch.
Acceptance criteria
Bot-created PR gets @coderabbitai review + /review within 2 min even when pull_request: opened does not fire
Burst creation of 3+ bot PRs in <30s — all get review chain kick
No duplicate @coderabbitai / @claude comments (dedupe guard)
Manual recovery: gh workflow run bot-pr-recovery.yml -f pr_number=XXXX
Document in .agent/workflows/review-chain.md
Test plan
Simulate bot PR create from claude.yml on a test issue; verify review comments appear without relying on pull_request: opened.
Open 3 bot PRs in rapid succession; confirm all receive chain kick.
Summary
When
praisonai-triage-agent[bot]opens a PR viaclaude.yml(gh pr create), thepull_request: openedevent sometimes does not trigger downstream GitHub Actions. The full review chain (CodeRabbit → Copilot → FINAL@claude) never starts.Example: PR #2245 — opened 2026-06-24 13:34:57 alongside #2243 and #2244 within ~11 seconds. #2243/#2244 got
Auto PR Comment+ full chain; #2245 got zeropull_requestworkflow runs and only a Greptile comment.Manual unblock applied: FINAL
@claudecomment posted on #2245 — #2245 (comment)Root cause
flowchart TD A[claude.yml creates PR via App token / GITHUB_TOKEN] --> B{pull_request opened fires?} B -->|Yes| C[bot-pr-trigger-reviews in auto-pr-comment.yml] C --> D["@coderabbitai + /review as MervinPraison PAT"] D --> E["@copilot → FINAL @claude"] B -->|No / dropped in burst| F[No workflows run] F --> G[Only external apps e.g. Greptile comment] G --> H[No @claude ever posted]Contributing factors:
GITHUB_TOKEN(including GitHub App tokens used byclaude-code-actionforgh pr create) may not trigger new workflow runs onpull_request: opened.claude.yml: Aftergh pr create, nothing usesGH_TOKENPAT to kick the review chain.auto-pr-comment.ymlonly chains off CodeRabbit/Qodo/Copilot — not Greptile alone.Affected workflow:
.github/workflows/auto-pr-comment.ymljobbot-pr-trigger-reviews(requirespull_request: opened).Required changes
1. Post-PR-create hook in
claude.yml(primary fix)After Claude runs
gh pr createfor issue fixes, add a final workflow step (only when a new PR was created) that usessecrets.GH_TOKEN(PAT as MervinPraison) to:Or consolidate into a shared
actions/github-scriptstep matchingbot-pr-trigger-reviewslogic (dedupe if comments already exist).Also: use
GH_TOKENPAT forgh pr createitself (not App token) where possible — PAT-created PRs are more likely to trigger downstream workflows.2. Idempotent review-chain helper in
auto-pr-comment.ymlExtract
bot-pr-trigger-reviewsbody into a reusable composite action or callable workflow (workflow_call) so both:pull_request: opened(existing path)claude.ymlpost-create stepworkflow_dispatchwithpr_numberinput (manual recovery)…can invoke the same logic without duplication.
3. Scheduled / recovery scanner (belt-and-braces)
Add a lightweight cron job (e.g. every 15 min) or extend existing merge-conflict scanner to find open bot PRs where:
praisonai-triage-agent[bot]orgithub-actions[bot]@coderabbitai reviewcomment fromMervinPraison@claudecomment fromMervinPraison→ Post review-chain kick via PAT.
4. Optional:
claude-fallback-timeoutimprovementCurrent
claude-fallback-timeoutwaits 15 min onpull_request: opened— useless ifopenednever fired. Change trigger to also run from recovery scanner orrepository_dispatch.Acceptance criteria
@coderabbitai review+/reviewwithin 2 min even whenpull_request: openeddoes not fire@coderabbitai/@claudecomments (dedupe guard)gh workflow run bot-pr-recovery.yml -f pr_number=XXXX.agent/workflows/review-chain.mdTest plan
claude.ymlon a test issue; verify review comments appear without relying onpull_request: opened.Related
.github/workflows/claude.yml,.github/workflows/auto-pr-comment.yml