Fix GitHub Actions workflow to support Python 3.6-3.14
Use Docker containers with official Python images to run tests across all Python versions from 3.6 to 3.14. This approach: - Eliminates "workers not found" errors from deprecated Ubuntu runners - Provides reliable support for older Python versions (3.6, 3.7) - Simplifies workflow configuration significantly - Uses official python:X.Y Docker images maintained by Python team - Sets fail-fast: false to test all versions independently
This commit is contained in:
parent
6839d21a77
commit
22933d7520
16
.github/workflows/run_tests.yml
vendored
16
.github/workflows/run_tests.yml
vendored
@ -3,21 +3,23 @@ name: Run tests
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-20.04
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: python:${{ matrix.python-version }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11"]
|
||||
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements-dev.txt
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
python -m pytest -v
|
||||
|
||||
Loading…
Reference in New Issue
Block a user