Update GitHub Actions in pre-release workflow #504
Workflow file for this run
This file contains hidden or 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: | |
| push: | |
| branches: | |
| - "*" | |
| pull_request: | |
| branches: | |
| - master | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} | |
| cancel-in-progress: true | |
| jobs: | |
| test: | |
| timeout-minutes: 30 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14", "3.14t"] | |
| os: [ubuntu-24.04] | |
| runs-on: ${{ matrix.os }} | |
| name: "${{ matrix.os }} Python: ${{ matrix.python-version }}" | |
| services: | |
| redis: | |
| image: redis:8.0-alpine | |
| ports: | |
| - 6379:6379 | |
| memcached: | |
| image: memcached:1.6-alpine | |
| ports: | |
| - 11211:11211 | |
| mysql: | |
| image: mysql:9.3.0 | |
| env: | |
| MYSQL_ALLOW_EMPTY_PASSWORD: yes | |
| ports: | |
| - 3306:3306 | |
| postgresql: | |
| image: postgis/postgis:17-3.5-alpine | |
| env: | |
| POSTGRES_HOST_AUTH_METHOD: trust | |
| ports: | |
| - 5432:5432 | |
| steps: | |
| - name: Install OS Packages | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install binutils libproj-dev gdal-bin libmemcached-dev libsqlite3-mod-spatialite | |
| - uses: actions/checkout@v5 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| pip install --upgrade "pip>=23.1.1" | |
| pip install --upgrade "tox-gh-actions==3.3.0" coverage | |
| - name: Log versions | |
| run: | | |
| python --version | |
| pip --version | |
| psql -V | |
| mysql -V | |
| - name: prep DB | |
| env: | |
| MYSQL_TCP_PORT: 3306 | |
| MYSQL_HOST: localhost | |
| PGHOST: localhost | |
| PGPORT: 5432 | |
| run: | | |
| psql --user postgres -c 'CREATE DATABASE postgis' | |
| psql --user postgres postgis -c 'CREATE EXTENSION IF NOT EXISTS postgis;' | |
| mysql --protocol=TCP --user=root -e 'create database django_prometheus_1;' | |
| - name: Run test and linters via Tox | |
| run: tox | |
| - name: Process code coverage | |
| run: | | |
| coverage combine .coverage django_prometheus/tests/end2end/.coverage | |
| coverage xml |