Skip to content

[STY] run isort rules via ruff/pre-commit #103

[STY] run isort rules via ruff/pre-commit

[STY] run isort rules via ruff/pre-commit #103

Workflow file for this run

name: CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
workflow_dispatch:
jobs:
linter-check:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python "3.10"
uses: actions/setup-python@v5
with:
python-version: "3.12"
- uses: pre-commit/[email protected]
makedocs:
name: build documentation
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get history and tags for SCM versioning to work
run: |
git fetch --prune --unshallow
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install dependencies
shell: bash -l {0}
run: |
python -m pip install --upgrade pip
python -m pip install .[optional,doc]
- name: Build API documentation
run: make -C docs html
test-suite:
runs-on: ${{ matrix.os }}
needs: linter-check
strategy:
fail-fast: true
matrix:
os: [ubuntu-latest]
python-version: ["3.12", "3.11", "3.10", "3.9"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
shell: bash
run: |
python --version
python -m pip install --upgrade pip
python -m pip install .[test,optional]
- name: Run Tests
shell: bash
run: |
pytest -n auto -x