Skip to content

docs: add CVE-2026-111497 Brotli note to README #156

docs: add CVE-2026-111497 Brotli note to README

docs: add CVE-2026-111497 Brotli note to README #156

Workflow file for this run

name: Tests
on:
push:
branches: [main, develop]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1
with:
version: 2.4.1
virtualenvs-create: true
virtualenvs-in-project: true
- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6
with:
path: .venv
key: venv-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}
- name: Install dependencies
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: poetry install --no-interaction --no-root
- name: Install project
run: poetry install --no-interaction
- name: Run tests with coverage
run: |
poetry run pytest --cov=postmark --cov-report=xml --cov-report=term --cov-fail-under=85
django-tests:
runs-on: ubuntu-latest
strategy:
matrix:
# Currently supported Django release series. The main `test` job above
# already exercises tests/django_backend/ against the pinned dev version
# (Django 5.2) across every supported Python version; this job additionally
# checks the Django backend against the rest of the support matrix.
django-version: ["4.2", "5.2", "6.0", "6.1"]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false
- name: Set up Python
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7
with:
# 3.12 is the one Python version every entry in the matrix supports:
# Django 4.2 added 3.12 support in 4.2.8; Django 6.0/6.1 require 3.12+.
python-version: "3.12"
- name: Install Poetry
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1
with:
version: 2.4.1
virtualenvs-create: true
virtualenvs-in-project: true
- name: Install dependencies
run: poetry install --no-interaction
- name: Install Django ${{ matrix.django-version }}
run: poetry run pip install "django~=${{ matrix.django-version }}.0"
- name: Run Django backend tests
run: poetry run pytest tests/django_backend/ -v
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false
- name: Set up Python
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7
with:
python-version: "3.14"
- name: Install Poetry
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1
with:
version: 2.4.1
virtualenvs-create: true
virtualenvs-in-project: true
- name: Install dependencies
run: |
poetry install --no-interaction --with dev
- name: Run Ruff lint
run: poetry run ruff check .
- name: Run Ruff format
run: poetry run ruff format --check .
- name: Run MyPy
run: poetry run mypy postmark/