How is python's added typing compared to TypeScript? Is it expressive enough to completely supplant traditional Python or is it just something you add in sometimes to help out a little?
If I'm not mistaken, all of the types are akin to comments: completely ignored by the interpreter.
So there's the same situation as with TS where you can't do runtime reflection to get type annotations? That seems frustrating. The one really rough edge I've seen in TS is type guards. Not the end of the world, obviously, but still kinda gross coming from Java.
You can get annotations for functions and classes with `typing.get_type_hints()`.
You can get type annotations at runtime. And you can use this for validation with something you roll yourself or with 3rd party packages. I've used pydantic [1] before and found it quite nice.
Pretty much all of my Python is typed with attrs and mypy. It's great.
Do you have editor integration by chance?
There are integrations for all the major editors.
it lacks some nice features like built-in structural subtyping (which is basically the default in TypeScript) - see my other post. A few things are a little clunkier because they're being added to an existing language rather than the language, and having to import things just to get Optional and generics is kind of ugly. But functionally, it's pretty much all there.