Skip to content

ci: check types with mypy #1226

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Apr 23, 2021
Prev Previous commit
ci: check types with mypy
This will result in _partial_ type checking of the type annotations by
using mypy. Keep in mind though that mypy is performing _static_
analysis in a _dynamic_ language so it can only partially check for
correctness.

Some other tool(s) will be needed to have more complete type checking at
runtime. E.g. [typeguard].

[typeguard]: https://pypi.org/project/typeguard/
  • Loading branch information
muggenhor committed Apr 23, 2021
commit 043e15fe140cfff8725d4f615f42fa1c55779402
5 changes: 5 additions & 0 deletions .github/workflows/pythonpackage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,11 @@ jobs:
pip install flake8
# stop the build if there are Python syntax errors or undefined names
flake8 --ignore=W293,E265,E266,W503,W504,E731 --count --show-source --statistics
- name: Check types with mypy
run: |
set -x
pip install tox
tox -e type
- name: Test with nose
run: |
set -x
Expand Down