Skip to content

Commit cd5dce5

Browse files
committed
CI: Verify public API types with pyright
1 parent 1911143 commit cd5dce5

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/tests.yml

+24
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,27 @@ jobs:
4343
uses: codecov/codecov-action@v3
4444
with:
4545
token: ${{ secrets.CODECOV_TOKEN }}
46+
47+
typesafety:
48+
runs-on: ubuntu-latest
49+
50+
steps:
51+
- uses: actions/checkout@v3
52+
- uses: actions/setup-python@v4
53+
with:
54+
cache: 'pip'
55+
56+
- run: |
57+
python -m venv .venv
58+
source .venv/bin/activate
59+
# Tell setuptools to *not* create a PEP 660 import hook and to use
60+
# symlinks instead, # so that pyright can still find the package. See
61+
# https://microsoft.github.io/pyright/#/import-resolution?id=editable-installs
62+
pip install --editable . --config-settings editable_mode=strict
63+
64+
- run: echo "$PWD/.venv/bin" >> $GITHUB_PATH
65+
66+
- uses: jakebailey/pyright-action@v1
67+
with:
68+
ignore-external: true
69+
verify-types: "aocd"

0 commit comments

Comments
 (0)