Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use 'pycodestyle' instead of 'pep8' #741

Merged

Conversation

vojtechtrefny
Copy link
Member

pep8 has been renamed to pycodestyle PyCQA/pycodestyle#466 but the python-pep8 package in Fedora has never been deprecated, so we are still using the two years old 1.6 version. Fortunately newest python-codestyle is available for both Fedora and RHEL/CentOS 7 so we can switch to it.

This also containts fixes for some new errors/warnings discovered by the newest pycodestyle.

The tool has been renamed two years ago -- PyCQA/pycodestyle#466
So pylint can load extensions like ped and check the code.
PEP8 has changed and it now requires line breaks before a binary
operator instead after: https://hg.python.org/peps/rev/3857909d7956

Unfortunately older versions of pep8 still report it as warning
(W503) and we don't have a simple way how to ignore different
warnings based on pep8 version.
New version of pycodestyle added some new warnings/errors.

E305 expected 2 blank lines after class or function definition
E741 ambiguous variable name
E722 do not use bare 'except'
Copy link
Contributor

@dwlehman dwlehman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good -- thanks!

@vojtechtrefny vojtechtrefny merged commit a37d50b into storaged-project:3.1-devel Dec 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants