Repository navigation
[pre-commit.ci] pre-commit autoupdate - #549
Merged
Merged
Conversation
updates: - [github.com/tox-dev/pyproject-fmt: v2.29.3 → v2.29.4](tox-dev/pyproject-fmt@v2.29.3...v2.29.4) - [github.com/astral-sh/ruff-pre-commit: v0.16.6 → v0.16.7](astral-sh/ruff-pre-commit@v0.16.6...v0.16.7) - [github.com/zizmorcore/zizmor-pre-commit: v1.30.0 → v1.30.1](zizmorcore/zizmor-pre-commit@v1.30.0...v1.30.1)
pre-commit-ci
Bot
requested review from
gaborbernat and
ofek
as code owners
September 14, 2026 16:59
gaborbernat
added a commit
that referenced
this pull request
Sep 18, 2026
Every release commit leaves `docs/changelog.rst` in a shape `docstrfmt` disagrees with: towncrier's header overline is one character short of what `docstrfmt -l 120` wants, and its line wrapping doesn't match either. Nothing runs `docstrfmt` before that commit lands on `main`, so the reformat shows up later as an unrelated diff in whichever PR pre-commit.ci next touches. #549 and #550 each carry exactly that reformat, with nothing to do with their actual change. The fix runs the `docstrfmt` pre-commit hook against the generated changelog in `prepare-release.yaml`, right after `towncrier build` and before the release commit, so the formatting is already correct when it lands. `pre-commit` reports a hook that rewrites a file as a failure, so the step is allowed to fail without breaking the job. Verified locally: replaying `towncrier build` plus this `docstrfmt` step against the pre-#549 changelog produces output identical to what pre-commit.ci fixed up afterward, and a dry-run release from current `main` needs no follow-up reformat. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
gaborbernat
added a commit
to gaborbernat/platformdirs
that referenced
this pull request
Sep 18, 2026
towncrier's header overline and line wrapping don't match docstrfmt's 120-column style, so every release commit left docs/changelog.rst in a shape docstrfmt wanted to rewrite. Nothing ran docstrfmt before that commit landed on main, so pre-commit.ci reformatted it on whichever PR happened to touch the repo next, carrying an unrelated diff into that PR's changes (tox-dev#549, tox-dev#550). Running the docstrfmt hook on the generated changelog right after towncrier build, before the release commit, fixes the formatting at the source instead of downstream.
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.
updates: