Skip to content

Commit 159557b

Browse files
fix(mac-ci): isolate legacy integration deps from managed Python
Co-authored-by: FluffyAIcode <FluffyAIcode@users.noreply.github.com>
1 parent f20ae90 commit 159557b

1 file changed

Lines changed: 15 additions & 7 deletions

File tree

.github/workflows/integration.yaml

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -155,21 +155,29 @@ jobs:
155155
156156
- name: Install Python dependencies
157157
run: |
158-
# The runner is expected to have a long-lived venv.
159-
# If a per-run venv is preferred, swap to ``python3 -m venv .venv``.
160-
python3 -m pip install --upgrade pip
158+
# Keep the legacy Qwen/Transformers-4 suite isolated from both
159+
# Homebrew's PEP-668-managed system Python and the Transformers-5 MLX
160+
# production venv used by the preceding real-model gate.
161+
LEGACY_VENV="$HOME/.kakeya/integration-legacy-venv"
162+
if [ ! -x "$LEGACY_VENV/bin/python" ]; then
163+
mkdir -p "$(dirname "$LEGACY_VENV")"
164+
python3 -m venv "$LEGACY_VENV"
165+
fi
166+
LEGACY_PY="$LEGACY_VENV/bin/python"
167+
"$LEGACY_PY" -m pip install --upgrade pip
161168
# The repo runs via PYTHONPATH (see ci.yaml) — it is NOT a pip package
162169
# (no setup.py/pyproject.toml), so install runtime deps from
163170
# requirements.txt rather than an editable `-e .` (which errors with
164171
# "does not appear to be a Python project").
165-
python3 -m pip install -r requirements.txt
172+
"$LEGACY_PY" -m pip install -r requirements.txt
166173
# The integration suite exercises the legacy dllm-hub Qwen proposer,
167174
# whose remote modeling file depends on the Transformers 4.x
168175
# decoder_layer.attention_type API. Keep this runner in the dedicated
169176
# legacy range; K3/Gemma production paths use requirements.txt's
170177
# unbounded Transformers 5.x-compatible environment.
171-
python3 -m pip install 'transformers>=4.45,<5.0'
172-
python3 -m pip install pytest pytest-asyncio pytest-timeout coverage
178+
"$LEGACY_PY" -m pip install 'transformers>=4.45,<5.0'
179+
"$LEGACY_PY" -m pip install pytest pytest-asyncio pytest-timeout coverage
180+
echo "KAKEYA_INTEGRATION_PY=$LEGACY_PY" >> "$GITHUB_ENV"
173181
174182
- name: Run integration suite
175183
env:
@@ -180,7 +188,7 @@ jobs:
180188
run: |
181189
mkdir -p results/platform-tests
182190
stamp=$(date +%s)
183-
python3 -m pytest \
191+
"$KAKEYA_INTEGRATION_PY" -m pytest \
184192
-m integration \
185193
tests/integration/ \
186194
--junitxml="results/platform-tests/integration-mac-m4-${stamp}.junit.xml" \

0 commit comments

Comments
 (0)