[Python-ideas] PEP 8 update on line length
Steve Barnes
gadgetsteve at live.co.uk
Tue Feb 19 01:20:20 EST 2019
From: Python-ideas <python-ideas-bounces+gadgetsteve=live.co.uk at python.org> On Behalf Of Anders Hovmöller
Sent: 19 February 2019 06:11
To: David Mertz <mertz at gnosis.cx>
Cc: Simon <simon.bordeyne at gmail.com>; python-ideas <python-ideas at python.org>
Subject: Re: [Python-ideas] PEP 8 update on line length
> On 19 Feb 2019, at 05:48, David Mertz <mertz at gnosis.cx> wrote:
>
> You either have much better eyes to read tiny fonts than I do, or maybe a much larger monitor (it's hard for me to fit a 30"" monitor in my laptop bag).
>
> But that's not even the real issue. If the characters were in giant letters on billboards, I still would never want more than 80 of them on a line (well, rarely, I violate PEP 8 sometimes). Centuries if not millennia of experience with writing show that cognitive burden goes up exponentially, not linearly, as lines get to be more than about 60 characters.
If that is the issue then we should be talking about non-space characters, not a 68 column limit right? No way does 40 spaces due to indent count towards the cognitive burden :)
Also, if the cognitive burden is the issue then we should talk about short forms for keyword arguments again. The way the 68 column limit works in practice is that people avoid keyword arguments because of line length, plus the issues already mentioned.
/ Anders
[Steve Barnes]
If you are getting to 40 spaces of indent, (for _most_ people that is 10 scope changes, e.g. fn then 9 levels of if), then you are already facing a major cognitive burden and should probably be refactoring.
More information about the Python-ideas
mailing list