-
Notifications
You must be signed in to change notification settings - Fork 82
Code Formatting
John Pocock edited this page May 12, 2021
·
4 revisions
We use Black. Please cede formatting control to Black.
Please ensure that you are using the version of black in the requirements files. Check your version with black --version
.
To format a single file:
black file.py
To format all .py files in the current directory:
black ./
https://black.readthedocs.io/en/stable/editor_integration.html
-
Docstring at the top
-
Module imports
- First tiatoolbox import and then external libraries
-
Class definition
-
Function definition
-
Version definition