diff options
-rw-r--r-- | pylint/checkers/classes.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pylint/checkers/classes.py b/pylint/checkers/classes.py index c5d631f24..6fffd2b16 100644 --- a/pylint/checkers/classes.py +++ b/pylint/checkers/classes.py @@ -909,6 +909,8 @@ a metaclass class method.", continue for attribute in node.nodes_of_class(astroid.Attribute): attribute = cast(astroid.Attribute, attribute) + if attribute.expr is None: # attribute.expr is probably not really an Optional ? + continue if ( attribute.attrname == function_def.name and attribute.scope() != function_def # We ignore recursive calls |