Remove trailing whitespace
Removed unused import
Tidy up with flake8