Fix deploy-docs.yml push permission and drop unused target_repo input - #9369
Merged
Conversation
actions/create-github-app-token defaults to scoping the minted token to the *current* repo (halide/Halide) unless told otherwise, regardless of which other repos the GitHub App is installed on -- so despite the halide-ci app having write access to halide.github.com, the final push step was always denied with a 403. Pass owner/repositories explicitly so the token is scoped to halide.github.com instead. While here, drop the target_repo workflow_dispatch input: this workflow has only ever deployed to halide/halide.github.com and rehearsing against a personal fork wasn't a realistic use case, so hardcode it and simplify the env/step wiring accordingly. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
derek-gerstmann
approved these changes
Aug 19, 2026
derek-gerstmann
left a comment
Contributor
There was a problem hiding this comment.
I'm not fluent in github workflows, but the changes look reasonable to me!
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.
Summary
actions/create-github-app-tokenscopes the minted token to the current repo (halide/Halide) unless told otherwise -- regardless of which other repos the app is installed on. That meant the finalgit pushtohalide.github.comindeploy-docs.ymlwas always denied with a 403, even after granting thehalide-ciGitHub App write access tohalide/halide.github.com. Passingowner/repositoriesexplicitly scopes the token correctly.target_repoworkflow_dispatch input: this workflow has only ever deployed tohalide/halide.github.com, and rehearsing against a personal fork wasn't a realistic use case, so it's hardcoded now and the env/step wiring is simplified accordingly.Test plan
halide/halide.github.comto confirm the push actually succeeds this time (see run linked in PR checks / comments).pre-commit run --all-filespasses.🤖 Generated with Claude Code