From 518e03801097cbbbda848df5c7f7cc5c13e452e6 Mon Sep 17 00:00:00 2001 From: Yusuke Watanabe Date: Wed, 22 Jul 2026 17:58:33 +0900 Subject: [PATCH] fix(pytest-matrix): seed pip into the uv venv MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `uv venv` installs no pip/setuptools/wheel, so any test that shells out to `sys.executable -m pip` fails with "No module named pip". The per-repo workflows this reusable replaced all built their env with actions/setup-python + `pip install`, so pip was always present — this is an unintended regression of the CI unification, not a test bug. Caught by scitex-ai/scitex-hub#433: its pip-install e2e gate (proving the production `pip_install_user_app` --no-deps --target argv shape) went red on all three legs while passing on develop's retired workflow. Runner evidence: `.venv/bin/python: No module named pip`. --- .github/workflows/pytest-matrix.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pytest-matrix.yml b/.github/workflows/pytest-matrix.yml index b9cb439..5adf756 100644 --- a/.github/workflows/pytest-matrix.yml +++ b/.github/workflows/pytest-matrix.yml @@ -33,7 +33,16 @@ jobs: - name: Install (.[all,dev]) + pytest run: | set -euo pipefail - uv venv --python ${{ matrix.python-version }} .venv + # --seed puts pip/setuptools/wheel IN the venv. A bare `uv venv` + # ships none of them, so any test that shells out to + # `sys.executable -m pip ...` gets "No module named pip". That is + # a regression against the per-repo workflows this reusable + # replaced: they all built the env with actions/setup-python + + # `pip install`, so pip was always present. + # Caught by scitex-hub PR #433 — its pip-install e2e gate proves + # the production `pip_install_user_app` argv shape and went red + # on exactly this. + uv venv --seed --python ${{ matrix.python-version }} .venv uv pip install --python .venv/bin/python -e ".[all,dev]" \ || uv pip install --python .venv/bin/python -e ".[dev]" \ || uv pip install --python .venv/bin/python -e .