1

I am using PyLint for years now and have just installed PyLint 1.2.1 on Python 2.7.6

When I am running PyLint 1.2.1 (within PyScripter 2.5.3) on any Python script, I get error log:

Command line: D:\PROGRA~1\Python27\python.exe D:\PROGRA~1\Python27\Lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\lint.py "E:\test\dotnetver.py" --msg-template="{path}:{line}: [{msg_id}({symbol}), {obj}] {msg}" Working directory: Timeout: 0 ms ************* Module dotnetver E:\test\dotnetver.py:2: [I0011(locally-disabled), ] Locally disabling missing-docstring (C0111) No config file found, using default configuration Traceback (most recent call last): File "D:\PROGRA~1\Python27\Lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\lint.py", line 1106, in <module> Run(sys.argv[1:]) File "D:\PROGRA~1\Python27\Lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\lint.py", line 1051, in __init__ linter.check(args) File "D:\PROGRA~1\Python27\Lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\lint.py", line 626, in check self.check_astroid_module(astroid, walker, rawcheckers, tokencheckers) File "D:\PROGRA~1\Python27\Lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\lint.py", line 708, in check_astroid_module checker.process_module(astroid) File "D:\PROGRA~1\Python27\lib\site-packages\pylint-1.2.1-py2.7.egg\pylint\checkers\format.py", line 477, in process_module if 'print_function' in module.future_imports: AttributeError: 'Module' object has no attribute 'future_imports' Process "Pylint" terminated, ExitCode: 00000001 

Is this a Bug in the new PyLint version or have I missed something?

1
  • 2
    you should update astroid as well Commented Jul 24, 2014 at 15:06

2 Answers 2

3

Upgrading astroid fixed this after a pylint upgrade

pip install --upgrade astroid 
Sign up to request clarification or add additional context in comments.

1 Comment

Specifically, fixed in astroid 1.2. Note, using astroid 1.4.3 will fail with from astroid.utils import ASTWalker ImportError: No module named utils
0

if using Debian or its derivatives, you may need to specifically apt-get install python-astroid. it wasn't one of the packages automatically updated by the install of pylint.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.