actions / setup-python

Set up your GitHub Actions workflow with a specific version of Python
MIT License
1.59k stars 505 forks source link

Python 3.13 fails to install on windows: Offset to Central Directory cannot be held in an Int64. #888

Open konstin opened 2 weeks ago

konstin commented 2 weeks ago

Description: The following used to work on windows but now fails:

- uses: actions/setup-python@v5
  with:
    python-version: "3.13"
    allow-prereleases: true
    cache: pip
   Version ~3.13.0-0 was not found in the local cache
  Version ~3.13.0-0 is available for downloading
  Download from "https://github.com/actions/python-versions/releases/download/3.13.0-beta.2-9442465578/python-3.13.0-beta.2-win32-x64.zip"
  Extract downloaded archive
  "C:\Program Files\PowerShell\7\pwsh.exe" -NoLogo -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command "$ErrorActionPreference = 'Stop' ; try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ; try { [System.IO.Compression.ZipFile]::ExtractToDirectory('D:\a\_temp\267e2789-454c-4fa7-a8f7-e25fb913c717', 'D:\a\_temp\c2ea4a3f-68d8-4c8a-a2ec-da68425c83eb', $true) } catch { if (($_.Exception.GetType().FullName -eq 'System.Management.Automation.MethodException') -or ($_.Exception.GetType().FullName -eq 'System.Management.Automation.RuntimeException') ){ Expand-Archive -LiteralPath 'D:\a\_temp\267e2789-454c-4fa7-a8f7-e25fb913c717' -DestinationPath 'D:\a\_temp\c2ea4a3f-68d8-4c8a-a2ec-da68425c83eb' -Force } else { throw $_ } } ;"
  Exception: Exception calling "ExtractToDirectory" with "3" argument(s): "Offset to Central Directory cannot be held in an Int64."
  Error: The process 'C:\Program Files\PowerShell\7\pwsh.exe' failed with exit code 1

Action version: actions/setup-python@v5

Platform:

Runner type:

Tools version: 3.13.0

Repro steps:
Failing job: https://github.com/astral-sh/uv/actions/runs/9447197607/job/26018697091 Workflow: https://github.com/astral-sh/uv/blob/4125cb26b804d1a0e4f095b8411bba819b089ad4/.github/workflows/ci.yml#L889-L903

Expected behavior: The installation works

Actual behavior:

Exception calling "ExtractToDirectory" with "3" argument(s): "Offset to Central Directory cannot be held in an Int64."
xqt commented 2 weeks ago

Python 3.13.0b2 also fails for Mac OS and Ubuntu, see https://phabricator.wikimedia.org/T367054

HarithaVattikuti commented 2 weeks ago

Hello @konstin Thankyou for creating this issue. we are working on the fix and will get back to you sooner.

aparnajyothi-y commented 2 weeks ago

Hello Everyone, we merged the fix for this issue. Please validate from your end and confirm.

xqt commented 2 weeks ago

LGTM, thanks a lot for this quick fix.