See #101. This adds type annotations to the project, along with static type checking with mypy. This is only using syntax and stdlib types from Python 3.5 or below, to avoid introducing new compatibility hurdles. In the future it would be nice to leverage Python 3.6+ variables annotation syntax, and potentially also types added in Python 3.8 and backported with typing_extensions.
[x] Stay on point and keep it small so it can be easily reviewed. For example, try to apply any general refactoring separately outside of the PR.
[x] Consider adding unit tests, especially for bug fixes. If you don't, tell us why.
[x] All new and existing tests pass, with 100% test coverage (make test-coverage)
[x] Linting passes (make lint)
[x] Consider updating documentation. If you don't, tell us why.
[x] List the environments / platforms in which you tested your changes.
Background & research: https://thib.me/python-static-type-checking-field-test
See #101. This adds type annotations to the project, along with static type checking with mypy. This is only using syntax and stdlib types from Python 3.5 or below, to avoid introducing new compatibility hurdles. In the future it would be nice to leverage Python 3.6+ variables annotation syntax, and potentially also types added in Python 3.8 and backported with
typing_extensions
.make test-coverage
)make lint
)Thanks for contributing to this project!