▲ | never_inline 7 months ago | |
> for more complex data structures (think a json response from an api), dict (or typing.Dict) work fine One of the reason I use typing is IDE completion and error highlighting. For that purpose - I make sure to annotate even the obvious primitive types and for API responses, I find that defining a Pydantic model works very well. |