This bit of code:
def foo():
print("hello")
violates PEP 0008, which states
Use 4 spaces per indentation level.
But neither the pep8
, pyflakes
, or flake8
commands warn about it.
How can I get one of them to complain about this unpythonic code?
pylint
would warn about this violation:
$ pylint test.py
No config file found, using default configuration
************* Module test
W: 2, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
Note that pep8
would warn you only if indentation is not a multiple of four (E111 error code).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With