While your program may work functionally, it may still be hard to maintain if the style of it is messy. So it would be nice to automated code style. A favourable tool for that the flake8 ecosystem.
This would be a great time to install flake8.
# from a virtualenv python -m pip install flake8
Feedback? See an issue? Something unclear? Feel free to mention it here.
If you want to be kept up to date, consider getting the newsletter.