Repository navigation
Commit 619d2c9
build: pin ruff's rule selection so the lint gate measures the change
CI installs ruff unpinned, so with no config block ruff applied whatever its
current default rule set happens to be. That set has widened considerably
since this gate was written, and ruff 0.16.4 reports 59 errors on an
unmodified origin/main (361df8d) -- I001, UP024, SIM*, BLE001, DTZ003, S110,
RUF*, FURB*. The gate was red on main itself, so any PR inherited a wall of
findings it did not cause.
Pin select = ["E4", "E7", "E9", "F"], which is ruff's own pre-widening
default and the rule set this codebase was written against. Verified with
ruff 0.16.4 against a detached worktree of origin/main: 0 errors across
src/ and tests/, both via --config and with the block grafted into main's
own pyproject.toml. `ruff check src/ tests/` is now green on main's code
and on this branch, so the gate reports only what a PR actually changes.
Rules that fire on unmodified main are deliberately left out rather than
silenced file-by-file: I (22), UP (16), B (5), C4 (1). Enabling any of them
is a real cleanup that belongs in its own commit, not smuggled into a
hardening branch. E501 is excluded because black owns line length and the
two cannot both be green here -- see the comment in pyproject.toml.
Uses [tool.ruff.lint] rather than a top-level select; ruff 0.16.4 warns that
the top-level linter settings are deprecated, and that warning would be the
same drift problem returning by another route.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent 2a54a09 commit 619d2c9
1 file changed
Lines changed: 28 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
30 | 58 | | |
31 | 59 | | |
32 | 60 | | |
| |||
0 commit comments