Skip to content

Commit

Permalink
Undo some type aliases (TEMPORARY)
Browse files Browse the repository at this point in the history
  • Loading branch information
nickdrozd committed Oct 1, 2024
1 parent 7581b77 commit af507d7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pylint/checkers/variables.py
Original file line number Diff line number Diff line change
Expand Up @@ -3334,7 +3334,7 @@ def _check_type_imports(

def _check_metaclasses(self, node: nodes.Module | nodes.FunctionDef) -> None:
"""Update consumption analysis for metaclasses."""
consumed: list[tuple[Consumption, str]] = []
consumed: list[tuple[dict[str, list[nodes.NodeNG]], str]] = []

for child_node in node.get_children():
if isinstance(child_node, nodes.ClassDef):
Expand All @@ -3349,12 +3349,12 @@ def _check_classdef_metaclasses(
self,
klass: nodes.ClassDef,
parent_node: nodes.Module | nodes.FunctionDef,
) -> list[tuple[Consumption, str]]:
) -> list[tuple[dict[str, list[nodes.NodeNG]], str]]:
if not klass._metaclass:
# Skip if this class doesn't use explicitly a metaclass, but inherits it from ancestors
return []

consumed: list[tuple[Consumption, str]] = []
consumed: list[tuple[dict[str, list[nodes.NodeNG]], str]] = []
metaclass = klass.metaclass()
name = ""
if isinstance(klass._metaclass, nodes.Name):
Expand Down

0 comments on commit af507d7

Please sign in to comment.