Skip to content

Commit 5bd779a

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

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

.github/workflows/tests.yml

+25
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,28 @@ 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+
pip install --upgrade pip
60+
# Tell setuptools to *not* create a PEP 660 import hook and to use
61+
# symlinks instead, # so that pyright can still find the package. See
62+
# https://microsoft.github.io/pyright/#/import-resolution?id=editable-installs
63+
pip install --editable . --config-settings editable_mode=strict
64+
65+
- run: echo "$PWD/.venv/bin" >> $GITHUB_PATH
66+
67+
- uses: jakebailey/pyright-action@v1
68+
with:
69+
ignore-external: true
70+
verify-types: "aocd"

0 commit comments

Comments
 (0)