> Message: 10
> Date: Mon, 27 Aug 2007 13:05:13 -0700
> From: "Guido van Rossum" <[EMAIL PROTECTED]>
> Subject: Re: [Python-3000] Will standard library modules comply with
> PEP 8?
> To: "Christian Heimes" <[EMAIL PROTECTED]>
> Cc: [email protected]
> Message-ID:
> <[EMAIL PROTECTED]>
> Content-Type: text/plain; charset=ISO-8859-1
>
On 8/27/07, "Guido van Rossum" <[EMAIL PROTECTED]> wrote:
> On 8/27/07, Christian Heimes <[EMAIL PROTECTED]> wrote:
> > Dennis Brakhane wrote:
> > > I'd like to ask if the modules in the standard library will comply
> > > with PEP 8. I've always found it weird that - in the logging module,
> > > for example - I have to get the logger via getLogger instead of
> > > get_logger. I understand that the logging module is older than PEP 8
> > > and therefore couldn't be changed. So if there's a time to "fix"
> > > logging, it'd probably be now.
> >
> > If I were in the position to decide I would rather change the PEP than
> > the logging module. I prefer Zope 3 style camel case names for public
> > attributes and methods
> > (http://wiki.zope.org/zope3/ZopePythonNamingConventions point 3) over
> > underscore names. I like to see the camel case style for public names as
> > an alternative in PEP 8. I find it easier to read and less to type. But
> > again it is just my personal and subjective opinion.
>
> Let's not start another bikeshed color debate. The PEP has been
> discussed, discussed again, and accepted.
>
Not trying to continue the bikeshed debate but just pointing out an area in PEP
8 which could be improved.
I would like to see PEP 8 remove the "as necessary to improve readability" in
the function and method naming conventions. That way methods like
StringIO.getvalue() can be renamed to StringIO.get_value().
from PEP 8
Function Names
Function names should be lowercase, with words separated by
underscores
as necessary to improve readability.
...
Method Names and Instance Variables
Use the function naming rules: lowercase with words separated by
underscores as necessary to improve readability.
...
John
_______________________________________________
Python-3000 mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe:
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com