Closed
Description
openedon Aug 11, 2023
The NamedTuple
function does not support keyword parameters, so the following causes a runtime error. Pyright doesn't catch this currently.
from typing import NamedTuple
NT1 = NamedTuple(typename="NT1", fields=[("a", str), ("b", str)])
This is related to mypy issue python/mypy#8651.
Related to this, the namedtuple
function does support keyword parameters, but pyright doesn't currently validate those.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment