News for hackers. Stuff that matters.
Re:Python 1.0.0 is out (1994) by ageofwant on Saturday January 27, 2018 @03:42AM (#16245395)
Yea thats what mypy is for, and that fits my workflow too: Rapidly prototype once the API has stabilised, I add the typehints.

For unfammilliar codebases using MonkeyType is now a option too.

Re:Python 1.0.0 is out (1994) by nicolaslem on Saturday January 27, 2018 @04:13AM (#16245491)
I started using type hints and it greatly improves the readability and sometimes catches a mistake. But would love for it to be more.

Maybe a flag to the interpreter that would raise an exception each time it detects an inconsistency at runtime. I can imaging turning this feature on in a staging environment.

Re:Python 1.0.0 is out (1994) by ATsch on Saturday January 27, 2018 @05:49AM (#16245714)
From my understanding, this should be possible by setting the sys.settrace hook. It would slow down every function call, but I'm surprised it looks like nobody has done it yet.