Skip to content

Update Python tutorial matrix examples for Ubuntu 26.04 runners - #47080

Closed
aniruddhaadak80 wants to merge 1 commit into
github:mainfrom
aniruddhaadak80:fix/python-3-9-matrix
Closed

aniruddhaadak80 wants to merge 1 commit into
github:mainfrom
aniruddhaadak80:fix/python-3-9-matrix

Conversation

@aniruddhaadak80

Copy link
Copy Markdown
Contributor

Why:

Closes: #46993

What's being changed (if available, include any code snippets, screenshots, or gifs):

Four examples in the "Building and testing Python" tutorial listed 3.9 in a matrix running on ubuntu-latest. Because ubuntu-latest is moving to Ubuntu 26.04 and the actions/python-versions manifest has no 3.9 build for that image, those jobs fail at the setup-python step and, with default fail-fast, cancel the rest of the matrix.

This removes 3.9 from the four version lists and adds 3.14:

  • "Using multiple Python versions": ["pypy3.10", "3.10", "3.11", "3.12", "3.13", "3.14"]
  • "Excluding a version": ["3.11", "3.13", "3.14", "pypy3.10"] (the two exclude entries are unchanged)
  • "Running tests with tox": ["3.11", "3.13", "3.14"]
  • "Packaging workflow data as artifacts": ["3.10", "3.11", "3.12", "3.13", "3.14"]

It also updates the stale sample error (##[error]Version 3.7 with arch x64 not found, "includes the available versions") to the message format emitted by current setup-python and says the message links to the list of available versions.

Verification

  • npm ci --prefer-offline --no-audit --no-fund in the isolated worktree: succeeded (added 1044 packages), with EBADENGINE warnings because this machine has Node v22.23.2 while the repository requires Node ^26.
  • npm run lint-content -- --paths content/actions/tutorials/build-and-test-code/python.md: failed under Node v22 with TypeError: RegExp.escape is not a function.
  • Re-ran the same linter with a locally fetched Node v26.13.1: npx -y node@26 ./node_modules/tsx/dist/cli.mjs src/content-linter/scripts/lint-content.ts --paths content/actions/tutorials/build-and-test-code/python.md → Markdownlint finished in 108.8 s / No errors found.
  • Checked the error message format against actions/setup-python v5 src/find-python.ts and the available-version claim against actions/python-versions versions-manifest.json.

Limitations

  • The matrix examples were not re-run in GitHub Actions locally; the issue reporter states they ran the four examples on ubuntu-latest, macos-latest, and windows-latest with the updated lists.
  • The full site build and GitHub Actions CI were not run locally.
  • git push to the fork fails with HTTP 408 because the fork's main is 1161 commits behind upstream/main; the branch and its single-file commit were created directly on the fork with the GitHub REST API. The content is identical to the local commit.
  • No subject matter expert review has taken place; wording and version choices should be confirmed by a GitHub maintainer.

AI assistance disclosure

This change and PR body were prepared with AI assistance. The issue, the affected tutorial, setup-python source, and the versions manifest were checked before submission.

Check off the following:

  • A subject matter expert (SME) has reviewed the technical accuracy of the content in this PR. In most cases, the author can be the SME. Open source contributions may require an SME review from GitHub staff.
  • The changes in this PR meet the docs fundamentals that are required for all content.
  • All CI checks are passing and the changes look good in the review environment.

Copilot AI lite review requested due to automatic review settings November 26, 2026 15:32
@github-actions

Copy link
Copy Markdown
Contributor

Warning

This pull request was closed automatically.

Please don't raise pull requests against an existing issue that another user has raised until it's been marked with a help wanted label. We need to properly assess all issues before we can accept community contributions, and determine whether it's something we need to fix internally, or how many articles are affected and what the scope of the fix will be. For now, we're going to close this pull request.

@github-actions github-actions Bot closed this Nov 26, 2026
@github-actions github-actions Bot added the triage Do not begin working on this issue until triaged by the team label Nov 26, 2026
@github-actions

Copy link
Copy Markdown
Contributor

How to review these changes 👓

Thank you for your contribution. To review these changes, choose one of the following options:

A Hubber will need to deploy your changes internally to review.

Table of review links

Note: Please update the URL for your staging server or codespace.

The table shows the files in the content directory that were changed in this pull request. This helps you review your changes on a staging server. Changes to the data directory are not included in this table.

Source Review Production What Changed
actions/tutorials/build-and-test-code/python.md fpt
ghec
ghes@ 3.23 3.22 3.21 3.20 3.19
fpt
ghec
ghes@ 3.23 3.22 3.21 3.20 3.19

Key: fpt: Free, Pro, Team; ghec: GitHub Enterprise Cloud; ghes: GitHub Enterprise Server

🤖 This comment is automatically generated.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

Approval should wait for maintainer or SME confirmation because the four OS/version matrices were not executed and depend on changing runner, manifest, and Python 3.14 availability and error wording.

No open issues 🎉

What changed in this PR

Updates the Python build-and-test tutorial to keep its matrix examples compatible with Ubuntu 26.04 runners by replacing unavailable Python 3.9 entries with Python 3.14 and refreshing the setup-python error guidance.

Changes:

  • Replaces Python 3.9 with Python 3.14 in four workflow matrix examples.
  • Updates the unavailable-version error example for Ubuntu 26.04 and available Python versions.
File Description
content/​actions/​tutorials/​build-and-test-code/​python.md Updates Python version matrices and refreshes the setup-python unavailable-version error guidance.

Review effort: Lite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

triage Do not begin working on this issue until triaged by the team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Building and testing Python: the "3.9" matrix jobs fail on ubuntu-latest (Ubuntu 26.04)

2 participants