Skip to content

ci: allow the bot actor, and stop push runs cancelling their own handoff - #149

Merged
lopugit merged 1 commit into
mainfrom
claude/resolver-allow-bot-actor
Jul 30, 2026
Merged

ci: allow the bot actor, and stop push runs cancelling their own handoff#149
lopugit merged 1 commit into
mainfrom
claude/resolver-allow-bot-actor

Conversation

@lopugit

@lopugit lopugit commented Jul 27, 2026

Copy link
Copy Markdown
Owner

Found by a deliberate canary

Built a throwaway conflict (PR #148 against a scratch base branch) to exercise push → detect → handoff → repository_dispatch → resolve end to end for the first time. It immediately surfaced two bugs — including one that meant the automatic path had never actually worked.

Bug 1 (blocker): the handoff was rejected as a bot

Action failed with error: Workflow initiated by non-human actor:
github-actions (type: Bot). Add bot to allowed_bots list or use '*' to allow all bots.

claude-code-action refuses non-human actors by default. The handoff added in #146 fires repository_dispatch using GITHUB_TOKEN, so every handed-off run is attributed to github-actions[bot] and died at the AI step.

This meant the automatic push path never worked end to end. Every run that ever reached the model — #145, #119, #126 — was a workflow_dispatch I triggered as a human, which is exactly why it looked healthy. The canary was the first bot-initiated run.

Fixed with allowed_bots: "github-actions" — deliberately naming the one bot rather than '*'.

Bug 2 (race): the push run cancelled its own handoff

Observed handoff: cancelled on the canary. The push run and the repository_dispatch it spawns shared a concurrency group with cancel-in-progress: true, so the child cancelled its parent mid-handoff.

It only worked because the dispatch API call had already returned. Had cancellation landed a moment earlier, the handoff would have been lost with no error — a silent, timing-dependent no-op, the worst kind of bug to chase later.

Push / PR / resolution runs now occupy separate concurrency namespaces (resolve-detect-*, resolve-pr*, resolve-base-*).

Validation

YAML parses; allowed_bots and the three-way concurrency expression verified in the parsed output. The canary (#148) is still conflicting and will be re-run against this branch to confirm the chain completes.

🤖 Generated with Claude Code

Found by a deliberate end-to-end canary (PR #148 against a throwaway base branch), which exercised push -> detect -> handoff -> repository_dispatch -> resolve for the first time.

BUG 1 (blocker): claude-code-action refuses non-human actors — "Workflow initiated by non-human actor: github-actions (type: Bot). Add bot to allowed_bots list". The handoff added in #146 fires repository_dispatch with GITHUB_TOKEN, so every handed-off run was attributed to github-actions[bot] and died at the AI step. This meant the automatic push path NEVER worked end to end; the only runs that ever reached the model were workflow_dispatch runs a human triggered, which is exactly why it looked healthy. Fixed with allowed_bots: github-actions (deliberately not '*').

BUG 2 (race): the push run and the repository_dispatch it spawns shared a concurrency group with cancel-in-progress, so the child cancelled its parent mid-handoff (observed: 'handoff: cancelled'). It only worked because the dispatch API call had already returned — had cancellation landed first, the handoff would have been lost silently. Push/PR/resolution runs now occupy separate concurrency namespaces.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Jul 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
thingtime Ready Ready Preview, Comment Jul 27, 2026 3:41am

Request Review

@lopugit
lopugit merged commit 2c10750 into main Jul 30, 2026
12 checks passed
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.

1 participant