-
Notifications
You must be signed in to change notification settings - Fork 72
43 lines (34 loc) · 1.13 KB
/
Copy pathcheck-python.yaml
File metadata and controls
43 lines (34 loc) · 1.13 KB
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: Check Python Code
on:
workflow_call:
jobs:
check-python:
runs-on: "ubuntu-latest"
steps:
- name: Checkout source code
uses: actions/checkout@v6
- name: Set up Python 3.12
uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Set up uv
uses: ./.github/actions/setup-uv
with:
extra-sync-args: "--group docs"
- name: Audit with pip-audit
run: |
set -o pipefail
uv export --no-dev --no-group docs --no-emit-project -o requirements.txt
# CVE-2026-4539: low-severity ReDoS in pygments (transitive dep), no fix available as of 2026-03-27
uv run pip-audit -r requirements.txt --ignore-vuln CVE-2026-4539
- name: Check formatting with Ruff
run: uv run ruff format --check .
- name: Check linting with Ruff
run: uv run ruff check .
- name: Check types with mypy
run: uv run mypy
- name: Check docs are up to date
run: |
set -o pipefail
uv run poe docs-cli
[ $(git status --porcelain docs/ | wc -l) -eq "0" ]