Skip to content

ci: gate Dependabot auto-merge on github.actor, not PR author - #616

Merged
nolik merged 1 commit into
mainfrom
ci/fix-dependabot-actor-gate
Jul 25, 2026
Merged

ci: gate Dependabot auto-merge on github.actor, not PR author#616
nolik merged 1 commit into
mainfrom
ci/fix-dependabot-actor-gate

Conversation

@nolik

@nolik nolik commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Fixes the "PR is not from Dependabot, nothing to do" error seen on #611.

Cause: the job was gated on github.event.pull_request.user.login == 'dependabot[bot]' (the PR author), so it ran even when a human triggered the event — e.g. clicking "Update branch" (run showed triggering_actor: nolik). dependabot/fetch-metadata then checks github.actor (the human), can't confirm Dependabot, and exits 1.

Fix: gate the job on github.actor == 'dependabot[bot]' — the event's triggering actor, which is what fetch-metadata requires and GitHub's docs recommend. Now:

  • Dependabot opens or rebases a PR → github.actor is Dependabot → job runs (approve + auto-merge).
  • A human interacts with a Dependabot PR → job skips cleanly (no error). Auto-merge/approval already persist, so nothing is lost.

🤖 Generated with Claude Code

Fixes "PR is not from Dependabot, nothing to do" from
dependabot/fetch-metadata. The job gated on the PR author (always
dependabot), so it ran even when a human triggered the event (e.g. clicked
"Update branch"); fetch-metadata then checks github.actor, sees the human,
and aborts with exit 1. Gating the whole job on
`github.actor == 'dependabot[bot]'` (GitHub's documented pattern) means
human-triggered events skip cleanly instead of failing.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@nolik
nolik merged commit b64b8fb into main Jul 25, 2026
8 checks passed
@nolik
nolik deleted the ci/fix-dependabot-actor-gate branch July 25, 2026 18:05
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