Python
mypy Commands
Optional static type checker for Python. Catch type errors before runtime by analyzing type annotations in your code.
9 commands
Pro Tips
Start with '--strict' mode for new projects to enforce full type coverage.
Use 'py.typed' marker file to indicate your package is typed.
Configure per-module overrides in mypy.ini for gradual typing adoption.
Common Mistakes
Third-party packages may need type stubs - install types-* packages.
Use '--ignore-missing-imports' carefully - it hides real import errors.