Open 0ut0fcontrol opened 3 weeks ago
I lean towards ruff due to its speed and high number of supported rules than can be configured (even the black format). Furthermore, it can be used both as formatter and linter.
For legacy reasons the project currently does not enforce a formatter at all. However, in my opinion it would make sense to introduce a formatter rather sooner than later. We would need to agree on the following points:
I had good experiences with ruff
. And I'd personally go with one full reformat of the code-base once, and requiring any new commits to be formatted correctly. A starting point could be to first only use ruff format (which will likely lead to the most changes) and add the ruff linting later
ruff format . # only changes the formatting, no linting
ruff check --fix . # this lints & fixes, we could start adding that in later, depending on how many lint issues we find (fix tries to autofix many)
black? or yapf?
If not specified, I recommend black.