python-template icon indicating copy to clipboard operation
python-template copied to clipboard

Type hints support

Open sverhoeven opened this issue 3 years ago • 0 comments

For library users it is beneficial if typings in the library are available. It will make writing code in an IDE much richer and less error prone. Having typing from the start will help library developers take typings into account.

Adding support could involve:

  • [ ] Typings in my_module.py with docstring without types
  • [ ] Include py.typed file besides my_module.py, see PEP-561
  • [ ] Command to check typings are correct, for example mypy or pytype or pyre or prospector[with_mypy] or pytest-mypy
  • [ ] Show types in api docs, see for example sphinx-autodoc-typehints
  • [ ] Run static type check on CI
  • [ ] Optionally, use runtime type checking with typeguard

sverhoeven avatar Apr 26 '21 12:04 sverhoeven