Skip to content

Bump fastmcp from 2.14.2 to 3.2.0 #1102

Bump fastmcp from 2.14.2 to 3.2.0

Bump fastmcp from 2.14.2 to 3.2.0 #1102

name: Contract Tests
on:
- push
- pull_request
jobs:
contract-tests:
name: Validate and test the contract of fastgeoapi against the generated pygeoapi OpenAPI document
runs-on: ubuntu-latest
steps:
- name: Check out the repository
uses: actions/[email protected]
- name: Set up Python 3.12
uses: actions/[email protected]
with:
python-version: "3.12"
- name: Upgrade pip
run: |
python -m pip install pip==25.1.1
pip --version
- name: Upgrade pip in virtual environments
shell: python
run: |
import os
import pip
with open(os.environ["GITHUB_ENV"], mode="a") as io:
print(f"VIRTUALENV_PIP={pip.__version__}", file=io)
- name: Install UV
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
cache-dependency-glob: "pyproject.toml"
version: "0.10.9"
- name: Install GDAL
run: |
sudo apt-add-repository ppa:ubuntugis/ubuntugis-unstable
sudo apt-get update
sudo apt-get install gdal-bin libgdal-dev
- name: Install fastgeoapi and run the server with API-KEY protection
env:
ENV_STATE: dev
OPA_ENABLED: false
API_KEY_ENABLED: true
JWKS_ENABLED: false
UV_SYSTEM_PYTHON: 1
UV_BREAK_SYSTEM_PACKAGES: 1
run: |
uv pip install -e . --break-system-packages
uv pip install --group dev --break-system-packages
ENV_STATE=$ENV_STATE
OPA_ENABLED=$OPA_ENABLED
API_KEY_ENABLED=$API_KEY_ENABLED
JWKS_ENABLED=$JWKS_ENABLED
uvicorn app.main:app --host 0.0.0.0 --port 5002 --reload --loop asyncio &
- name: Run API-KEY contract tests
run: |
uv run pytest tests/test_openapi_contract.py -vv
env:
API_KEY_ENABLED: true
JWKS_ENABLED: false
UV_SYSTEM_PYTHON: 1
UV_BREAK_SYSTEM_PACKAGES: 1
- name: Stop the API-KEY server
run: |
pkill -f "uvicorn app.main:app"
sleep 2
- name: Run the server with OAuth2/JWKS protection
env:
ENV_STATE: dev
OPA_ENABLED: false
API_KEY_ENABLED: false
JWKS_ENABLED: true
UV_SYSTEM_PYTHON: 1
UV_BREAK_SYSTEM_PACKAGES: 1
run: |
ENV_STATE=$ENV_STATE
OPA_ENABLED=$OPA_ENABLED
API_KEY_ENABLED=$API_KEY_ENABLED
JWKS_ENABLED=$JWKS_ENABLED
uvicorn app.main:app --host 0.0.0.0 --port 5002 --reload --loop asyncio &
sleep 5
- name: Run OAuth2/JWKS contract tests
run: |
uv run pytest tests/test_openapi_contract.py -vv
env:
API_KEY_ENABLED: false
JWKS_ENABLED: true
UV_SYSTEM_PYTHON: 1
UV_BREAK_SYSTEM_PACKAGES: 1