Repository navigation
ci(dependabot): put major updates in their own PR, so only minor and patch get auto-merged - #269
Merged
Merged
Conversation
…patch updates get auto-merged Assisted-by: Claude Code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175Q8iDhm66k14xJCbRnxV7
Contributor
|
connabyss
enabled auto-merge (squash)
November 27, 2026 08:46
4 tasks done
connabyss
added a commit
that referenced
this pull request
Nov 27, 2026
#271) **What was wrong, what you changed, how you checked:** Dependabot's minor/patch PRs were meant to auto-merge (see #269), and the repo setting "Allow auto-merge" is on, but that setting only *permits* auto-merge: something still has to switch it on for each PR. Nothing did, so #270 sat open with every check green until it was merged by hand. This adds `.github/workflows/dependabot-auto-merge.yml`. On Dependabot PRs it runs `gh pr merge --auto --squash`, but only for the minor/patch group branches (`dependabot/github_actions/actions-<hash>`, `dependabot/pip/python-<hash>`). The `-major` groups and any ungrouped update (e.g. a security fix) are left for review. The "protect main" ruleset's required checks still have to pass before anything merges. It uses no actions and never checks out the PR's code. One side effect: a merge made with the workflow token doesn't trigger push workflows on main (e.g. release-drafter) for that commit. The next normal merge catches up. Fixes n/a (follow-up to #269 / #270) - [x] The title says what changed, in the Conventional Commit style. - [x] It links the issue it fixes: n/a, follow-up to #269 and #270. - [x] For a bug fix: `tests/test_dependabot_auto_merge.py` fails without the workflow (file missing) and passes with it (4 tests: minor/patch groups match, major groups and single updates don't, group names match dependabot.yml). - [x] `python -m pytest` passes locally (467 passed, 1 skipped). Assisted-by: Claude Code --- _Generated by [Claude Code](https://claude.ai/code)_ Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Requested by CH · project thread
What this changes
.github/dependabot.ymlonly. Each group (actions,python) now takes minor and patch updates only. Major updates go to a separateactions-major/python-majorgroup, so they arrive as their own PR that you review by hand instead of auto-merging. Security updates are unchanged.How it was checked
[['actions', 'actions-major'], ['python', 'python-major']].python -m pytestisn't affected. CI runs it anyway.Checklist
pyproject.tomlAssisted-by: Claude Code
Lesson (3 lines)
groupswithupdate-typessort updates into the right pile for you.Generated by Claude Code