Conversation
|
Things I'm not sure about:
|
| Okay: def a():\n return 1\n return 2 | ||
| Okay: def a():\n return | ||
| Okay: def a():\n return\n return | ||
| Okay: def a():\n def b():\n return\n return b |
There was a problem hiding this comment.
These can be taken out as they are tested in the more detailed tests.
|
So sorry for the delay on this @r3m0t:
That makes me lean towards yes.
I think not. Mostly because it will be disabled by default, it shouldn't be required here, plus once it's on and a code-base is passing, I somehow doubt folks will want to allow someone to
Eh. I don't think we have other checks in this codebase that behave that way so it's fine that this emits more than one per function. |
|
@sigmavirus24 Can this just be landed then? Was looking for the pycodestyle code for this rule, and found it was added for pylint some time ago pylint-dev/pylint#1267 but never done here. |
This implements the same as #431 #527 (requested in #399). This is about the best that can be done without importing the
astmodule, and therefore this PR is much smaller.PEP8:
This: