-
Notifications
You must be signed in to change notification settings - Fork 3
43 lines (40 loc) · 1.09 KB
/
python-tests.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Python tests
on:
workflow_dispatch: # Allows manual triggers
push:
branches:
- main
paths:
- "**.py"
- "**.pyi"
- "**/requirements*.txt"
- "**/pyproject.toml"
- ".github/workflows/python-tests.yaml"
pull_request:
branches:
- main
paths:
- "**.py"
- "**.pyi"
- "**/requirements*.txt"
- "**/pyproject.toml"
- ".github/workflows/python-tests.yaml"
env:
PIP_DISABLE_PIP_VERSION_CHECK: 1
FORCE_COLOR: 1
jobs:
pyright:
name: Run pyright
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get pyright version
id: pyright_version
run: |
PYRIGHT_VERSION=$(grep pyright== 'Dolphin scripts/requirements-dev.txt' | cut -d "#" -f 1 | cut -d \; -f 1 | cut -d = -f 3)
echo pyright version: "${PYRIGHT_VERSION}"
echo PYRIGHT_VERSION="${PYRIGHT_VERSION}" >> "${GITHUB_OUTPUT}"
- uses: jakebailey/pyright-action@v2
with:
version: ${{ steps.pyright_version.outputs.PYRIGHT_VERSION }}
extra-args: --threads