PEP8 and PyFlakes fixes