Fix Python setup in LCK container builds (#1466)

## Summary

- disable `actions/setup-python`'s pip cache hook in the CUDA container
matrix jobs
- retain Python 3.12 setup and all dependency installation through
`python -m pip`
- keep pip caching enabled for the non-container wheel-packaging job

## Root cause

Post-merge run
[35030952199](https://github.com/linkedin/Liger-Kernel/actions/runs/35030952199)
failed before compilation in both architecture jobs. `setup-python`
installed CPython successfully, then its cache hook tried to execute
`/__t/Python/3.12.14/x64/bin/pip` inside the job container and failed
with `ENOENT`.

The cache is only an optimization and is incompatible with this
container/toolcache path layout. Removing `cache: pip` avoids the
failing hook; subsequent steps already use `python -m pip`.

## Validation

- workflow YAML parses with the container cache disabled and the host
packaging cache retained
- fork workflow run:
https://github.com/kolehma8/Liger-Kernel/actions/runs/35031510256

Co-authored-by: jkolehma <[email protected]>
Co-authored-by: Copilot <[email protected]>
This commit is contained in:
Jari Kolehmainen
2026-09-15 22:34:54 +00:00
committed by GitHub
co-authored by jkolehma Copilot
parent d72addc575
commit dc1512630d
@@ -42,11 +42,12 @@ jobs:
ref: 4370102f9dacab813282e1d67722fceb0b90a019
path: .release-deps/cutlass
# setup-python's pip cache helper cannot execute its host-toolcache pip
# launcher from inside a container job.
- name: Set up Python
uses: actions/setup-python@v7
with:
python-version: '3.12'
cache: pip
- name: Install build dependencies
run: |