Would my project benefit from static typing?
For many projects dynamic typing is perfectly fine (we think thatPython is a great language). But sometimes your projects demand biggerguns, and that’s when mypy may come in handy.
If some of these ring true for your projects, mypy (and static typing)may be useful:
- Your project is large or complex.
- Your codebase must be maintained for a long time.
- Multiple developers are working on the same code.
- Running tests takes a lot of time or work (type checking helpsyou find errors quickly early in development, reducing the number oftesting iterations).
- Some project members (devs or management) don’t like dynamic typing,but others prefer dynamic typing and Python syntax. Mypy could be asolution that everybody finds easy to accept.
- You want to future-proof your project even if currently none of theabove really apply. The earlier you start, the easier it will be toadopt static typing.