Anyone out there have a solution or workaround for this?
https://github.com/python/mypy/issues/14023
Right now I’m doing:
# wrapper type is Callable[[Iterable[T]], Iterable[T]]k: KeyTypev: ValueTypefor k, v in wrapper(my_dict.items()): # type: ignore ...
Which is fine for a temporary workaround, but it’d be better to have a proper workaround for the time being.
Formatting on that is weird, I don’t know why it gets rid of the linebreaks. Here it is with linebreaks:
# wrapper type is Callable[[Iterable[T]], Iterable[T]]k: KeyTypev: ValueTypefor k, v in wraper(my_dict.items()): # type: ignore ...
# wrapper type is Callable[[Iterable[T]], Iterable[T]]
k: KeyType
v: ValueType
for k, v in wraper(my_dict.items()): # type: ignore
...
^ #python #mypy
QOTO: Question Others to Teach Ourselves An inclusive, Academic Freedom, instance All cultures welcome. Hate speech and harassment strictly forbidden.
^ #python #mypy