chore: add script for running mypy type checks and speed up mypy checks in CI jobs (#17489)
This commit is contained in:
parent
eb0e51d44d
commit
0b1259fc4a
5 changed files with 391 additions and 120 deletions
9
.github/workflows/api-tests.yml
vendored
9
.github/workflows/api-tests.yml
vendored
|
|
@ -53,9 +53,14 @@ jobs:
|
|||
- name: Run dify config tests
|
||||
run: poetry run -P api python dev/pytest/pytest_config_tests.py
|
||||
|
||||
- name: Cache MyPy
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: api/.mypy_cache
|
||||
key: mypy-${{ matrix.python-version }}-${{ runner.os }}-${{ hashFiles('api/poetry.lock') }}
|
||||
|
||||
- name: Run mypy
|
||||
run: |
|
||||
poetry run -C api python -m mypy --install-types --non-interactive .
|
||||
run: dev/run-mypy
|
||||
|
||||
- name: Set up dotenvs
|
||||
run: |
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue