fixes some errors found by flake8 (pyFlake + pep8)
enable flake8 testing