enable mypy type checking

This commit is contained in:
scito
2022-12-29 14:24:12 +01:00
parent 631bacc409
commit b89a338246
7 changed files with 85 additions and 8 deletions

View File

@@ -36,13 +36,17 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest pytest-mock
pip install flake8 pytest pytest-mock mypy types-protobuf
pip install --use-pep517 -r requirements.txt
mypy --install-types --non-interactive
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=200 --statistics
- name: Type checking with mypy
run: |
mypy *.py
- name: Test with pytest
run: pytest