Skip to content

Commit

Permalink
Merge pull request #119 from uktrade/ci/check-types
Browse files Browse the repository at this point in the history
ci: run mypy type checking
  • Loading branch information
michalc authored Nov 17, 2024
2 parents 6a165af + 8d4300c commit 4378f27
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ jobs:
- name: "Install python dependencies"
run: |
pip install ".[dev,ci]"
- name: "Run type checking"
run: |
mypy python test.py --disable-error-code import
- name: "Run tests"
run: |
coverage run -m unittest -v
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,13 @@ dependencies = [
[project.optional-dependencies]
dev = [
"coverage>=6.2",
"mypy>=1.4.1",
"pytest>=6.2.5",
"pytest-cov>=3.0.0",
"trio>=0.19.0",
]
ci = [
"mypy==1.4.1",
"pycryptodome==3.10.1",
"stream-inflate==0.0.12",
]
Expand Down
2 changes: 1 addition & 1 deletion python/stream_unzip/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -539,7 +539,7 @@ def to_sync_iterable(async_iterable):
loop = None

if loop is None:
import trio
import trio # type: ignore [no-redef, assignment]

unzipped_chunks = stream_unzip(
zipfile_chunks=to_sync_iterable(chunks),
Expand Down

0 comments on commit 4378f27

Please sign in to comment.