Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'skip:[ 20': 0.03; 'attribute': 0.05; '*not*': 0.07; 'suppose': 0.07; 'python': 0.09; 'pep': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'terry': 0.09; 'underscore': 0.09; 'yet.': 0.13; 'properly': 0.15; 'value.': 0.15; '"invalid': 0.16; '(should': 0.16; 'agree.': 0.16; 'boolean': 0.16; 'improper': 0.16; 'name"': 0.16; 'naming': 0.16; 'needless': 0.16; 'pep8': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'situation.': 0.16; 'tool.': 0.16; 'wrote:': 0.17; 'jan': 0.18; 'saying': 0.18; '>>>': 0.18; 'variable': 0.20; 'tells': 0.22; 'seems': 0.23; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'creating': 0.26; 'am,': 0.27; 'mike': 0.27; 'separate': 0.27; 'convention': 0.27; "doesn't": 0.28; 'header:X-Complaints-To:1': 0.28; 'style.': 0.29; 'surprised': 0.29; 'case,': 0.29; 'words': 0.29; 'related': 0.30; 'that.': 0.30; 'error': 0.30; 'sense': 0.31; '(and': 0.32; 'like:': 0.33; 'to:addr:python-list': 0.33; 'recommended': 0.33; 'clear': 0.35; 'community': 0.35; 'pm,': 0.35; 'something': 0.35; 'received:org': 0.36; 'really': 0.36; 'but': 0.36; 'should': 0.36; 'does': 0.37; 'quite': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'little': 0.39; 'skip:" 10': 0.40; 'header:Received:5': 0.40; 'subject:, ': 0.61; 'subject:...': 0.63; 'more': 0.63; 'making': 0.64; 'wanting': 0.65; 'middle': 0.66; 'capital': 0.68; '9:19': 0.84; 'checker': 0.84; 'received:fios.verizon.net': 0.84; 'subject:very': 0.91; 'choice.': 0.93 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: pylint, was Re: pygame - importing GL - very bad... Date: Thu, 03 Jan 2013 11:52:33 -0500 References: <50e4c83b$0$30003$c3e8da3$5496439d@news.astraweb.com> <50E59367.1040306@vrplumber.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: pool-173-75-251-66.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Thunderbird/17.0 In-Reply-To: <50E59367.1040306@vrplumber.com> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 33 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1357231993 news.xs4all.nl 6851 [2001:888:2000:d::a6]:54792 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:36070 On 1/3/2013 9:19 AM, Mike C. Fletcher wrote: > On 13-01-02 09:48 PM, Terry Reedy wrote: > ... >> 2) self.lightDone: Invalid name "lightDone" (should match >>> [a-z_][a-z0-9_]{2,30}$) >>> >>> So I can now understand that pylint doesn't like my naming convention >>> with a capital letter in the middle of the variable name, like: >>> "lightDone" = a boolean value. I suppose pylint wants me to use (a >>> little longer method) an underscore to separate words in long variable >>> names... >> >> That is more conventional in the Python community (and is in pep 8, I >> believe) but still a choice. > That seems like a improper error message from the tool. "Invalid name" > does *not* properly describe that situation. The name is *not* > "Invalid" in any sense of the word, and a "checker" that tells you it is > is creating needless false-positives. An error checker should be saying > something like: > > "self.lightDone: Does not match PEP8 recommended style" > > making it clear that this is *not* an error, it is a *style* related > *warning*. I quite agree. Wanting 3 chars for attribute names is not even PEP-8 style but pylint-author style. I was really surprised at that. In that case, 'Does not match pylint recommended style.' or even 'configured styles'. I have not used pylint or pychecker as of yet. -- Terry Jan Reedy