Skip to content

Streamline Dependabot pull requests - #347

Merged
camUrban merged 6 commits into
mainfrom
dependabot_config
Nov 5, 2026
Merged

camUrban merged 6 commits into
mainfrom
dependabot_config

Conversation

@camUrban

@camUrban camUrban commented Nov 5, 2026 •

Copy link
Copy Markdown
Owner

Description

This PR reduces the manual upkeep that Dependabot pull requests need. The GitHub Actions and pre-commit version updates now share one monthly multi-ecosystem group, so routine CI tooling bumps arrive as a single pull request each month instead of two weekly ones. A new dependabot-triage.yml workflow runs on every Dependabot pull request, replacing its title with a short fixed one and adding it to the lowest open release milestone. A new pip entry in dependabot.yml controls the labels and assignee on pip security update pull requests without opening any routine version updates for the requirements files. Separate from this PR, I also made the new dependabot-triage.yml workflow a required status check in the main ruleset.

Neither workflow step can run before this merges, because the workflow only runs from main once Dependabot opens a pull request. The first grouped pull request after merging is therefore its first real test. This PR deliberately leaves out automatic rebasing of pull requests that fall behind main and an approval requirement for Dependabot pull requests only. Dependabot ignores @dependabot rebase comments posted with the workflow token, and rulesets cannot scope an approval requirement or merge method to a pull request's author, so both stay manual.

Motivation

Every Dependabot pull request has needed the same set of manual steps: assigning it, setting its milestone, removing stray labels such as python that Dependabot creates on security updates, and editing the squash-merge subject so it stays within the 50-character commit subject limit. Dependabot's own titles, such as "Bump the actions group with 3 updates", leave little room once the squash merge appends the pull request number. Weekly updates for two ecosystems also produced a steady stream of small pull requests for tooling that never affects the package's runtime. Security updates do not follow the version update schedule, so the slower cadence does not delay vulnerability fixes.

Relevant Issues

None.

Changes

  • Replaced the separate weekly schedule and single-ecosystem groups of the github-actions and pre-commit entries in dependabot.yml with one ci-tooling multi-ecosystem group on a monthly interval, keeping the 7-day cooldown on each entry.
  • Added assignees on the ci-tooling group so grouped pull requests arrive assigned to the maintainer. Review requests already come from CODEOWNERS.
  • Added a pip entry with open-pull-requests-limit: 0, labels: [dependencies], and assignees. The zero limit disables pip version updates, while the labels and assignee still apply to pip security update pull requests, which replaces Dependabot's default python label.
  • Added .github/workflows/dependabot-triage.yml, which runs on opened, reopened, and synchronize events for pull requests authored by dependabot[bot], with permissions: {} at the top level and issues: write and pull-requests: write on its single job.
  • Its title step sets "Bump CI tooling" when every changed file is under .github/ or is .pre-commit-config.yaml. Otherwise it sets "Bump runtime dependency" or "Bump runtime dependencies", chosen by counting the - dependency-name: entries in Dependabot's own commit messages, which keeps the count correct after the title has already been replaced.
  • Its milestone step picks the lowest open milestone titled vX.Y.Z, sorting the version numbers numerically so that v5.9.0 sorts before v5.10.0. It skips pull requests that already have a milestone, so a milestone set by hand is never overwritten.
  • Added dependabot-triage.yml to the list of workflows in CLAUDE.md.

Dependency Updates

None.

Change Magnitude

Minor: Small change such as a bug fix, small enhancement, or documentation update.

Checklist (check each item when completed or not applicable)

  • I am familiar with the current contribution guidelines.
  • PR description links all relevant issues and follows this template.
  • My branch is based on main and is up to date with the upstream main branch.
  • All calculations use S.I. units.
  • Code is formatted with black (line length = 88).
  • Code is well documented with block comments where appropriate.
  • Any external code, algorithms, or equations used have been cited in comments or docstrings.
  • All new modules, classes, functions, and methods have docstrings in reStructuredText format, and are formatted using docformatter (--in-place --black). See the style guide for type hints and docstrings for more details.
  • All new classes, functions, and methods in the pterasoftware package use type hints. See the style guide for type hints and docstrings for more details.
  • If any major functionality was added or significantly changed, I have added or updated tests in the tests package.
  • Code locally passes all tests in the tests package.
  • This PR passes the ReadTheDocs build check (this runs automatically with the other workflows).
  • This PR passes the ascii-only, pre-commit-hooks, and zizmor GitHub actions.
  • This PR passes the lint job of the CI GitHub action.
  • This PR passes the test jobs of the CI GitHub action.

