Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions mypy/stubtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -968,7 +968,7 @@ def from_overloadedfuncdef(stub: nodes.OverloadedFuncDef) -> Signature[nodes.Arg

is_arg_pos_only: defaultdict[str, set[bool]] = defaultdict(set)
for func in map(_resolve_funcitem_from_decorator, stub.items):
assert func is not None, "Failed to resolve decorated overload"
assert func is not None, f"Failed to resolve decorated overload of {stub.fullname!r}"
args = maybe_strip_cls(stub.name, func.arguments)
for index, arg in enumerate(args):
if (
Expand All @@ -984,7 +984,7 @@ def from_overloadedfuncdef(stub: nodes.OverloadedFuncDef) -> Signature[nodes.Arg

all_args: dict[str, list[tuple[nodes.Argument, int]]] = {}
for func in map(_resolve_funcitem_from_decorator, stub.items):
assert func is not None, "Failed to resolve decorated overload"
assert func is not None, f"Failed to resolve decorated overload of {stub.fullname!r}"
args = maybe_strip_cls(stub.name, func.arguments)
for index, arg in enumerate(args):
# For positional-only args, we allow overloads to have different names for the same
Expand Down