|
|
|
|
|
by farhanhubble
636 days ago
|
|
Dynamic typing with deeply nested data forces you to put type bandaids all over the code. For example you end up defining Pydantic schemas and then validating the same thing more than once since you can't guarantee that the type of a thing was not changed somewhere in the middle. Dynamic typing forces you to test behavior which could be tested much more thoroughly by a type checker, at compile time, with zero development time. Dynamic typing does offer much faster time to early prototyping but then drags you down with each bug. Static typing does force some early commitments to the structure of the data but it also allows faster iteration and refactoring. Static typing with good type inference seems the best to me. |
|