Skip to content

CICD-036 · Test two Python releases ​

Encyclopedia · Matrices and sharding · All snippets

Previous · CICD-035 · Next · CICD-037

1. Where it fits ​

  • Placement .github/workflows/ci.yml, inside the relevant job.
  • Prerequisites workspace whose runtime dependencies match the chosen target combinations.
  • Platforms github-actions, gitea-actions.

2. Copy the snippet ​

yaml
strategy:
  matrix:
    python: ["3.11", "3.12"]

3. How it works ​

The matrix expands one job for each Python entry. The job needs a setup step using matrix.python to translate that entry into the real interpreter.

4. Verify the result ​

Install matrix.python in each job. Expect two independently visible results.

Validation syntax-validated (YAML parse). Status definitions.