Hacker News new | past | comments | ask | show | jobs | submit login

Why would you resist it?



It would be nice if the language was typed. Easier for overall maintenance, and refactoring for big projects.


Type hinting is a standard feature since Python 3.6.

https://docs.python.org/3/library/typing.html

The thing about python, as overall language philosophy, is convention over enforcement.

If you want your team to have a particular style and use certain features, then you should agree to do it and then use automated tools (like pep8, flake) to check that code complies with those rules, but it is up to you how you want to write the code.


Python 3 is typed. Not strongly typed but the point remains. Python is used in a lot of domains and I feel the strides the language has made over the past decade have made it very competitive and a worthy addition to any programmer's toolbox.


Python is strongly typed. It is not statically typed.


There is a way: http://mypy-lang.org/

I've used Python a fair bit for a variety of semi-permanent or long scripts. I would have liked types more as well. Discovered MyPy after those instances.


It has a very nice strong typing add on in mypy. Highly recommended for a couple of years now. It’s technically optional but your CI process should take care of that.


You should look into type hinting and MyPy




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: