Generate a migration path to ruff from anywhere.
Project description
that's
Answering what's necessary to migrate to ruff right now.
Motivation
Starting with ruff is simple. But enabling "ALL" rules in an
existing application? That’s a challenge.
This project helps identify the minimal set of rules to disable temporarily, ensuring the CI remains green while allowing maintainers to iteratively fix their codebase at their own pace.
Installation
pip install ruffly-all
or
cargo install ruffly-all
Usage
Find a project you'd like to use ruff in, we'll be using pylint as
an example[^1].
- Run it
cd pylint/
ruffly-all
- Get a minimal ignore list for currently failing linters on
stdout.
[tool.ruff]
lint.select = [ "ALL" ]
lint.ignore = [
"D203", # incompatible to D211
"D212", # incompatible to D213
"ERA", # https://docs.astral.sh/ruff/rules/#eradicate-era
"YTT", # https://docs.astral.sh/ruff/rules/#flake8-2020-ytt
"ANN", # https://docs.astral.sh/ruff/rules/#flake8-annotations-ann
"S", # https://docs.astral.sh/ruff/rules/#flake8-bandit-s
"BLE", # https://docs.astral.sh/ruff/rules/#flake8-blind-except-ble
"FBT", # https://docs.astral.sh/ruff/rules/#flake8-boolean-trap-fbt
"B", # https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
"A", # https://docs.astral.sh/ruff/rules/#flake8-builtins-a
"COM", # https://docs.astral.sh/ruff/rules/#flake8-commas-com
"C4", # https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
"DTZ", # https://docs.astral.sh/ruff/rules/#flake8-datetimez-dtz
"T10", # https://docs.astral.sh/ruff/rules/#flake8-debugger-t10
"EM", # https://docs.astral.sh/ruff/rules/#flake8-errmsg-em
"EXE", # https://docs.astral.sh/ruff/rules/#flake8-executable-exe
"FIX", # https://docs.astral.sh/ruff/rules/#flake8-fixme-fix
"ISC", # https://docs.astral.sh/ruff/rules/#flake8-implicit-str-concat-isc
"ICN", # https://docs.astral.sh/ruff/rules/#flake8-import-conventions-icn
"LOG", # https://docs.astral.sh/ruff/rules/#flake8-logging-log
"G", # https://docs.astral.sh/ruff/rules/#flake8-logging-format-g
"INP", # https://docs.astral.sh/ruff/rules/#flake8-no-pep420-inp
"PIE", # https://docs.astral.sh/ruff/rules/#flake8-pie-pie
"T20", # https://docs.astral.sh/ruff/rules/#flake8-print-t20
"PYI", # https://docs.astral.sh/ruff/rules/#flake8-pyi-pyi
"PT", # https://docs.astral.sh/ruff/rules/#flake8-pytest-style-pt
"Q", # https://docs.astral.sh/ruff/rules/#flake8-quotes-q
"RSE", # https://docs.astral.sh/ruff/rules/#flake8-raise-rse
"RET", # https://docs.astral.sh/ruff/rules/#flake8-return-ret
"SLF", # https://docs.astral.sh/ruff/rules/#flake8-self-slf
"SIM", # https://docs.astral.sh/ruff/rules/#flake8-simplify-sim
"TID", # https://docs.astral.sh/ruff/rules/#flake8-tidy-imports-tid
"TD", # https://docs.astral.sh/ruff/rules/#flake8-todos-td
"TC", # https://docs.astral.sh/ruff/rules/#flake8-type-checking-tc
"ARG", # https://docs.astral.sh/ruff/rules/#flake8-unused-arguments-arg
"PTH", # https://docs.astral.sh/ruff/rules/#flake8-use-pathlib-pth
"FLY", # https://docs.astral.sh/ruff/rules/#flynt-fly
"C90", # https://docs.astral.sh/ruff/rules/#mccabe-c90
"NPY", # https://docs.astral.sh/ruff/rules/#numpy-specific-rules-npy
"N", # https://docs.astral.sh/ruff/rules/#pep8-naming-n
"PERF", # https://docs.astral.sh/ruff/rules/#perflint-perf
"E", # https://docs.astral.sh/ruff/rules/#error-e
"W", # https://docs.astral.sh/ruff/rules/#warning-w
"D", # https://docs.astral.sh/ruff/rules/#pydocstyle-d
"F", # https://docs.astral.sh/ruff/rules/#pyflakes-f
"PGH", # https://docs.astral.sh/ruff/rules/#pygrep-hooks-pgh
"PLC", # https://docs.astral.sh/ruff/rules/#convention-plc
"PLE", # https://docs.astral.sh/ruff/rules/#error-ple
"PLR", # https://docs.astral.sh/ruff/rules/#refactor-plr
"PLW", # https://docs.astral.sh/ruff/rules/#warning-plw
"UP", # https://docs.astral.sh/ruff/rules/#pyupgrade-up
"FURB", # https://docs.astral.sh/ruff/rules/#refurb-furb
"RUF", # https://docs.astral.sh/ruff/rules/#ruff-specific-rules-ruf
"TRY", # https://docs.astral.sh/ruff/rules/#tryceratops-try
]
- Get a summary on
stderr
This project has 11734 problems, which can be postponed by the above ruleset.
That's ruffly-all to migrate to ruff right now.
- Decide whether to fix the failures immediately or to add the above ignores for the moment.
The latter prevents the project to worsen and can be resolved in small steps once there is time.
FAQ
All those codes - where do they come from?
ruff unifies a whole bunch of different static analysis tools (linters).
To group them into their different original linters, the ecosystem came up
with short abbreviations of them.
Each one of them can be found on https://docs.astral.sh/ruff/rules.
Why are there incompatible rules?
No matter how clean the inspected python project is, one cannot ever enable
ALL rules, due to conflicitng flavors of the very same rule.
The most prominent examples are D203 and D211, which enforce a blank line
before a class docstring or its absence respectively.
ruff warns about ignoring one of them and ruffly-all just transparently
conveys that choice.
You can swap them to your own liking though.
Same goes for D212 and D213 which disagree on whether a docstrings
content should start on the same line as itself, or the next.
[^1]: While this does look like the pylint project had a lot going on,
keep in mind extensive parts of the repo are faulty python snippets
necessary as test resources for pylints unittests.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ruffly_all-0.6.2.tar.gz.
File metadata
- Download URL: ruffly_all-0.6.2.tar.gz
- Upload date:
- Size: 69.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b835e0d633ceada4795b6241ddc4cb2814ba5b251bad0f3d2e819c7e0d9734d1
|
|
| MD5 |
6ccd05196c9d4eab3da28227bb55bcf8
|
|
| BLAKE2b-256 |
bb0f2b6ef6bb9fd8013cd59a61e42ba7c1fb33db0c688ee68922d918a57d5f11
|
File details
Details for the file ruffly_all-0.6.2-py3-none-win_amd64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-win_amd64.whl
- Upload date:
- Size: 205.8 kB
- Tags: Python 3, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
859dad57ad49d9df488493087a7de8af6a45b07e632a4a43ca2546d1d490ee8d
|
|
| MD5 |
cbd27f5d0a542fd4f1335c769bc5b8a2
|
|
| BLAKE2b-256 |
6c276c4ad23179e324f73aa214c01b33c231507a18d421e33a938c2db567a60b
|
File details
Details for the file ruffly_all-0.6.2-py3-none-win32.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-win32.whl
- Upload date:
- Size: 195.3 kB
- Tags: Python 3, Windows x86
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
13023bdab8c1dc1930979e4bab60a95ce4f6469f730240ae567c4ab12d6c6493
|
|
| MD5 |
cae23b5d8ec581d4e887e57767e17a68
|
|
| BLAKE2b-256 |
86c317d83d3132b0bc84393e421c57cc357e7ba88e752e10afed0936b3d6e4fd
|
File details
Details for the file ruffly_all-0.6.2-py3-none-musllinux_1_2_x86_64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-musllinux_1_2_x86_64.whl
- Upload date:
- Size: 385.3 kB
- Tags: Python 3, musllinux: musl 1.2+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3fdd5051ee178f18eada3ad463cecdcd0714f33866c86534db34fc3393d8a0c0
|
|
| MD5 |
801c3b92fb5e82c90ea3f2983509aa35
|
|
| BLAKE2b-256 |
379e5f3175e87ea476825a47bff38af67a5593ce264030ce52e5493f32d1eb04
|
File details
Details for the file ruffly_all-0.6.2-py3-none-musllinux_1_2_i686.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-musllinux_1_2_i686.whl
- Upload date:
- Size: 395.9 kB
- Tags: Python 3, musllinux: musl 1.2+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
47d2d125409e08120c6e87384a5eb1051a4bebbf403b72240dd33388d4100762
|
|
| MD5 |
72261b7e6e29369d1e018ca2b09653b4
|
|
| BLAKE2b-256 |
2429e50f0808f998a8dde6aefe007c189d42a2850c482218250588f4c2ebdad8
|
File details
Details for the file ruffly_all-0.6.2-py3-none-musllinux_1_2_armv7l.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-musllinux_1_2_armv7l.whl
- Upload date:
- Size: 364.8 kB
- Tags: Python 3, musllinux: musl 1.2+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0b28cff52d533a01ada23dc14981021014816e443264828744c32ad3e57cb11f
|
|
| MD5 |
6b86cacffb25031d5a382f1e5290e0f7
|
|
| BLAKE2b-256 |
817a21c7166ba2c08cf802a6cbce311f736f0e7f2248373a17fbd246fe7c5619
|
File details
Details for the file ruffly_all-0.6.2-py3-none-musllinux_1_2_aarch64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-musllinux_1_2_aarch64.whl
- Upload date:
- Size: 373.2 kB
- Tags: Python 3, musllinux: musl 1.2+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
180b125128bffea3cb47ebd9cddda8e5e17623fda48533bdd8d67f7dd969fcea
|
|
| MD5 |
55dc7990d8dea1371a07465b77b9dedd
|
|
| BLAKE2b-256 |
2aae17594ad4bb4d0f1e3b374d9c62b91b59b6bd4862ab82df424100abf9ee45
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 328.1 kB
- Tags: Python 3, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7ef2ea12e8583c00d36d1778ac2b08149bf48c9c2202d16e69ba0b5ad8788ad1
|
|
| MD5 |
5e45611e73c043aa70bd3896f009b482
|
|
| BLAKE2b-256 |
af46b7aea72f0947cbcab2743a44193ce2dca0fd1e5ee5f4efcf94e4f82a34a4
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
- Upload date:
- Size: 360.6 kB
- Tags: Python 3, manylinux: glibc 2.17+ s390x
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
51bacbd4bb8611bf6c76637e2742f9c228e36a85afe25ad8ae03f945ec5933a3
|
|
| MD5 |
e28e90681e6280e2659d62e21850e7a1
|
|
| BLAKE2b-256 |
9e819bb636ff9eca88bae12ddd2c2985a42512f491b157fe7bfb48a6eda7594d
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
- Upload date:
- Size: 422.1 kB
- Tags: Python 3, manylinux: glibc 2.17+ ppc64le
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
451f9f07f4eae70ab7ac81ef24ebdd063febb56a84627b033670ebd10102c02d
|
|
| MD5 |
601a67936ab9444cf1113ac392430c12
|
|
| BLAKE2b-256 |
1357cd6023e9317d0ccb1f1705aac98e5c3ecc187d37692d36e7903b57b1d7aa
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
- Upload date:
- Size: 342.2 kB
- Tags: Python 3, manylinux: glibc 2.17+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52d3c34f597f03a618e8873a8b6c0983254ef7f48be00c2c4a86cf46bdfec70f
|
|
| MD5 |
83a8d29f7e4fdbab7f1e16c897e421f4
|
|
| BLAKE2b-256 |
7b4e289cb400eaeacfc1d94b12a16015e8ccdfc31dfee0a1a9cdd16998990726
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 327.3 kB
- Tags: Python 3, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
91e7458fdaa91abdd88aa3d58e7df3ac854a0d04b9da82b88416fd6e3828314d
|
|
| MD5 |
5005a9a9d86aee2bd63a432506ec096c
|
|
| BLAKE2b-256 |
f8048f2323104d7b427d1f16d29b714b9423ca8dcada2a886e99f7ed5232b0ad
|
File details
Details for the file ruffly_all-0.6.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 316.1 kB
- Tags: Python 3, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aaf3d51ca630f1f9d16aa8c8af625733644147e4dd5813e7890fe35c4706c5d3
|
|
| MD5 |
cef68a20d0a56761270770d85b71c764
|
|
| BLAKE2b-256 |
014a2bb2024b57c213a25f6c988355d59c9aad1239f3bc168c509483dc891bcf
|
File details
Details for the file ruffly_all-0.6.2-py3-none-macosx_11_0_arm64.whl.
File metadata
- Download URL: ruffly_all-0.6.2-py3-none-macosx_11_0_arm64.whl
- Upload date:
- Size: 294.3 kB
- Tags: Python 3, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9c932eba0f129aef73c62e050ddc9bdeff4f6e7174d353de1a950c4e1f82bab3
|
|
| MD5 |
49c54cf692ca8cbc7495576f3d131fed
|
|
| BLAKE2b-256 |
e72de03a069cd48f606e20e27ad4e914ee264a35379c5d36f54aedd4e59b66b1
|