Package: pylint
Version: 0.13.2-2
Severity: normal

When I run PyLint on this minimal python script:

from PyQt4 import QtCore
class Cl(object):
        def method(self, r = QtCore.Qt.DisplayRole):
                pass

I get the following output:

$ pylint minimal.py 
No config file found, using default configuration
************* Module diskmanipulator
W:  3: Found indentation with tabs instead of spaces
W:  4: Found indentation with tabs instead of spaces
C:  1: Missing docstring
C:  2:Cl: Missing docstring
C:  3:Cl.method: Missing docstring
Traceback (most recent call last):
  File "/usr/bin/pylint", line 4, in ?
    lint.Run(sys.argv[1:])
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 897, in __init__
    linter.check(args)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 497, in check
    self.check_file(filepath, modname, checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 514, in 
check_file
    astng = self._check_file(filepath, modname, checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 538, in 
_check_file
    if not self.check_astng_module(astng, checkers):
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 599, in 
check_astng_module
    self.astng_events(astng, [checker for checker in checkers
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 617, in 
astng_events
    self.astng_events(child, checkers, _reversed_checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 617, in 
astng_events
    self.astng_events(child, checkers, _reversed_checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 617, in 
astng_events
    self.astng_events(child, checkers, _reversed_checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 617, in 
astng_events
    self.astng_events(child, checkers, _reversed_checkers)
  File "/usr/lib/python2.4/site-packages/pylint/lint.py", line 614, in 
astng_events
    checker.visit(astng)
  File "/usr/lib/python2.4/site-packages/logilab/astng/utils.py", line 84, in 
visit
    method(node)
  File "/usr/lib/python2.4/site-packages/pylint/checkers/base.py", line 367, in 
visit_function
    self._check_defaults(node)
  File "/usr/lib/python2.4/site-packages/pylint/checkers/base.py", line 531, in 
_check_defaults
    value = default.infer().next()
  File "/usr/lib/python2.4/site-packages/logilab/astng/inference.py", line 51, 
in wrapped
    if not ares in yielded:
  File "/usr/lib/python2.4/site-packages/logilab/astng/__init__.py", line 251, 
in Const___getattr__
    self._proxied = MANAGER.astng_from_class(self.value.__class__)
  File "/usr/lib/python2.4/site-packages/logilab/astng/manager.py", line 191, 
in astng_from_class
    return modastng.getattr(klass.__name__)[0] # XXX
  File "/usr/lib/python2.4/site-packages/logilab/astng/scoped_nodes.py", line 
229, in getattr
    raise NotFoundError(name)
logilab.astng._exceptions.NotFoundError: ItemDataRole


This seems to be some kind of bug...

Note that you need to have PyQt4 installed to reproduce it.

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (990, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.21-2-k7 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages pylint depends on:
ii  python                        2.4.4-6    An interactive high-level object-o
ii  python-logilab-astng          0.17.1-1   extend python's abstract syntax tr
ii  python-logilab-common         0.22.2-1   useful miscellaneous modules used 

Versions of packages pylint recommends:
ii  python-tk                     2.4.4-1    Tkinter - Writing Tk applications 

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to