We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Python 3.11 added support for generic TypedDicts.
For example, the following generic TypedDict can (probably) be defined now:
T = TypeVar('T', bound=Union[int, float, complex]) class Point(TypedDict, Generic[T]): x: T y: T int_point: Point[int] = {"x": 1, "y": 2} float_point: Point[float] = {"x": 1.0, "y": 2.0} complex_point: Point[complex] = {"x": 1j, "y": 2j}
It would be nice if trycast() recognized parameterized TypedDict types like Point[int]
Point[int]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Python 3.11 added support for generic TypedDicts.
For example, the following generic TypedDict can (probably) be defined now:
It would be nice if trycast() recognized parameterized TypedDict types like
Point[int]
The text was updated successfully, but these errors were encountered: