fix(github): pin renovate to platform-independent automerge - #946
Merged
Conversation
Setting allow_auto_merge to true switches Renovate from its direct merge API to GitHub native auto-merge reservation, which does not evaluate branch protection bypass_pull_request_allowances. That blocks Renovate PRs forever once required reviews apply, breaking previously working automerge. Pinning platformAutomerge to false keeps Renovate on its own bypass-capable merge API regardless of the allow_auto_merge repository setting.
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.
背景
このリポジトリはブランチ保護(
dev)でrequired_approving_review_count: 1が設定されているが、bypass_pull_request_allowancesに Renovate app が登録されており、従来 Renovate は自身の direct マージ API を使ってレビュー要件をバイパスし自動マージできていた。今回、リポジトリ設定
allow_auto_mergeをfalseからtrueに変更した。他リポジトリ(kamado, linters)で検証した結果、allow_auto_merge: trueにすると Renovate の挙動が「GitHub native auto-merge 予約」方式に切り替わり、これはブランチ保護のbypass_pull_request_allowancesを評価しないため、レビュー必須要件を満たせず CI 成功済み PR が永久にブロックされる問題が確認されている。このリポジトリは元々allow_auto_merge: falseの direct マージ方式でうまく機能していたため、同じ退行が起きるリスクが高い。対応内容
.github/renovate.jsonのトップレベルにplatformAutomerge: falseを追加した。これによりallow_auto_mergeの値に関わらず、Renovate は常に自前の direct マージ API(bypass が効く方式)を使うようになる。影響範囲
.github/renovate.jsonの1行追加のみpackageRules内の automerge 設定(minor/patch 等の自動マージ対象範囲)には変更なし確認事項
node -e "JSON.parse(...)")yarn lintパスyarn buildパスyarn testパス(142 files / 1884 tests)