Perform Style Checking on your Python 3 using flake8 and formate code using black
Flake8 is a Python library that wraps PyFlakes, pycodestyle and Ned Batchelder's McCabe script. It is a great toolkit for checking your codebase against coding style (PEP8), programming errors (like “library imported but unused” and “Undefined name”) and checking cyclomatic complexity.
Black is the uncompromising Python code formatter. By using it, you agree to cede control over minutiae of hand-formatting. In return, Black gives you speed, determinism, and freedom from pycodestyle nagging about formatting. You will save time and mental energy for more important matters.