Skip to content
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

Enable black and isort for this repo #5551

Closed
eloquence opened this issue Oct 1, 2020 · 6 comments · Fixed by #6480
Closed

Enable black and isort for this repo #5551

eloquence opened this issue Oct 1, 2020 · 6 comments · Fixed by #6480

Comments

@eloquence
Copy link
Member

eloquence commented Oct 1, 2020

We've been trialing black and isort for auto-formatting Python code in other SecureDrop repos, and are generally happy with the combination. An example configuration can be found here:

https://github.com/freedomofpress/securedrop-client/blob/main/pyproject.toml
https://github.com/freedomofpress/securedrop-client/blob/main/Makefile

We'll want to use the same setup for SecureDrop Core, with the same settings. As with previous migrations (e.g., freedomofpress/securedrop-client#1115), we'll use .git-blame-ignore-revs to ensure that original attribution of modified lines is preserved in git blame output.

@eloquence
Copy link
Member Author

eloquence commented Oct 1, 2020

@nabla-c0d3 Perhaps you'd be interested in collaborating with us on this, after the type annotation stuff is merged (will probably still take us a couple of weeks to get through; thanks for all your work on it so far)?

@eloquence
Copy link
Member Author

We're aiming to work on this late in the 10/15-10/29 sprint, or early in the following one.

@eloquence
Copy link
Member Author

(@rmol is still focused on churning through the PR backlog to make this a bit easier, so bumped back to backlog for now.)

@eloquence eloquence added this to the 2.0.0 milestone Jan 25, 2021
@eloquence eloquence modified the milestones: 2.0.0, 1.9.0 Apr 15, 2021
@eloquence eloquence removed this from the 2.0.0 milestone Apr 26, 2021
@eloquence
Copy link
Member Author

(Doesn't need to be coupled to the next release, removing from milestone for now.)

@zenmonkeykstop zenmonkeykstop self-assigned this Mar 23, 2022
@zenmonkeykstop
Copy link
Contributor

Optimistically adding this to the 2.4.0 milestone, would like to land upcoming large changes first if possible though.

@zenmonkeykstop zenmonkeykstop added this to the 2.4.0 milestone Apr 13, 2022
@legoktm
Copy link
Member

legoktm commented Apr 13, 2022

As part of this it would be nice if we could remove the useless # -*- coding: utf-8 -*- lines and enforce a newline at the end of every file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants