I've already met a few times with mypy reacting to the following code:
def run(self, values: Variadic[int]):
for value in values:
...
By saying that values is an int, so it's not iterable. That is correct because right now Variadic gives mypy no hint of being an Iterable. We should make Variadic alias a type such as List or Sequence to fix this issue.
I've already met a few times with mypy reacting to the following code:
By saying that
values
is anint
, so it's not iterable. That is correct because right nowVariadic
gives mypy no hint of being an Iterable. We should makeVariadic
alias a type such asList
orSequence
to fix this issue.