File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -286,6 +286,36 @@ jobs:
286286
287287 ${{ matrix.install_cmd }}
288288
289+ - name : Clear installer cache on failure
290+ if : failure()
291+ run : |
292+ INSTALL_CMD='${{ matrix.install_cmd }}'
293+
294+ if [[ "$INSTALL_CMD" == uv* || "$INSTALL_CMD" == *" uv "* ]]; then
295+ echo "[INFO] Previous install command uses uv, clearing uv cache..."
296+ uv cache clean
297+ elif [[ "$INSTALL_CMD" == pip* || "$INSTALL_CMD" == *" pip "* ]]; then
298+ echo "[INFO] Previous install command uses pip, clearing pip cache..."
299+ python -m pip cache purge || rm -rf ~/.cache/pip
300+ fi
301+ echo "RETRY_INSTALL=true" >> $GITHUB_ENV
302+
303+ - name : retry ${{ matrix.name }}
304+ if : env.RETRY_INSTALL == 'true'
305+ run : |
306+ uv venv "${{ matrix.env_name }}"
307+ source "${{ matrix.env_name }}/bin/activate"
308+ if [[ "${{ matrix.use_pip }}" == "true" ]]; then
309+ uv pip install pip -U
310+ fi
311+ if python -VV 2>&1 | grep -q '3\.14.*free-threading'; then
312+ echo "[INFO] Python 3.14t detected, installing torchao..."
313+ uv pip install http://10.0.13.31/files/torchao-0.18.0+git13cd013d6-cp314-cp314t-linux_x86_64.whl
314+ else
315+ echo "[INFO] Current Python is not 3.14t, skip torchao."
316+ fi
317+
318+ ${{ matrix.install_cmd }}
289319
290320 setuptools-compatibility :
291321 uses : ./.github/workflows/setuptools_compatibility_reusable.yml
You can’t perform that action at this time.
0 commit comments