-
Notifications
You must be signed in to change notification settings - Fork 302
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
Format Python code with black #2778
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## branch-22.12 #2778 +/- ##
===============================================
Coverage ? 60.44%
===============================================
Files ? 111
Lines ? 6515
Branches ? 0
===============================================
Hits ? 3938
Misses ? 2577
Partials ? 0 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
For sanity and convenience, this PR has a companion branch and PR #2780 that has the necessary changes before running black. #2780 will be useful for keeping this branch up to date as PRs get merged, and for updating other PRs once this PR gets merge. To verify the correctness of this PR, check out #2780 and run |
FWIW, when this comes to merge, recommend squashing all the formatting commits and adding the final "change everything" commit hash to a top-level |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assuming this contains the same changes as #2780 + changes as the result of running black
Test failure is from a timeout in a test. |
rerun tests reason: timeout failure while running a test that doesn't appear related to the PR changes, assuming it's a transient CI problem. |
@gpucibot merge |
closes #2527
I also added
.pre-commit-config.yaml
to make this easier to use and match versions (for example, I kept using a newer flake8 locally). This uses the versions of black and flake8 that are in therapids
environment in the docker container. There's a lot more we can do with pre-commit, but I didn't want to be overzealous in this PR.After this PR is merged, we should add a
.git-blame-ignore-revs
file so that I won't get blamed for everything :) . See:Once this is merged, existing PRs should probably run
black
(version 22.3.0) on their branch before merging 22.12 branch into their branch.This changes the maximum line length to 88, which is the default for black