On 19 juin 10:41, Skip Montanaro wrote: > On Wed, Jun 19, 2013 at 2:37 AM, Sylvain Thénault > <sylvain.thena...@logilab.fr> wrote: > > On 07 juin 09:18, Martin Pool wrote: > >> On 7 June 2013 06:49, Skip Montanaro <s...@pobox.com> wrote: > >> > >> > If I never refer to self.x or self.y within the class's methods it > >> > would be nice to be alerted. > >> > > >> > >> +1, and that seems feasible to add to pylint. > > > > Hey guys, today is your last chance to contribute this to the pylint 10th > > anniversary sprint ;) > > And to get it in forthcoming 1.0... > > > > Monday and tuesday reports: > > https://www.logilab.org/blogentry/146924 > > https://www.logilab.org/blogentry/147339 > > > > -- > > Sylvain Thénault, LOGILAB, Paris (01.45.32.03.12) - Toulouse > > (05.62.17.16.42) > > Formations Python, Debian, Méth. Agiles: http://www.logilab.fr/formations > > Développement logiciel sur mesure: http://www.logilab.fr/services > > CubicWeb, the semantic web framework: http://www.cubicweb.org > > I don't have a bunch of spare time, but can you point me in the > general direction of where such a check would be made? I believe > pylint already has a "set but not used" message for local variables. > This check could, I think, be patterned after that code.
There is an unused-variable message in the variables checker (pylint/checkers/variables.py). This is probably worth reading indeed, though in this particular case in should rather go in the classes checker (pylint/checkers/classes.py). > Sorry, I wasn't aware you were sprinting. no problem. I will do a whole sprint report later today. -- Sylvain Thénault, LOGILAB, Paris (01.45.32.03.12) - Toulouse (05.62.17.16.42) Formations Python, Debian, Méth. Agiles: http://www.logilab.fr/formations Développement logiciel sur mesure: http://www.logilab.fr/services CubicWeb, the semantic web framework: http://www.cubicweb.org _______________________________________________ code-quality mailing list code-quality@python.org http://mail.python.org/mailman/listinfo/code-quality