Commit 0b827ec
committed
fix(ci): use vswhere to locate and activate MSVC for x86 on windows-2025
The x86 (32-bit) build fails at Install dependencies because packages
such as pyyaml and greenlet have no cp314-win32 wheels and must be
built from sdist, requiring a 32-bit MSVC toolchain.
Root cause on current runners:
- windows-2025 now ships Visual Studio 2026 (paths under
Microsoft Visual Studio\18\Enterprise, not 2022).
- Previous hardcoded "2022" discovery failed to locate vcvarsall.bat.
- ilammy/msvc-dev-cmd is Node-20 based and deprecated on Node 24.
Proper solution (standard in GitHub Actions + VS 2022/2026 CI):
- Use vswhere.exe (official locator) to dynamically find the current
installationPath (handles any VS version/edition).
- Activate with amd64_x86 (64-bit host tools for 32-bit target).
- Verify in logs (where cl + version output).
- Export env (PATH/INCLUDE/LIB) via GITHUB_ENV for uv sync --compile.
Implemented with pwsh + child cmd for vcvars (no external action).
Only this CI x86 fix; no dep changes.1 parent 2b8fbfa commit 0b827ec
1 file changed
Lines changed: 29 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
47 | 76 | | |
48 | 77 | | |
49 | 78 | | |
| |||
0 commit comments