Hacker News new | ask | show | jobs
by Mehdi2277 1863 days ago
The inference system and the type system are separate. Pyright uses a very different inference algorithm than mypy for better incremental support. It remains pep 484 compliant like mypy. Pyre's taint analysis is separate from pep 484 and is something different from type checking. Pyre explicitly describes taint analysis as separate from base type checking, "Pyre has applications beyond type checking python code: it can also run static analysis, more specifically called Taint Analysis, to identify potential security issues. "

My base statement of 4 main type checkers are pep 484 compliant and that's main type checking most people refer to for python. If you get a type error that's inconsistent with that pep that's a bug. If you use a feature outside of any pep like plugins, taint analysis, pyright stub generation, then yes that is unspecified and can vary. Most engineers I work with python type checking stops mostly at basic type system and I'll sometimes point them to newer peps for better type definitions. My actual experience is most places don't consistently do any type checking at all although people tend to be open to it if you're fine guiding them/setting it up.