Skip to content
Discussion options

You must be logged in to vote

I'd suggest you use a library like https://github.com/ilevkivskyi/typing_inspect. You can also typing_extensions.get_origin and get_args (backports of https://docs.python.org/3.10/library/typing.html#typing.get_args).

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@johhnry
Comment options

Answer selected by johhnry
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants