Skip to content

Add hybrid partitioning notebook #406

Add hybrid partitioning notebook

Add hybrid partitioning notebook #406

Workflow file for this run

name: Python package
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
name: Build and test for (${{ matrix.python-version }}, ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: ${{ github.event.pull_request.draft && fromJSON('["ubuntu-latest"]') || fromJSON('["ubuntu-latest", "windows-latest"]') }}
python-version: ${{ github.event.pull_request.draft && fromJSON('["3.12"]') || fromJSON('["3.11", "3.12", "3.13"]') }}
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install build
python -m pip install .[dev]
- name: Run unit tests
run: |
python -c "import pcse"
pytest --fast -v -n auto
- name: Verify that we can build the package
run: python -m build
lint:
name: Linting with ruff
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[dev]
- name: Check style against standards using ruff
run: |
ruff check
ruff format --check
docs:
name: Build documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[docs]
- name: Build documentation with mkdocs
run: mkdocs build