I had a hard time finding something in pep8 that would forbid this (and pycodestyle itself doesn't trigger a lint) but deep down inside I feel it surely should :)
[(a,)for a in y]
Maybe something like "expected spaces around keyword for"?
but deep down inside I feel it surely should
I feel the same.
This should probably be a new check altogether though.
This is a grey area as I noted in a similar case https://github.com/PyCQA/pycodestyle/issues/570
But [pep 8] doesnt address when unassigned data-structures are used immediately near a keyword like
iforfor.
I suspect this should be a non-controversial update to PEP 8.
Another (related) strange one:
from .import bar
(works the same as from . import bar)
Is that supposed to be from .import bar?
yep, woops, edited
Would the rule here be 'all keywords must be preceded and followed by one space character'?
Another related case:
try:
...
except(IOError,):
...
Duplicate of #371
Most helpful comment
Would the rule here be 'all keywords must be preceded and followed by one space character'?