fix: Disable flake8 w503 #357
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When using black to autoformat an extension one flake8 rule fails on a rule which does not follow pep8. W503 is disabled by default, but because the .flake8 files are using "ignore" instead of "extend-ignore", W503 is enabled in our ruleset. The maintainer of flake8 explained here I recommend that we disable this rule, so that people may follow pep8 while also being able to use
blackto autoformat their code.Line break occurred before a binary operator (W503)
This rule goes against the PEP 8 recommended style, which was changed on April 16th, 2016 in [this commit](https://github.com/python/peps/commit/c59c4376ad233a62ca4b3a6060c81368bd21e85b). The tool [will soon be updated](https://github.com/PyCQA/pycodestyle/pull/502) to recommend the opposite: line breaks should occur before the binary operator because it keeps all operators aligned.Code Before Autoformat
Code After Autoformat
Flake8 Output