Use improved OpenAPI enums #737
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
merge_group: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
check: | |
runs-on: ubuntu-22.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
# use all supported versions from https://devguide.python.org/versions/ | |
python-version: ["3.8", "3.9", "3.10", "3.11"] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: APT update | |
run: sudo apt-get update | |
- name: Install system dependencies | |
run: sudo apt-get install libgeos-dev libproj-dev | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install build dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -e . | |
pip install -e .[dev] | |
- name: Check Formatting | |
run: | | |
python -m pycodestyle | |
- name: Lint code | |
run: | | |
python -m pylint geoengine | |
- name: Type-check code | |
run: | | |
python -m mypy geoengine | |
- name: Build | |
run: python -m build . | |
- name: Install test dependencies | |
run: | | |
pip install -e .[test] | |
- name: Lint tests | |
run: | | |
python -m pylint tests | |
- name: Type-check tests | |
run: | | |
python -m mypy tests | |
- name: Test | |
run: pytest | |
# Checks the library using minimum version resolution | |
# `uv` has this feature built-in, c.f. https://github.com/astral-sh/uv | |
check-min-version: | |
runs-on: ubuntu-22.04 | |
env: | |
# use minimum supported versions from https://devguide.python.org/versions/ | |
python-version: "3.8" | |
# lowest compatible versions for all direct dependencies | |
# cf., https://github.com/astral-sh/uv#resolution-strategy | |
resolution: "lowest-direct" | |
steps: | |
- uses: actions/checkout@v3 | |
- name: APT update | |
run: sudo apt-get update | |
- name: Install system dependencies | |
run: sudo apt-get install libgeos-dev libproj-dev | |
- name: Set up Python ${{ env.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ env.python-version }} | |
- name: Install build dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install uv | |
uv venv | |
source .venv/bin/activate | |
uv pip install --resolution=${{ env.resolution}} -e . | |
uv pip install --resolution=${{ env.resolution}} -e .[dev] | |
- name: Build | |
run: | | |
source .venv/bin/activate | |
python -m build . | |
- name: Install test dependencies | |
run: | | |
source .venv/bin/activate | |
uv pip install --resolution=${{ env.resolution}} -e .[test] | |
- name: Test | |
run: | | |
source .venv/bin/activate | |
pytest |