Skip to content

Merge pull request #14 from RealDougEubanks/fix/startup-resilience #29

Merge pull request #14 from RealDougEubanks/fix/startup-resilience

Merge pull request #14 from RealDougEubanks/fix/startup-resilience #29

Workflow file for this run

name: CI
on:
push:
branches: [main, develop]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
lint-and-test:
name: Lint & Test (Python ${{ matrix.python-version }})
runs-on: ubuntu-latest
permissions:
contents: read
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: ${{ matrix.python-version }}
cache: pip
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt -r requirements-dev.txt
- name: Lint with ruff
run: ruff check src/ tests/
- name: Format check with black
run: black --check src/ tests/
- name: Type check with mypy
run: mypy src/ --ignore-missing-imports
continue-on-error: true # advisory only — doesn't fail the build
- name: Scan Python dependencies for vulnerabilities
run: |
pip install pip-audit
pip-audit -r requirements.txt --desc
- name: Security scan with bandit
run: |
pip install bandit
bandit -r src/ -c pyproject.toml || bandit -r src/ -s B101
continue-on-error: true # advisory — doesn't block the build
- name: Run tests with coverage
run: |
pytest tests/ -v \
--tb=short \
--cov=src \
--cov-report=term-missing \
--cov-report=xml \
--cov-fail-under=70
- name: Upload coverage report
uses: codecov/codecov-action@ad3126e916f78f00edff4ed0317cf185271ccc2d # v5.4.2
if: always() && matrix.python-version == '3.12'
with:
files: coverage.xml
fail_ci_if_error: false
token: ${{ secrets.CODECOV_TOKEN }}