Skip to content

ci: bump timeout to 90m, add pytest-timeout, bump v1.3.4 #20

ci: bump timeout to 90m, add pytest-timeout, bump v1.3.4

ci: bump timeout to 90m, add pytest-timeout, bump v1.3.4 #20

Workflow file for this run

name: Publish to PyPI
on:
push:
tags:
- "v*"
jobs:
quality:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.11"
- name: Install package with dev dependencies
run: pip install -e ".[dev]"
- name: Lint (ruff)
run: ruff check lfm/ tests/
- name: Format check (ruff-format)
run: ruff format --check lfm/ tests/
test:
needs: quality
runs-on: ${{ matrix.os }}
timeout-minutes: 90
strategy:
fail-fast: true
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install package with dev dependencies
run: pip install -e ".[dev]"
- name: Run tests
run: pytest -m "not slow" --timeout=120 --cov=lfm --cov-report=term-missing
publish:
needs: test
runs-on: ubuntu-latest
permissions:
id-token: write # Required for trusted publishing
steps:
- uses: actions/checkout@v5
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install build tools
run: pip install build
- name: Build package
run: python -m build
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1