Repository navigation
74 lines (61 loc) · 1.73 KB
/
Copy pathci.yml
File metadata and controls
74 lines (61 loc) · 1.73 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: CI
on:
push:
branches: ["**"]
pull_request:
permissions:
contents: read
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: ${{ matrix.os }} / Python ${{ matrix.python }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
python: "3.13"
- os: ubuntu-latest
python: "3.11"
- os: ubuntu-latest
python: "3.13"
env:
QT_QPA_PLATFORM: offscreen
PYTHONUTF8: "1"
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
cache: pip
cache-dependency-path: |
pyproject.toml
requirements.txt
- name: Install Qt system libraries
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends \
libegl1 libgl1 libxkbcommon0 libfontconfig1 libdbus-1-3 libpulse0
- name: Install project
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[dev]"
- name: Check syntax
run: python -m compileall -q src tests scripts
- name: Check imports
run: python scripts/check_package.py imports
- name: Ruff lint
run: python -m ruff check src tests scripts
- name: Ruff format
run: python -m ruff format --check src tests scripts
- name: Tests
run: python -m pytest -q
- name: Build and validate packages
run: |
python -m build
python scripts/check_package.py wheel "$(ls dist/*.whl)"
shell: bash