Re:Typeguard
by nicolaslem on Friday July 29, 2022 @07:30AM
(#32275615)
In my opinion the best way to get started with typing annotations in Python is just having an editor that understands type hints.
[ Parent
| on HN ]
Re:Typeguard
by romanovcode on Friday July 29, 2022 @08:06AM
(#32275871)
Unless your environment requires you to use Python e.g. data science I just wonder why not use something with types to begin with.
I agree, but it is not enforced. When I see a @typechecked annotation I know that the tests touching that path will blow up if the type is not correct. With intellij or Visual Studio code it is more of an hint (pun intended) one cannot rely on.