Skip to content

CI: pin ubuntu-24.04 in test matrices; report pip output on #require failures - #111

Merged
yannrichet merged 1 commit into
mainfrom
claude/ci-ubuntu-2404
Nov 7, 2026
Merged

yannrichet merged 1 commit into
mainfrom
claude/ci-ubuntu-2404

Conversation

@yannrichet

Copy link
Copy Markdown
Member

Pull Request

Description

GitHub's ubuntu-latest runner image moved to Ubuntu 26.04 overnight. On main (0b8514c, a NEWS-only change), two ci.yml jobs now fail, again after one re-run. Both passed on Ubuntu 24.04 the day before (#108).

  • Ubuntu + Python 3.9: The version '3.9' with architecture 'x64' was not found for Ubuntu 26.04.
  • Ubuntu + Python 3.14: test_demos.py::test_load_algorithm_with_auto_install fails in pip install six with an empty Error:.

release.yml's verify job uses the same matrix, so publishing 2.0 is blocked until this is fixed.

Related Issues

Relates to #110 (move back to Ubuntu 26.04: Python 3.9, and diagnosing pip on 3.14). This PR is the short-term mitigation plus the fix that makes the 3.14 cause visible.

Type of Change

  • Bug fix (error message of the #require: auto-install)
  • Test addition/modification
  • CI configuration

Changes Made

  • ci.yml, release.yml: the OS × Python test/verify matrices use ubuntu-24.04 instead of ubuntu-latest. This is the environment in which everything was green the day before, and the supported versions do not change. Non-matrix jobs (lint, build, publish) keep ubuntu-latest with Python 3.11, which is available there.
  • fz/algorithms.py: the algorithm #require: auto-install ran subprocess.check_call([... pip install pkg], stdout=DEVNULL, stderr=PIPE). check_call never reads that pipe, so CalledProcessError.stderr was always None and the RuntimeError always ended with an empty Error:. A long pip output could also fill the pipe and block. pip now runs through subprocess.run(capture_output=True, text=True), and the message ends with the last lines of pip's stderr, else its stdout, or states the exit status when pip printed nothing.
  • tests/test_algorithm_require_errors.py (3 tests, subprocess.run mocked): stderr is reported, stdout is used when stderr is empty, and a silent failure states its status. All three fail on main and pass with the fix.
  • NEWS.md: one entry in the 2.0 "Robustness" section (the 2.0 tag does not exist yet).

Testing Performed

  • New tests: fail on main (3 failed), pass with the fix (3 passed).
  • tests/test_demos.py, including the real auto-install of six: passes.
  • Real (unmocked) pip failure on a missing package: the message now ends with ERROR: No matching distribution found for fz_surely_missing_pkg_110; before, it was Error: with nothing after it.
  • test_python_version_support, test_check_dist, test_skill_static, test_docs_consistency: 31 passed. The CI's blocking flake8 check: 0 errors. Both workflow YAMLs parse.
  • release.yml is not run by this PR's CI; after merging, main's CI and the release's verify job will use ubuntu-24.04.

Generated by Claude Code

…failures (#110)

GitHub's ubuntu-latest image moved to Ubuntu 26.04: setup-python has no
Python 3.9 there, and test_load_algorithm_with_auto_install fails on 3.14
(pip install six). Both jobs fail on main (0b8514c, NEWS-only change) and
again on re-run; they passed on Ubuntu 24.04 the day before.

- ci.yml and release.yml test/verify matrices: ubuntu-24.04 instead of
  ubuntu-latest, until #110 is handled (release.yml's verify job would
  otherwise block a release).
- fz/algorithms.py: the #require auto-install ran pip with check_call(...,
  stderr=PIPE), which never reads the pipe, so the RuntimeError always ended
  with an empty "Error:". pip now runs with subprocess.run(capture_output=
  True); the message ends with the last lines of its stderr, else stdout, or
  states its exit status when it printed nothing.
- tests/test_algorithm_require_errors.py (3 tests, fail before the fix).
- NEWS (2.0, Robustness).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RjXvVRjM6aMvKvvSFoxpZ6
@yannrichet
yannrichet merged commit a6b2f26 into main Nov 7, 2026
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants