Repository navigation
fix: CI runs on release PRs without a close and reopen - #23
Merged
Merged
Conversation
AlexeyShalaev
force-pushed
the
fix/12-release-pr-ci
branch
from
October 16, 2026 15:01
e7af9cd to
760cdc8
Compare
Release Please opened and updated its PR with GITHUB_TOKEN. GitHub holds the pull_request run such an event creates until it expires, so the required All checks passed never reported, and every release needed someone to close and reopen the PR after its last update. The workflow now mints a token from an org-owned GitHub App (actions/create-github-app-token, scoped to contents and pull-requests write, the same permissions the job's GITHUB_TOKEN has) and hands it to Release Please, so its PR events start CI like anyone else's. The App is configured once per org: RELEASE_PLEASE_APP_CLIENT_ID as a variable, RELEASE_PLEASE_APP_PRIVATE_KEY as a secret. Until then the workflow falls back to GITHUB_TOKEN and warns, so a new library still releases the way it does today. setup_repo.py warns when a repository cannot see the two names. Closes #12
AlexeyShalaev
force-pushed
the
fix/12-release-pr-ci
branch
from
October 16, 2026 15:05
760cdc8 to
4c6f62b
Compare
This was referenced Oct 17, 2026
Merged
Merged
AlexeyShalaev
added a commit
to bedrock-python/touchmark
that referenced
this pull request
Oct 18, 2026
With GITHUB_TOKEN the release PR's CI run is held and never starts, so it needed a close and reopen before every merge. The token now comes from the org's release App (bedrock-python/python-library-template#23), with GITHUB_TOKEN and a warning as the fallback while the App's variable is unset.
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.
The problem
release-please.ymlranrelease-please-action@v5withouttoken:, so the release PR was opened and updated withGITHUB_TOKEN. GitHub creates thepull_requestCI run for those events but holds it until it expires, so the requiredAll checks passednever reports. Every release has needed someone to close and reopen the PR after its last update (idempotency-kit #38, clientwright #40/#43, deadline-budget #23). One held run in deadline-budget waited 30 days.The decision
Release Please gets an installation token of an org-owned GitHub App, minted per run with
actions/create-github-app-token@v3. Events from that token start CI the same way a person's would.contents: writeandpull-requests: write, which are the permissions the job'sGITHUB_TOKENhas today and releases with today. My plan comment also listedissues: write, but the current releases show it isn't needed, so I left it out.RELEASE_PLEASE_APP_CLIENT_ID, org secretRELEASE_PLEASE_APP_PRIVATE_KEY. A variable rather than a secret for the client ID, because a client ID isn't secret and a variable can be tested inif:.GITHUB_TOKENand the run carries a::warning::that says what that means. A library created before the App exists still releases the way it does today and does not fail. If the variable is set and the key is wrong or missing, the token step fails loudly. It does not fall back.setup_repo.pywarns when a repository cannot see the variable or the secret, at org or repository level.Rejected:
What I could and could not test
release-please(Google's hosted one, no key we hold),codecov,claude, and the twobedrock-python-assets-*apps). The first release PR after setup is the real check: its CI run should be started by the App's bot and get jobs.actionlint1.7.12 is clean, except for two findings that come from its bundled action metadata, which predatesclient-id.actions/create-github-app-token'saction.ymlatv3(= v3.3.0,64ab729) declaresclient-idand marksapp-idas deprecated ("Use 'client-id' instead"), so I usedclient-idand ignored those two findings.setup_repo.pywith a fakegh:The four listing endpoints it reads (
actions/{organization-,}{variables,secrets}) answer with thereposcope; I checked them read-only against this repository.What the maintainer has to set up
Once per org, as described in the README section: create the App (Contents and Pull requests read/write, no webhook), install it on all repositories, add variable
RELEASE_PLEASE_APP_CLIENT_IDand secretRELEASE_PLEASE_APP_PRIVATE_KEY, both visible to all repositories.Closes #12