Skip to content

Commit a1bebd4

Browse files
Add pylint, pip caching improvements, and static analysis
1 parent 6b87d9c commit a1bebd4

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

.github/workflows/python-tests.yml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,28 @@ jobs:
2525
uses: actions/setup-python@v5
2626
with:
2727
python-version: ${{ matrix.python-version }}
28+
cache: pip
29+
cache-dependency-path: requirements.txt
2830

2931
- name: Install dependencies
3032
run: |
3133
python -m pip install --upgrade pip
3234
pip install -r requirements.txt
3335
34-
- name: Install pytest and pytest-cov
36+
- name: Run pylint analysis
3537
run: |
36-
pip install pytest pytest-cov
38+
bash tests/python/run_pylint.sh
39+
40+
- name: Upload pylint reports
41+
if: always()
42+
uses: actions/upload-artifact@v4
43+
with:
44+
name: pylint-reports-${{ matrix.python-version }}
45+
path: tests/python/pylint/reports/
46+
47+
- name: Verify bytecode compilation
48+
run: |
49+
python -m compileall infrastructure samples setup shared tests
3750
3851
# Run tests with continue-on-error so that coverage and PR comments are always published.
3952
# The final step will explicitly fail the job if any test failed, ensuring PRs cannot be merged with failing tests.

0 commit comments

Comments
 (0)