Make PEP8 testing stricter and tidy up some cruft

The run_tests script is now stricter so it can find unused imports.

Remove said unused imports so they don't annoy my syntax checker every time I
open these files!