-
Notifications
You must be signed in to change notification settings - Fork 799
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
Make Travis check formatting with Black #215
Conversation
Hello @tomwhite! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:
Comment last updated at 2019-05-23 17:12:24 UTC |
This is failing because |
I'm not really sure -- I have never been that good at this CI stuff. I'll try to look into it when I get some time; I'm kind of swamped with things right now. |
If you want to use black (which you should), then you should relax the line limit to 88: https://github.com/python/black#line-length. |
Try adding "black" to the dependencies in Line 29 in b381667
|
Thanks @jamesmyatt. I'll see if I can get that sorted soon. |
Thanks for the suggestion @jamesmyatt. It's getting a bit further now, but is failing one build as |
We should just start ignoring python2. It is going to be end of life soon, and I have no particular desire to support it (and have pledged to drop support for it by Jan 1 2020 anyway, so we certainly do not ahve to provide any support after that). |
The If you go this way, I also suggest doing the black check before the tests, rather than after. This way the check fails faster. Also the coverage checks often falsely fail the build due to negligible negative changes in coverage which would otherwise hide a "true" failure due to a forgotten reformatting. Finally, I added a section about using |
Thanks for the suggestions James. Here's another attempt. |
Sorry for being slow to get to this, but thanks for all the work people have put it. It is definitely appreciated. Merging now, and thanks again! |
Black has been used to format the source previously. This adds a check and fails the build if the source is not correctly formatted. PR authors can fix the formatting by running
black umap
.