Merge pull request #409 from alex/flake8-cleanup

Fixed up some flake8 errors from the latest version