News for hackers. Stuff that matters.
Re:Google Python Style Guide by tvon on Saturday May 01, 2010 @04:37PM (#1311196)
A "how this differs from PEP8" summary would be useful to me, assuming it differs.
Re:Google Python Style Guide by d0mine on Saturday May 01, 2010 @07:35PM (#1311459)
The crucial difference:

Google (original formatting):

  BE CONSISTENT. 
PEP8:

  A Foolish Consistency is the Hobgoblin of Little Minds
Re:Google Python Style Guide by sigzero on Saturday May 01, 2010 @07:41PM (#1311478)
No...those are different. One is just telling you to "be" consistent and the other is telling you not to be "foolish" about it. Much different in my mind.
Re:Google Python Style Guide by vcrash on Saturday May 01, 2010 @09:49PM (#1311725)
Seeing as the response is to a comment asking for differences, wouldn't it make sense to assume that it shows differences? In fact, the response notes that they are an example of a "crucial difference".
Re:Google Python Style Guide by tvon on Sunday May 02, 2010 @01:15AM (#1312005)
I think sigzero means "different" as in "not contradictory or in conflict"
Re:Google Python Style Guide by d0mine on Tuesday May 11, 2010 @07:57AM (#1337515)
Google uses CAPS LOCK that I understand as a command "be consistent no matter what".

The quote from PEP8 translates in my mind to "be consistent if it's worth it".

These policies are not orthogonal. You can't satisfy both in all cases.

Re:Google Python Style Guide by etal on Saturday May 01, 2010 @10:35PM (#1311799)
I had thought the main difference was indenting with 2 spaces instead of 4, but this style guide says 4 spaces, too. I guess Google deliberately brought themselves in sync with the Python mainstream.

This style guide looks like a superset of PEP 8 -- where PEP 8 describes what Python code should look like, this guide goes through every Python feature and lays out exactly where a sizable group of top-notch Python hackers were willing to draw the line on maintainability vs. whipupitude for large, long-running projects.

Re:Google Python Style Guide by durin42 on Sunday May 02, 2010 @01:25AM (#1312018)
This is decidedly not the same as the internal guide. 2-space indents are the norm, and functions_like_this are supposed to be spelled FunctionsLikeThis (yes, with the leading capital). Those are the two big differences from PEP8 that I can think of.