[Python-projects] pylint crashers - AttributeError: fromlineno

Heikki Toivonen heikki at osafoundation.org
Wed Nov 1 00:46:59 CET 2006


I'm trying to upgrade to pylint 0.12.1 (and astng 0.16.1, common 0.19.2)
but it seems this version (combination) is unable to analyze the files I
am interested in without crashing. --version gives:

lint.py 0.12.1,
astng 0.16.1, common 0.19.2
Python 2.4.3 (#1, Oct 31 2006, 12:46:44)
[GCC 4.0.3 (Ubuntu 4.0.3-1ubuntu5)]

I am currently using pylint 0.11.0, astng 0.16.0, and common 0.15.0, but
would like to upgrade so that I could move onto Python 2.5.

Here's the error I get with one specific file (happens with some others
as well with slightly different stacks, but they all end in that
AttributeError):

$ ./release/RunPython tools/lint.py tools.pygettext
No config file found, using default configuration
************* Module tools.pygettext
E:  1: Wrong encoding specified (utf-8)
W:526: FIXME: currently this option has no effect at all.
C:  1: Missing docstring
Traceback (most recent call last):
  File "tools/lint.py", line 49, in ?
    lint.Run(sys.argv[1:])
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 847, in __init__
    linter.check(args)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 481, in check
    self.check_file(filepath, modname, checkers)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 495, in check_file
    astng =3D self._check_file(filepath, modname, checkers)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 519, in _check_file
    self.check_astng_module(astng, checkers)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 577, in check_astng_module
    self.astng_events(astng, [checker for checker in checkers
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/lint.py",
line 591, in astng_events
    checker.visit(astng)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/logila=
b/astng/utils.py",
line 85, in visit
    method(node)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/checkers/variables.py",
line 125, in visit_module
    self.add_message('W0622', args=3Dname, node=3Dstmts[0])
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/checkers/__init__.py",
line 84, in add_message
    self.linter.add_message(msg_id, line, node, args)
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/pylint=
/utils.py",
line 231, in add_message
    line =3D node.fromlineno#lineno or node.statement().lineno
  File
"/home/heikki/workspace/chandler/release/lib/python2.4/site-packages/logila=
b/astng/__init__.py",
line 194, in Const___getattr__
    raise AttributeError(name)
AttributeError: fromlineno

You can either download prebuilt binaries of Chandler
(http://builds.osafoundation.org/ - grab a continuous build for latest
code) or use svn and build whatever parts you want yourself
(http://wiki.osafoundation.org/bin/view/Projects/BuildingChandler).

Any ideas?

-- =

  Heikki Toivonen


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : http://lists.logilab.org/pipermail/python-projects/attachments/200610=
31/de931c4b/signature-0002.pgp


More information about the Python-Projects mailing list