Repository navigation
Pin ruff's rule selection and bump the pre-commit hook to 0.17.2 - #964
Merged
Merged
Conversation
Ruff 0.16 enlarged its default rule set, so ruff 0.17.2 from uv.lock reported 454 findings on master while the pre-commit hook (v0.14.10) reported none. Select the previous defaults (E4, E7, E9, F) explicitly so every ruff version checks the same rules, and run the same ruff in pre-commit as in uv.lock.
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.
Ruff 0.16 enlarged its default rule set. The project never set
select, soruff checkwith the ruff inuv.lock(0.17.2) reports 454 findings onmaster(UP006, BLE001, I001, DTZ001, ...), while the pre-commit hook, pinned at v0.14.10, reports none.[tool.ruff.lint]now selects the previous defaults (E4,E7,E9,F) explicitly, so every ruff version checks the same rules.uv.lock.No code changes: with these settings ruff 0.17.2 reports no findings and
ruff format --checkis clean.pre-commit run --all-filespasses.Adopting any of the new rules (for example the autofixable UP006/I001) would be a separate PR.
Changelog
None (development tooling only).