-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use Black and isort for automatic formatting #184
Comments
Hello, Black contributor here! FYI, isort 5 has been released. It now has built-in Black support via profiles -> Line 3 in 31166a1
Just something to keep in mind when considering to use Black (and isort) together for automatic code formatting. We're still working on the "magic trailing comma" issues so I do agree that introducing Black should wait for now (probably isort too since v5 is big change and probably needs a bit of ironing out - if isort v5 is used). |
Thank you for the information and suggestions! |
The magic trailing comma issue has been fixed! And I'm warming up to the formatting against which the other issue was raised. So we ought to start looking at this again! |
Let's wait just a bit for the stable version of Black to be released. I was a bit quick to pull off the label. |
Also, when the time comes, Pre-commit could be used to enforce the formatting and reducing the number of oopsies. Remembering to run |
We could also use some RST formatter if one exists. Prettier is only for MD. It's rather annoying to change things yourself, particularly for contributors that don't know about it yet (ref #260). |
The first stable version of Black released! 🎉 |
😉 Thanks for the reminder! |
Finally there's enough action to warrant a resolution here, I'll look to introduce this for 5.0 |
We should format code automatically. I already tried out a configuration in #183, but due to some issues with Black (psf/black#1054 & psf/black#1288) we'll be delaying that.
Here's the configuration in
tox.ini
:The text was updated successfully, but these errors were encountered: