Repository navigation
fix: request auto-merge on pull_request instead of pull_request_target - #7
Merged
Merged
Conversation
GitHub blocks pull_request_target in public repositories by default from 2 December 2026, which stops this required workflow from starting and keeps pull requests out of the merge queue. The job checks out no pull request code and already skips forks, and same-repository pull_request runs receive the secrets it needs, so pull_request is enough.
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.
GitHub's default Actions policy blocks
pull_request_targetin public repositories, enforced from 2 December 2026 (https://gh.io/securely-using-pull_request_target#default-policy-for-pull_request_target). A scheduled brownout already stopped this required workflow from starting on 16 November, so pull requests could not enter the merge queue.This switches the trigger to
pull_request:gh pr merge --auto.head.repo.full_name == github.repository). Same-repositorypull_requestruns receive repository and organization secrets, so the delivery token still works. Fork pull requests get no secrets underpull_request, and the job skips them anyway.refs/heads/main, so the merged version applies to every repository without ruleset changes.merge_grouphandling is unchanged.Known difference: Dependabot pull requests receive only Dependabot secrets under
pull_request, so this job would not get the delivery key for them.Verification: this can only be exercised by a real pull request once merged. The first pull request in a public repository after merging should show Request Auto-Merge running on
pull_requestand auto-merge being enabled.