pylint, was Re: pygame - importing GL - very bad...

Chris Rebert clp2 at rebertia.com
Thu Jan 3 07:33:36 CET 2013


On Wed, Jan 2, 2013 at 10:01 PM, Ben Finney <ben+python at benfinney.id.au> wrote:
> Ian Kelly <ian.g.kelly at gmail.com> writes:
>
>> On Wed, Jan 2, 2013 at 7:24 PM, someone <newsboost at gmail.com> wrote:
>> > 1) class somethingWork: Invalid name "somethingWork" (should match
>> > [A-Z_][a-zA-Z0-9]+$), I'm not that good at regular exps, but I
>> > suppose it wants my class name to start with a capital letter ?
>>
>> Yes, PEP-8 recommends CamelCase for class names.
>
> PEP 8 discourages camelCase for names except for compatibility purposes,
> and recommends TitleCase for class names.

If we must quibble over meta-nomenclature...
http://www.python.org/dev/peps/pep-0008/ :
"""
The following naming styles are commonly distinguished:
[...]
* CapitalizedWords (or CapWords, or CamelCase -- so named because of
the bumpy look of its letters [3]). […]
* mixedCase (differs from CapitalizedWords by initial lowercase character!)
"""

The term "TitleCase" does not make an appearance in the document.

Regards,
Chris



More information about the Python-list mailing list