Assisted-by: Claude Opus 5.5

camUrban and others added 5 commits November 5, 2026 10:29
Combine the GitHub Actions and pre-commit updates into a single
multi-ecosystem group so that routine CI tooling bumps arrive as one
pull request instead of two. Move the schedule from weekly to monthly
to cut review overhead, since neither ecosystem affects the package's
runtime dependencies and security updates are not tied to this schedule.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Automate the assignment step, which has been manual on each pull
request even though CODEOWNERS already requests the review. Set it in
the group configuration so that every grouped update arrives assigned
and shows up in the assigned pull request list.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Keep squash-merge commit subjects, which append the PR number to the PR
title, within the 50-character limit. Rename each Dependabot pull
request from a workflow, since Dependabot offers no option for a fixed
title. Base the title on the changed files so that runtime dependency
bumps from security updates stay distinct from CI tooling bumps in the
history, and pick the singular or plural form from the dependency list
in Dependabot's commit message, which survives the rename on later
runs. List the new workflow in CLAUDE.md alongside the others.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Stop Dependabot from creating and applying its default python label on
security update pull requests, since that label is not in labels.yml
and has to be removed by hand each time. Assign those pull requests to
the maintainer as well, matching the grouped CI tooling updates. Set
the open pull request limit to zero so that the new pip entry carries
these settings for security updates without also opening routine
version bumps to the requirements files.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Replace the manual step of adding each Dependabot pull request to the
next release milestone. Pick the lowest open milestone titled with a
semantic version rather than using Dependabot's own milestone option,
which accepts only a fixed milestone number and would need editing
after every release. Skip pull requests that already have a milestone
so that later pushes from Dependabot never override one set by hand.
Rename the workflow to reflect its broader role, and update its entry
in CLAUDE.md to match.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@camUrban camUrban added maintenance Improvements or additions to documentation, testing, robustness, or tooling github_actions Updates to GitHub Actions code labels Nov 5, 2026
@camUrban camUrban self-assigned this Nov 5, 2026
@camUrban camUrban added this to the v5.2.0 milestone Nov 5, 2026
@camUrban
camUrban requested a balanced review from Copilot November 5, 2026 17:06

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The workflow’s read-only Dependabot token prevents PR updates, and its stale event-payload milestone check can overwrite a maintainer’s manual assignment.

2 open issues
What changed in this PR

This PR reduces manual Dependabot upkeep by consolidating CI tooling updates and automating pull request metadata.

Changes:

  • Groups GitHub Actions and pre-commit updates into one monthly pull request, retaining seven-day cooldowns.
  • Configures labels and assignment for pip security updates while disabling routine pip version updates.
  • Adds a workflow to shorten Dependabot pull request titles and assign the lowest open release milestone.
File Description
CLAUDE.md Adds the triage workflow to the documented workflow list.
.github/​workflows/​dependabot-triage.yml Automates Dependabot pull request titles and milestone assignment.
.github/​dependabot.yml Consolidates tooling updates and configures pip security update metadata.

Review effort: Balanced

Comment thread .github/workflows/dependabot-triage.yml Resolved
Comment thread .github/workflows/dependabot-triage.yml Resolved
@codecov

codecov Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.72%. Comparing base (b555f4d) to head (3b74739).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #347   +/-   ##
=======================================
  Coverage   96.72%   96.72%           
=======================================
  Files          75       75           
  Lines       10933    10933           
=======================================
  Hits        10575    10575           
  Misses        358      358           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Add check for existing milestone before setting a new one.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@camUrban
camUrban merged commit 1ff9b0a into main Nov 5, 2026
39 checks passed
@camUrban
camUrban deleted the dependabot_config branch November 5, 2026 17:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Updates to GitHub Actions code maintenance Improvements or additions to documentation, testing, robustness, or tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants