News for hackers. Stuff that matters.
Re:Google's Python style guide by raverbashing on Thursday April 19, 2012 @07:20AM (#3862387)
There are 2 issues there

1 - yes, screens are huge, but it doesn't mean people can/will use small fonts or will scroll the screen

With today's big/wide screens it's more useful to have code side by side.

2 - Abuse. The 80 character limit is a pretty good indicator that you should be doing something else instead of having your code go over 80 characters.

Long lines are confusing, and you most likely can split the logic in several lines, facilitating maintenance.

Re:Google's Python style guide by jdevera on Thursday April 19, 2012 @07:32AM (#3862421)
I see both points but regarding (2), there are common cases where you are not necessarily doing anything wrong but the 80 character limit will make your code less readable, especially when using four spaces or more for indentation. For example you might end up in the fourth level of indentation wanting to write a list comprehension that would be perfectly readable in one line but have to break it down because of this rather short hard limit.

I think having a soft and a hard limit makes more sense, if anything, I would make 80 characters the soft limit and perhaps 100 a hard limit, although I'd prefer them to be 100 and 120.

Re:Google's Python style guide by bonzoesc on Thursday April 19, 2012 @07:34AM (#3862426)
If you're in the fourth level of indentation, you might already have a readability problem.
Re:Google's Python style guide by jdevera on Thursday April 19, 2012 @07:56AM (#3862489)
"Might" being the key word. You might, if you are writing a simple script, but if you are writing some more complex code, class and method already take two levels, and that is your base line, I don't see how having two more levels is a readability problem.
Re:Google's Python style guide by khill on Thursday April 19, 2012 @10:53AM (#3863278)
I find that limiting line length to 80 characters causes some programmers to use overly terse variable names. This hurts code readability and can hide defects.