Skip to content

A few ruff / pre-commit details#397

Merged
astanin merged 3 commits into
astanin:masterfrom
DimitriPapadopoulos:ruff
Mar 5, 2026
Merged

A few ruff / pre-commit details#397
astanin merged 3 commits into
astanin:masterfrom
DimitriPapadopoulos:ruff

Conversation

@DimitriPapadopoulos

@DimitriPapadopoulos DimitriPapadopoulos commented Mar 4, 2026

Copy link
Copy Markdown
Contributor
  • The proper hook for the linter is ruff-check nowadays.
    Avoids:
    ruff (legacy alias)......................................................Passed
    
    and instead prints:
    ruff check...............................................................Passed
    
  • Use extend-select and let the linter choose its default rule sets — compatible with formatters.
  • No need to specify the directory to check, ruff operates on . by default.
  • The debug-statements hook can be replaced by Ruff debugger (T100) rules if needed.

@DimitriPapadopoulos DimitriPapadopoulos force-pushed the ruff branch 2 times, most recently from 7da0fc3 to ae6be02 Compare March 4, 2026 23:03
@DimitriPapadopoulos DimitriPapadopoulos changed the title A few ruff details A few ruff / pre-commit details Mar 4, 2026
- The proper hook for the linter is `ruff-check` nowadays.
- Use `extend-select` and let the linter choose its default rule sets - compatible with formatters.
- No need to specify the directory to check, ruff operates on `.` by default.
- The `debug-statements` hook can be replaced by Ruff debugger (T100) rules if needed.
- Add the `end-of-file-fixer` hook.
Unused blanket `noqa` directive
Lambda may be unnecessary; consider inlining inner function
@astanin astanin merged commit 8f32086 into astanin:master Mar 5, 2026
19 checks passed
@astanin

astanin commented Mar 5, 2026

Copy link
Copy Markdown
Owner

Thank you.

@DimitriPapadopoulos DimitriPapadopoulos deleted the ruff branch March 5, 2026 08:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants