aman/.github/workflows/ci.yml
Thales Maciel dd2813340b Align CI with the validated Ubuntu support floor
Stop implying that one Ubuntu 3.11 unit lane validates the full Linux support surface Aman documents.\n\nSplit CI into an Ubuntu CPython 3.10/3.11/3.12 unit-package matrix, a portable install plus doctor smoke lane, and a packaging lane gated on both. Add a reproducible ci_portable_smoke.sh helper with fake systemctl coverage, and force the installer onto /usr/bin/python3 so the smoke path uses the distro-provided GI and X11 Python packages it is meant to validate.\n\nUpdate the README, release/distribution docs, and Debian metadata to distinguish the automated Ubuntu CI floor from broader manual GA signoff families, and add the missing AppIndicator introspection package to the Ubuntu/Debian dependency lists.\n\nValidate with python3 -m unittest discover -s tests -p 'test_*.py', python3 -m py_compile src/*.py tests/*.py, and bash -n scripts/ci_portable_smoke.sh. The full xvfb-backed smoke could not be run locally in this sandbox because xvfb-run is unavailable.
2026-03-14 15:45:21 -03:00

135 lines
4.1 KiB
YAML

name: ci
on:
push:
pull_request:
jobs:
unit-matrix:
name: Unit Matrix (${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Ubuntu runtime dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
gobject-introspection \
libcairo2-dev \
libgirepository1.0-dev \
libportaudio2 \
pkg-config \
python3-gi \
python3-xlib \
gir1.2-gtk-3.0 \
gir1.2-ayatanaappindicator3-0.1 \
libayatana-appindicator3-1
- name: Create project environment
run: |
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install uv build
uv sync --active --frozen
echo "${GITHUB_WORKSPACE}/.venv/bin" >> "${GITHUB_PATH}"
- name: Run compile check
run: python -m py_compile src/*.py tests/*.py
- name: Run unit and package-logic test suite
run: python -m unittest discover -s tests -p 'test_*.py'
portable-ubuntu-smoke:
name: Portable Ubuntu Smoke
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install Ubuntu runtime dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
gobject-introspection \
libcairo2-dev \
libgirepository1.0-dev \
libportaudio2 \
pkg-config \
python3-gi \
python3-xlib \
gir1.2-gtk-3.0 \
gir1.2-ayatanaappindicator3-0.1 \
libayatana-appindicator3-1 \
xvfb
- name: Create project environment
run: |
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install uv build
uv sync --active --frozen
echo "${GITHUB_WORKSPACE}/.venv/bin" >> "${GITHUB_PATH}"
- name: Run portable install and doctor smoke with distro python
env:
AMAN_CI_SYSTEM_PYTHON: /usr/bin/python3
run: bash ./scripts/ci_portable_smoke.sh
- name: Upload portable smoke logs
if: always()
uses: actions/upload-artifact@v4
with:
name: aman-portable-smoke-logs
path: build/ci-smoke
package-artifacts:
name: Package Artifacts
runs-on: ubuntu-latest
needs:
- unit-matrix
- portable-ubuntu-smoke
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install Ubuntu runtime dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
gobject-introspection \
libcairo2-dev \
libgirepository1.0-dev \
libportaudio2 \
pkg-config \
python3-gi \
python3-xlib \
gir1.2-gtk-3.0 \
gir1.2-ayatanaappindicator3-0.1 \
libayatana-appindicator3-1
- name: Create project environment
run: |
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install uv build
uv sync --active --frozen
echo "${GITHUB_WORKSPACE}/.venv/bin" >> "${GITHUB_PATH}"
- name: Prepare release candidate artifacts
run: make release-prep
- name: Upload packaging artifacts
uses: actions/upload-artifact@v4
with:
name: aman-artifacts
path: |
dist/*.whl
dist/*.tar.gz
dist/*.sha256
dist/SHA256SUMS
dist/*.deb
dist/arch/PKGBUILD
dist/arch/*.tar.gz