DEV Community

Preslav Rachev
Preslav Rachev

Posted on

What (if any) is your preferred auto-formatter for Python?

This is more of a discussion poll than an actual post. I am writing a blog post about auto-formatting options for Python, and wanted to source a little bit of intel from the community itself.

I'd really love to know which one is your favorite and why. If you don't want to bother writing at length, I have a created a Twitter poll, where you can simply choose your fave.

Thanks!

Top comments (2)

Collapse
 
remorses profile image
Tommaso De Rossi

Black, it is the most readable and most importantly i can write “blacked” in the the commit messages

Collapse
 
rhymes profile image
rhymes

black, these are the rest of the tools:

linter: flake8 plus various plugins
formatter: black
IDE: sublime text or visual studio code
type checker: none, but you can take a look at mypy
package manager: I used to use pipenv but i've switch to poetry

As for the interpreter goes I use standard Python, the version in C you can find at python.org/

I install it through pyenv so I can easily switch between different versions in different projects