ci: run release-please under a PAT so release PRs get CI - #9
Merged
Conversation
Workflows are not triggered by events a GITHUB_TOKEN causes, so the release PR the action opened got no CI run at all. With ci-green required by branch protection, that PR could never be merged: the required check never reported, and the PR sat BLOCKED with nothing failing to explain it. Cutting 1.0.2 needed the PR closed and reopened by hand, twice, to produce a run. Opening the PR under a PAT makes it come from a user, so CI runs on it like on any other PR. The token needs Contents and Pull requests, both read/write, on this repo only. Two things this costs, both documented rather than left to be rediscovered: the token expires, and releases stop being proposed until it is rotated; and going back to the GITHUB_TOKEN means deleting the `token:` line, not just the secret, since a default only applies to an omitted input. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Workflows are not triggered by events a
GITHUB_TOKENcauses, so the release PR the action opens gets no CI run at all. Withci-greenrequired by branch protection, such a PR can never be merged: the required check never reports, and the PR sitsBLOCKEDwith zero failing checks to explain it. Cutting1.0.2needed the PR closed and reopened by hand — twice — to produce a run.Opening the PR under a PAT makes it come from a user, so CI runs on it like on any other PR.
Token: fine-grained, this repo only,
Contents: read/write+Pull requests: read/write.What this costs, documented in
docs/OVERVIEW.mdrather than left to be rediscovered:GITHUB_TOKENmeans deleting thetoken:line, not just the secret — the action's default is${{ github.token }}, but a default only applies to an omitted input, and a deleted secret leaves the input present and empty;"Allow GitHub Actions to create and approve pull requests"stops being relevant here, since the PR no longer comes from Actions.🤖 Generated with Claude Code