Bug 1126815

Summary: pylint 1.2 crashes on incorrect super() calls
Product: [Fedora] Fedora Reporter: Jan Cholasta <jcholast>
Component: pylintAssignee: Brian Lane <bcl>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: akozumpl, bcl, mrunge
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-05-29 15:26:21 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Cholasta 2014-08-05 11:12:45 UTC
Description of problem:

Pylint 1.2 crashes on incorrect super() calls, e.g.:

test.py:
import datetime
class Test(datetime.datetime):
    def __init__(self):
        super(datetime.datetime, self).__init__()

$ pylint test.py
No config file found, using default configuration
************* Module test
C:  1, 0: Missing module docstring (missing-docstring)
C:  2, 0: Missing class docstring (missing-docstring)
Traceback (most recent call last):
  File "/bin/pylint", line 9, in <module>
    load_entry_point('pylint==1.2.0', 'console_scripts', 'pylint')()
  File "/usr/lib/python2.7/site-packages/pylint/__init__.py", line 21, in run_pylint
    Run(sys.argv[1:])
  File "/usr/lib/python2.7/site-packages/pylint/lint.py", line 1047, in __init__
    linter.check(args)
  File "/usr/lib/python2.7/site-packages/pylint/lint.py", line 626, in check
    self.check_astroid_module(astroid, walker, rawcheckers, tokencheckers)
  File "/usr/lib/python2.7/site-packages/pylint/lint.py", line 712, in check_astroid_module
    walker.walk(astroid)
  File "/usr/lib/python2.7/site-packages/pylint/utils.py", line 715, in walk
    self.walk(child)
  File "/usr/lib/python2.7/site-packages/pylint/utils.py", line 715, in walk
    self.walk(child)
  File "/usr/lib/python2.7/site-packages/pylint/utils.py", line 712, in walk
    cb(astroid)
  File "/usr/lib/python2.7/site-packages/pylint/checkers/newstyle.py", line 135, in visit_function
    args=(call.args[0].name, ))
AttributeError: 'Getattr' object has no attribute 'name'

Version-Release number of selected component (if applicable):
pylint-1.2-6.fc20.noarch

How reproducible:
Always.

Steps to Reproduce:
See above.

Actual results:
Pylint crashes.

Expected results:
Pylint does not crash.

Additional info:

Comment 1 Brian Lane 2014-10-17 00:02:22 UTC
Posted a bug upstream - https://bitbucket.org/logilab/pylint/issue/361/attributeerror-getattr-object-has-no

Comment 2 Brian Lane 2014-10-17 00:22:02 UTC
*** Bug 1128038 has been marked as a duplicate of this bug. ***

Comment 3 Fedora End Of Life 2015-05-29 12:33:57 UTC
This message is a reminder that Fedora 20 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 20. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '20'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 20 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 4 Brian Lane 2015-05-29 15:26:21 UTC
Works fine with pylint 1.4.3 (upstream fixed it).