-
Notifications
You must be signed in to change notification settings - Fork 42
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
Add black and isort #1115
Add black and isort #1115
Conversation
Is this blocked on the same packaging change described in freedomofpress/securedrop-sdk#124 (comment) ? |
Technically not blocked -- the formatting changes can be verified -- but we do need to change the Debian package rules in securedrop-debian-packaging before we can successfully package it. |
Um, I should check CI before talking. Yeah, this isn't getting through CI until the packaging repo is updated. I'll see to that first thing in the morning. |
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.
The change looks good, I will go through it once more after the CI is green.
@rmol Flagging that this branch now has conflicts. |
@eloquence Thanks, rebased. |
And again. 😐 |
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.
Trying to approve. This is good.
Description
Adds the black and isort tools to the development requirements, and adds Makefile targets for both checking and applying them.
Fixes #1100.
Test Plan
add-black-isort
withgit checkout 86ee815
make check-isort
. It should show the changes it would make.make check-black
. It should show the changes it would make.git checkout add-black-isort
make check-isort
andmake check-black
. No changes should be indicated.git blame securedrop_client/logic.py | head -60 | grep -c 361ba88
. There should be 22 lines attributed to that revision.git config blame.ignoreRevsFile .git-blame-ignore-revs
git config blame.markIgnoredLines true
git config blame.markUnblamableLines true
git blame securedrop_client/logic.py | head -60 | grep 361ba88
. There should be three lines attributed to that revision, each prefixed with an asterisk. This indicates that those changes are only attributable to the ignored revision.Checklist
If these changes modify code paths involving cryptography, the opening of files in VMs or network (via the RPC service) traffic, Qubes testing in the staging environment is required. For fine tuning of the graphical user interface, testing in any environment in Qubes is required. Please check as applicable:
If these changes add or remove files other than client code, the AppArmor profile may need to be updated. Please check as applicable:
If these changes modify the database schema, you should include a database migration. Please check as applicable:
master
and confirmed that the migration applies cleanlymaster
and would like the reviewer to do so