Falsehoods People Believe about PEP 8 (was: Guido sees the light: PEP 8 updated)
Ben Finney
ben+python at benfinney.id.au
Sat Apr 16 16:21:54 EDT 2016
Chris Angelico <rosuav at gmail.com> writes:
> Maybe we need a blog post "Falsehoods Programmers Believe About PEP
> 8", along the lines of the ones about time and names.
Great suggestion. (Do you have a blog on which you could post an article
like this?)
> Remember, every one of these is false.
>
> * All Python code should follow PEP 8.
>
> * If you use a tool named pep8, your code will be PEP 8 compliant.
>
> * If your code is PEP 8 compliant, a tool named pep8 will accept it.
>
> * The Python Standard Library is PEP 8 compliant.
>
> * Okay, at least the new parts of the standard library are PEP 8
> compliant.
>
> * PEP 8 compliant code is inherently better than non-compliant code.
>
> * PEP8-ing existing code will improve it.
>
> * Once code is PEP 8 compliant, it can easily be kept that way through
> subsequent edits.
>
> * PEP 8 never changes.
>
> * Well, it never materially changes.
>
> * I mean, new advice, sure, but it'll never actually go back on a
> rule.
* The line length limit is obsolete in an age of high-resolution
displays.
* Okay, but if you disregard side-by-side windows, lines of code can be
arbitrarily long without hurting readability.
* Well, maybe not several hundred characters, but surely 120 characters
of code on a line is easy enough to read.
* The only valid white space is line breaks and U+0020 SPACE.
* Okay, U+0009 TAB when lining up columns, but no other white space.
* Oh, come on, no-one would use U+000C FORM FEED in source code.
--
\ “The apparent lesson of the Inquisition is that insistence on |
`\ uniformity of belief is fatal to intellectual, moral, and |
_o__) spiritual health.” —_The Uses Of The Past_, Herbert J. Muller |
Ben Finney
More information about the Python-list
mailing list