Fix style consistency issues to pass flake8