fix(mergify): exempt release-plz PRs from CI merge protection#121
Conversation
|
Caution Review failedFailed to post review comments Summary by CodeRabbit
WalkthroughThis PR modifies the Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Merge ProtectionsYour pull request matches the following merge protections and will not be merged until they are valid. 🔴 Enforce conventional commitThis rule is failing.Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/
🟢 📃 Configuration Change RequirementsWonderful, this rule succeeded.Mergify configuration change
🟢 CI must passWonderful, this rule succeeded.All CI checks must pass. This protection prevents manual merges that bypass the merge queue.
🟢 Do not merge outdated PRsWonderful, this rule succeeded.Make sure PRs are within 10 commits of the base branch before merging
|
🧪 CI InsightsHere's what we observed from your CI run for 67319c8. 🟢 All jobs passed!But CI Insights is watching 👀 |
There was a problem hiding this comment.
Pull request overview
Updates Mergify merge protections to avoid release-plz PRs getting stuck due to GITHUB_TOKEN force-push behavior suppressing CI workflow runs, while still relying on the merge queue as the final CI gate.
Changes:
- Exempt
release-plz-*PR branches from the “CI must pass” merge protection. - Expand the merge protection description to document the rationale for the exemption.
| on main), and GITHUB_TOKEN-triggered force-pushes suppress CI. | ||
| if: | ||
| - base = main | ||
| - "-head ~= ^release-plz-" |
There was a problem hiding this comment.
The CI-merge-protection exemption is based solely on the branch name (head ~= ^release-plz-). That makes it easy to unintentionally (or intentionally) bypass the “CI must pass” protection by naming a branch release-plz-*, even if the PR did not come from the release-plz automation. Consider tightening the exemption to also match the PR author (the bot account used by the release-plz workflow) and/or require a bot-applied label so only genuine release-plz PRs are exempt.
| - "-head ~= ^release-plz-" | |
| - or: | |
| - "-head ~= ^release-plz-" | |
| - "-author = release-plz[bot]" |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Update documentation for #121 _Generated by [Dosu](https://dosu.dev)_ Co-authored-by: dosubot[bot] <131922026+dosubot[bot]@users.noreply.github.com> Co-authored-by: UncleSp1d3r <unclesp1d3r@evilbitlabs.io>
Release-plz force-pushes when updating existing PRs, and GITHUB_TOKEN-triggered pushes suppress workflow events, so CI never runs on the new HEAD. Since release-plz PRs only bump versions and changelogs (code was already tested on main), exempting them from the CI merge protection avoids the hang. CI still runs in the merge queue as a final safety net. Signed-off-by: UncleSp1d3r <unclesp1d3r@evilbitlabs.io>
…egex The regex used \\\\( in YAML which after parsing becomes \\( in the regex engine, matching a literal backslash before the parenthesis. This caused scoped titles like "fix(mergify): ..." to fail validation. Change to \\( so YAML produces \( which matches a literal parenthesis. Signed-off-by: UncleSp1d3r <unclesp1d3r@evilbitlabs.io>
2eda662 to
67319c8
Compare
## 🤖 New release * `libmagic-rs`: 0.2.0 -> 0.2.1 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.2.1] - 2026-03-02 ### Bug Fixes - **mergify**: Exempt release-plz PRs from CI merge protection ([#121](#121)) ### Documentation - **readme**: Use reference-style links for badges ([#128](#128)) ### Miscellaneous Tasks - **Mergify**: Configuration update ([#124](#124)) - **Mergify**: Configuration update ([#126](#126)) - **mergify**: Streamline auto-approval and merging rules for bots <!-- generated by git-cliff --> </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary
head ~= ^release-plz-) from the "CI must pass" merge protectionGITHUB_TOKEN-triggered pushes suppress workflow events, so CI never runs on the new HEAD — causing the merge protection to hang indefinitely (see PR chore: release v0.2.0 #111)Test plan
🤖 Generated with Claude Code