3 ms·
You're being downvoted, but I sort of agree... How in the world can I stop worrying about errors like using a non existant class member and having a runtime ex
by _zamorano_ 3y ago
You're being downvoted, but I sort of agree...
How in the world can I stop worrying about errors like using a non existant class member and having a runtime exception? How can I refactor?
Ok, the core devs add annotations, then type hints to the language.
Some other people create MyPy, the JetBrains people use some other linting thing that does well, but does not match MyPy. The Pydantic appear and some other people says its awesome, but yet again, different to the others...
And all that to enforce things we already had 20 years ago in Java 1.0
How about using dynamic typing for small script and prototyping and using better tools for bigger projects?
- ptx 3y agoJava 1.0 didn't have generics, so collection elements were only type-checked at runtime, and Java still doesn't have null-safety in the type system. The Python type annotations handle both of these things.