There was an error while loading. Please reload this page.
1 parent a73b51f commit 855c354Copy full SHA for 855c354
pylint/checkers/utils.py
@@ -1174,10 +1174,8 @@ def class_is_abstract(node: nodes.ClassDef) -> bool:
1174
1175
# As well as directly inherited ABC class
1176
for base in node.bases:
1177
- base_class_name = (
1178
- base.attrname if isinstance(base, astroid.Attribute) else base.as_string()
1179
- )
1180
- if base_class_name == "ABC":
+ inferred_base = safe_infer(base)
+ if inferred_base.name == "abc" and inferred_base.root().name == "ABC":
1181
# abc.ABC inheritance
1182
return True
1183
0 commit comments