-
-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Open
Labels
Description
Motivation.
We would like to transition vLLM from yapf
to ruff format
. This will give us:
- Increased line length
- Better formatting style which is more effectively enforced by tooling rather than by maintainers
- Fewer formatting tools fighting eachother
Proposed Change.
We plan to make this change gradually using the following process.
If we are converting directory x
:
- In
x
, we add a localpyproject.toml
which:- overrides
ruff
's line length to 88 (it's own default) - removes the deprecated type ignores
- enables
isort
in ruff - enables formatting of code in docstrings (good for the API docs)
- overrides
- We add
x
to the list of files to runruff-format
on in.pre-commit-config.yaml
- We add
x
to the list of ignores in theyapf
andisort
config in the rootpyproject.toml
Here is the list of PRs used to make the transition:
DarkLight1337, yihong0618, princepride, aarnphm, ProExpertProg and 3 more