From d936aeca20ed75502e6881fca13b844fc90f0cf6 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Mon, 6 Jan 2025 01:18:43 +0530 Subject: [PATCH 01/25] added aarch64 runner for windows --- .github/workflows/ci.yml | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0f2248890df4..29225454efd4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,7 +9,7 @@ on: concurrency: group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.event.pull_request.number || github.sha }} cancel-in-progress: true - +build-binary env: CARGO_INCREMENTAL: 0 CARGO_NET_RETRY: 10 @@ -526,7 +526,7 @@ jobs: path: ./target/debug/uv retention-days: 1 - build-binary-windows: + build-binary-windows-x86_64: needs: determine_changes timeout-minutes: 10 if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} @@ -559,6 +559,39 @@ jobs: path: ${{ env.UV_WORKSPACE }}/target/debug/uv.exe retention-days: 1 + build-binary-windows-aarch64: + needs: determine_changes + timeout-minutes: 10 + if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} + runs-on: + labels: github-windows-11-aarch64-4 + name: "build binary | windows aarch64" + steps: + - uses: actions/checkout@v4 + + - name: Create Dev Drive using ReFS + run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1 + + # actions/checkout does not let us clone into anywhere outside ${{ github.workspace }}, so we have to copy the clone... + - name: Copy Git Repo to Dev Drive + run: | + Copy-Item -Path "${{ github.workspace }}" -Destination "${{ env.UV_WORKSPACE }}" -Recurse + + - uses: Swatinem/rust-cache@v2 + with: + workspaces: ${{ env.UV_WORKSPACE }} + + - name: "Build" + working-directory: ${{ env.UV_WORKSPACE }} + run: cargo build --target aarch64-pc-windows-msvc + + - name: "Upload binary" + uses: actions/upload-artifact@v4 + with: + name: uv-windows-${{ github.sha }} + path: ${{ env.UV_WORKSPACE }}/target/debug/uv.exe + retention-days: 1 + cargo-build-msrv: name: "cargo build (msrv)" needs: determine_changes From 76aa6d8a5d94bd473310eb6d9ca9709928177d62 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Sun, 5 Jan 2025 13:58:24 -0600 Subject: [PATCH 02/25] Empty commit From 0aef71c120f87a2c08d37c6bbc1479181aba6b72 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Mon, 6 Jan 2025 01:35:22 +0530 Subject: [PATCH 03/25] fixed typo. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 29225454efd4..02dce85cf2c6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,7 +9,7 @@ on: concurrency: group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.event.pull_request.number || github.sha }} cancel-in-progress: true -build-binary + env: CARGO_INCREMENTAL: 0 CARGO_NET_RETRY: 10 From 027cdbd46d5c2179aeffe8cfd7886dc51bb2cbc1 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Mon, 6 Jan 2025 01:37:32 +0530 Subject: [PATCH 04/25] rename build-binary-windows-x86 back to build-binary-windows --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 02dce85cf2c6..8f4ba77a4da9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -526,7 +526,7 @@ jobs: path: ./target/debug/uv retention-days: 1 - build-binary-windows-x86_64: + build-binary-windows: needs: determine_changes timeout-minutes: 10 if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} From 423b77b46f1e55d67399ead80824ec221316bd49 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Mon, 6 Jan 2025 01:41:52 +0530 Subject: [PATCH 05/25] removed dev drive from build-binary-windows-aarch64 --- .github/workflows/ci.yml | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8f4ba77a4da9..f7b307d1ad09 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -569,27 +569,16 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Create Dev Drive using ReFS - run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1 - - # actions/checkout does not let us clone into anywhere outside ${{ github.workspace }}, so we have to copy the clone... - - name: Copy Git Repo to Dev Drive - run: | - Copy-Item -Path "${{ github.workspace }}" -Destination "${{ env.UV_WORKSPACE }}" -Recurse - - uses: Swatinem/rust-cache@v2 - with: - workspaces: ${{ env.UV_WORKSPACE }} - name: "Build" - working-directory: ${{ env.UV_WORKSPACE }} run: cargo build --target aarch64-pc-windows-msvc - name: "Upload binary" uses: actions/upload-artifact@v4 with: name: uv-windows-${{ github.sha }} - path: ${{ env.UV_WORKSPACE }}/target/debug/uv.exe + path: target/debug/uv.exe retention-days: 1 cargo-build-msrv: From 17b5a7c9e2f75a1ffeaa497a25ee2771f00f0695 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Mon, 6 Jan 2025 01:56:35 +0530 Subject: [PATCH 06/25] added explict step to install rust in `build-binary-windows-aarch64` --- .github/workflows/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f7b307d1ad09..fa45e31c914a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -568,6 +568,11 @@ jobs: name: "build binary | windows aarch64" steps: - uses: actions/checkout@v4 + + - name: Install Rust + uses: dtolnay/rust-toolchain@stable + with: + targets: aarch64-pc-windows-msvc - uses: Swatinem/rust-cache@v2 From e21da45af032ec99fb3fea6fc1bc414f1ccf6c56 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 09:20:11 +0530 Subject: [PATCH 07/25] added llvm, rust and git to aarch64 flow --- .github/workflows/ci.yml | 43 ++++++++++++++++++++++++++++++++++------ 1 file changed, 37 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fa45e31c914a..71e2b6064798 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -567,17 +567,48 @@ jobs: labels: github-windows-11-aarch64-4 name: "build binary | windows aarch64" steps: - - uses: actions/checkout@v4 - - - name: Install Rust - uses: dtolnay/rust-toolchain@stable + - name: Download LLVM (aarch64) + uses: robinraju/release-downloader@v1 + with: + repository: 'llvm/llvm-project' + tag: 'llvmorg-19.1.5' + filename: 'LLVM-19.1.5-woa64.exe' + + - name: Install LLVM (aarch64) + run: | + Start-Process -FilePath "LLVM-19.1.5-woa64.exe" -ArgumentList '/S' -NoNewWindow -Wait + + - name: Install Build Tools (aarch64) + run: | + Set-ExecutionPolicy Bypass -Scope Process -Force + [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 + iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) + Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621" + + - name: Install Nightly Rust (aarch64) + run: | + Add-Content -Path $env:GITHUB_PATH -Value "$env:USERPROFILE\.cargo\bin" -Encoding utf8 + Invoke-WebRequest -Uri "https://win.rustup.rs/aarch64" -OutFile "$env:RUNNER_TEMP\rustup-init.exe" + & "$env:RUNNER_TEMP\rustup-init.exe" --default-host aarch64-pc-windows-msvc --default-toolchain nightly -y + + - name: Download Git for Windows (aarch64) + uses: robinraju/release-downloader@v1 with: - targets: aarch64-pc-windows-msvc + repository: 'git-for-windows/git' + tag: 'v2.48.0-rc1.windows.1' + filename: 'Git-2.48.0-rc1-arm64.exe' + + - name: Install Git for Windows (aarch64) + run: | + Start-Process -FilePath "Git-2.48.0-rc1-arm64.exe" -ArgumentList "/VERYSILENT" -NoNewWindow -Wait + Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\cmd" -Encoding utf8 + Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\bin" -Encoding utf8 - uses: Swatinem/rust-cache@v2 - name: "Build" - run: cargo build --target aarch64-pc-windows-msvc + run: cargo build -vv --target aarch64-pc-windows-msvc - name: "Upload binary" uses: actions/upload-artifact@v4 From eb8b60c8817ee1b74808b983756992bb32c9f4ef Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 09:35:25 +0530 Subject: [PATCH 08/25] added back checkout process --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 71e2b6064798..f8088d06af2d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -607,6 +607,8 @@ jobs: - uses: Swatinem/rust-cache@v2 + - uses: actions/checkout@v4 + - name: "Build" run: cargo build -vv --target aarch64-pc-windows-msvc From c45f762cb1b6dc0a0b0afaf583f3af79f242b69a Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 09:47:37 +0530 Subject: [PATCH 09/25] increased timeout for `build-binary-windows-aarch64` --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f8088d06af2d..f9c2d58ee861 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -561,7 +561,7 @@ jobs: build-binary-windows-aarch64: needs: determine_changes - timeout-minutes: 10 + timeout-minutes: 30 if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} runs-on: labels: github-windows-11-aarch64-4 From b1544211e09dd659ae718f9e66a5b8f2a341534f Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 10:13:49 +0530 Subject: [PATCH 10/25] added clang to `build-binary-windows-aarch64` --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f9c2d58ee861..bee1d1e761d4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,7 +584,7 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang" - name: Install Nightly Rust (aarch64) run: | From c5532df24e42f2f533f23d0a6637c57a62f858bf Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 11:08:31 +0530 Subject: [PATCH 11/25] added cmake and other tools --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bee1d1e761d4..eb5044e2becf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,7 +584,7 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" - name: Install Nightly Rust (aarch64) run: | From 11c28dc11b641f4b127e767c0740b396a6731162 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 11:40:52 +0530 Subject: [PATCH 12/25] added more tools to visualstudio in `Install Build Tools (aarch64)` --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index eb5044e2becf..95d584b01c22 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,7 +584,7 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Llvm.Clang --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset --add Microsoft.VisualStudio.Component.VC.CMake.Project --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATL.ARM --add Microsoft.VisualStudio.Component.VC.ASAN" - name: Install Nightly Rust (aarch64) run: | From 6331143cbf2fe4ccb62abef1c1f1e32738d448ef Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 11:46:57 +0530 Subject: [PATCH 13/25] prettier fixes --- .github/workflows/ci.yml | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95d584b01c22..11f514b43a90 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -570,21 +570,32 @@ jobs: - name: Download LLVM (aarch64) uses: robinraju/release-downloader@v1 with: - repository: 'llvm/llvm-project' - tag: 'llvmorg-19.1.5' - filename: 'LLVM-19.1.5-woa64.exe' - + repository: "llvm/llvm-project" + tag: "llvmorg-19.1.5" + filename: "LLVM-19.1.5-woa64.exe" + - name: Install LLVM (aarch64) run: | Start-Process -FilePath "LLVM-19.1.5-woa64.exe" -ArgumentList '/S' -NoNewWindow -Wait - + - name: Install Build Tools (aarch64) run: | Set-ExecutionPolicy Bypass -Scope Process -Force [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Llvm.Clang --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset --add Microsoft.VisualStudio.Component.VC.CMake.Project --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATL.ARM --add Microsoft.VisualStudio.Component.VC.ASAN" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "^ + --add Microsoft.VisualStudio.Component.VC.Tools.ARM64 ^ + --add Microsoft.VisualStudio.Component.Windows11SDK.22621 ^ + --add Microsoft.VisualStudio.Workload.VCTools ^ + --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 ^ + --add Microsoft.VisualStudio.Component.VC.Llvm.Clang ^ + --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang ^ + --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset ^ + --add Microsoft.VisualStudio.Component.VC.CMake.Project ^ + --add Microsoft.VisualStudio.Component.VC.ATL ^ + --add Microsoft.VisualStudio.Component.VC.ATL.ARM ^ + --add Microsoft.VisualStudio.Component.VC.ASAN" - name: Install Nightly Rust (aarch64) run: | @@ -595,10 +606,10 @@ jobs: - name: Download Git for Windows (aarch64) uses: robinraju/release-downloader@v1 with: - repository: 'git-for-windows/git' - tag: 'v2.48.0-rc1.windows.1' - filename: 'Git-2.48.0-rc1-arm64.exe' - + repository: "git-for-windows/git" + tag: "v2.48.0-rc1.windows.1" + filename: "Git-2.48.0-rc1-arm64.exe" + - name: Install Git for Windows (aarch64) run: | Start-Process -FilePath "Git-2.48.0-rc1-arm64.exe" -ArgumentList "/VERYSILENT" -NoNewWindow -Wait From ead622d734b6bd6234bcf36d940d4a5d77a8340c Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 11:53:12 +0530 Subject: [PATCH 14/25] fixed multiline bug --- .github/workflows/ci.yml | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 11f514b43a90..4a9fe7792127 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,18 +584,7 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "^ - --add Microsoft.VisualStudio.Component.VC.Tools.ARM64 ^ - --add Microsoft.VisualStudio.Component.Windows11SDK.22621 ^ - --add Microsoft.VisualStudio.Workload.VCTools ^ - --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 ^ - --add Microsoft.VisualStudio.Component.VC.Llvm.Clang ^ - --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang ^ - --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset ^ - --add Microsoft.VisualStudio.Component.VC.CMake.Project ^ - --add Microsoft.VisualStudio.Component.VC.ATL ^ - --add Microsoft.VisualStudio.Component.VC.ATL.ARM ^ - --add Microsoft.VisualStudio.Component.VC.ASAN" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Llvm.Clang --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset --add Microsoft.VisualStudio.Component.VC.CMake.Project --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATL.ARM --add Microsoft.VisualStudio.Component.VC.ASAN" - name: Install Nightly Rust (aarch64) run: | From 1ee07c9eb2e78ebd3d38f3194b3123136d6f8e87 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Tue, 7 Jan 2025 12:24:24 +0530 Subject: [PATCH 15/25] added clang path and check --- .github/workflows/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4a9fe7792127..35b69d610797 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -586,6 +586,11 @@ jobs: Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Llvm.Clang --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset --add Microsoft.VisualStudio.Component.VC.CMake.Project --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATL.ARM --add Microsoft.VisualStudio.Component.VC.ASAN" + - name: Add clang to PATH and check if clang exists + run: | + $env:PATH += ";C:\Program Files\Microsoft Visual Studio\2022\BuildTools\Llvm\ARM64\bin\" + clang --version + - name: Install Nightly Rust (aarch64) run: | Add-Content -Path $env:GITHUB_PATH -Value "$env:USERPROFILE\.cargo\bin" -Encoding utf8 From 7ada457d95facf9ae6c4f7f007093b5478e1519f Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 08:11:58 +0530 Subject: [PATCH 16/25] - fixed clang path - fixed uv.exe path - fixed git upload name - removed unused tools from vs install step --- .github/workflows/ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 35b69d610797..dd2b12aa129f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,11 +584,11 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Llvm.Clang --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset --add Microsoft.VisualStudio.Component.VC.CMake.Project --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATL.ARM --add Microsoft.VisualStudio.Component.VC.ASAN" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang" - name: Add clang to PATH and check if clang exists run: | - $env:PATH += ";C:\Program Files\Microsoft Visual Studio\2022\BuildTools\Llvm\ARM64\bin\" + $env:PATH += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" clang --version - name: Install Nightly Rust (aarch64) @@ -615,13 +615,13 @@ jobs: - uses: actions/checkout@v4 - name: "Build" - run: cargo build -vv --target aarch64-pc-windows-msvc + run: cargo build --target aarch64-pc-windows-msvc - name: "Upload binary" uses: actions/upload-artifact@v4 with: - name: uv-windows-${{ github.sha }} - path: target/debug/uv.exe + name: uv-windows-aarch64-${{ github.sha }} + path: target/aarch64-pc-windows-msvc/debug/uv.exe retention-days: 1 cargo-build-msrv: From cdccfd1010e4b308d130ad3354a8c0125b5cf24e Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 10:01:43 +0530 Subject: [PATCH 17/25] added cmake and cmake to path --- .github/workflows/ci.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dd2b12aa129f..27784b0ea402 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -584,12 +584,17 @@ jobs: [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang" + choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" - name: Add clang to PATH and check if clang exists run: | $env:PATH += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" clang --version + + - name: Add cmake to PATH and check if cmake exists + run: | + $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" + cmake --version - name: Install Nightly Rust (aarch64) run: | From 4927f9e277cf3aeaa15eac01021bd8c064adb4d5 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 10:46:46 +0530 Subject: [PATCH 18/25] replaced path with GITHUB_PATH --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 27784b0ea402..2608565798d4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -588,12 +588,12 @@ jobs: - name: Add clang to PATH and check if clang exists run: | - $env:PATH += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" + "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" >> $env:GITHUB_PATH clang --version - name: Add cmake to PATH and check if cmake exists run: | - $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" + "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" >> $env:GITHUB_PATH cmake --version - name: Install Nightly Rust (aarch64) From 8af24733c3c75353ce7789546f68901f5bc73f80 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 11:04:19 +0530 Subject: [PATCH 19/25] changed way to add to github path --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2608565798d4..dfcfd7770f67 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -588,12 +588,12 @@ jobs: - name: Add clang to PATH and check if clang exists run: | - "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" >> $env:GITHUB_PATH + Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" -Encoding utf8 clang --version - name: Add cmake to PATH and check if cmake exists run: | - "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" >> $env:GITHUB_PATH + Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin" -Encoding utf8 cmake --version - name: Install Nightly Rust (aarch64) From 6f45ee47eb768bff9acec78705bbd95c7302dc94 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 11:17:33 +0530 Subject: [PATCH 20/25] enforced path before cargo build --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dfcfd7770f67..96a821e4a81c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -588,11 +588,13 @@ jobs: - name: Add clang to PATH and check if clang exists run: | + $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" -Encoding utf8 clang --version - name: Add cmake to PATH and check if cmake exists run: | + $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin" -Encoding utf8 cmake --version @@ -620,7 +622,7 @@ jobs: - uses: actions/checkout@v4 - name: "Build" - run: cargo build --target aarch64-pc-windows-msvc + run: $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin"; $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\"; cargo build --target aarch64-pc-windows-msvc - name: "Upload binary" uses: actions/upload-artifact@v4 From 1c5d5640fdccaa74e57381083b63eacc477a5be1 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Wed, 8 Jan 2025 11:10:55 -0600 Subject: [PATCH 21/25] Prettier --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 96a821e4a81c..7e1c694a0e60 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -591,7 +591,7 @@ jobs: $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" -Encoding utf8 clang --version - + - name: Add cmake to PATH and check if cmake exists run: | $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" From 0289e96deb99e39ec4cd2c7ef2be915d9a381707 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Wed, 8 Jan 2025 11:27:05 -0600 Subject: [PATCH 22/25] Move rust-cache step to after checkout --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7e1c694a0e60..53c07974e081 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -582,7 +582,7 @@ jobs: run: | Set-ExecutionPolicy Bypass -Scope Process -Force [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 - iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) + iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" @@ -617,10 +617,10 @@ jobs: Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\cmd" -Encoding utf8 Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\bin" -Encoding utf8 - - uses: Swatinem/rust-cache@v2 - - uses: actions/checkout@v4 + - uses: Swatinem/rust-cache@v2 + - name: "Build" run: $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin"; $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\"; cargo build --target aarch64-pc-windows-msvc From 3a5469e99703c625d2ed8ffc0b564f1400b22a76 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Wed, 8 Jan 2025 11:29:21 -0600 Subject: [PATCH 23/25] Display choco cache --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 53c07974e081..658f44383b82 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -585,6 +585,7 @@ jobs: iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" + choco cache list -v - name: Add clang to PATH and check if clang exists run: | From b316c95c6dff22d9856efef8a3bc60e4fcf97948 Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Wed, 8 Jan 2025 23:52:45 +0530 Subject: [PATCH 24/25] added tests for aarch64 windows, renamed windows to windows-x86. --- .github/workflows/ci.yml | 372 ++++++++++++++++++++++++++++++++++++--- 1 file changed, 345 insertions(+), 27 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 658f44383b82..e66d4e61e7de 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -526,7 +526,7 @@ jobs: path: ./target/debug/uv retention-days: 1 - build-binary-windows: + build-binary-windows-x86_64: needs: determine_changes timeout-minutes: 10 if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} @@ -555,7 +555,7 @@ jobs: - name: "Upload binary" uses: actions/upload-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} path: ${{ env.UV_WORKSPACE }}/target/debug/uv.exe retention-days: 1 @@ -822,9 +822,9 @@ jobs: run: | ./uv pip install -v anyio - integration-test-free-threaded-windows: + integration-test-free-threaded-windows-x86_64: timeout-minutes: 10 - needs: build-binary-windows + needs: build-binary-windows-x86_64 name: "integration test | free-threaded on windows" runs-on: windows-latest env: @@ -835,7 +835,7 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} - name: "Install free-threaded Python via uv" run: | @@ -869,6 +869,55 @@ jobs: run: | ./uv run python -c "" ./uv run -p 3.13t python -c "" + + integration-test-free-threaded-windows-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "integration test | free-threaded on windows" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + + steps: + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} + + - name: "Install free-threaded Python via uv" + run: | + ./uv python install -v 3.13t + + - name: "Create a virtual environment (stdlib)" + run: | + & (./uv python find 3.13t) -m venv .venv + + - name: "Check version (stdlib)" + run: | + .venv/Scripts/python --version + + - name: "Create a virtual environment (uv)" + run: | + ./uv venv -p 3.13t --python-preference only-managed + + - name: "Check version (uv)" + run: | + .venv/Scripts/python --version + + - name: "Check is free-threaded" + run: | + .venv/Scripts/python -c "import sys; exit(1) if sys._is_gil_enabled() else exit(0)" + + - name: "Check install" + run: | + ./uv pip install -v anyio + + - name: "Check uv run" + run: | + ./uv run python -c "" + ./uv run -p 3.13t python -c "" + integration-test-pypy-linux: timeout-minutes: 10 @@ -934,9 +983,9 @@ jobs: run: | ./uv pip install anyio - integration-test-pypy-windows: + integration-test-pypy-windows-x86_64: timeout-minutes: 10 - needs: build-binary-windows + needs: build-binary-windows-x86_64 name: "integration test | pypy on windows" runs-on: windows-latest @@ -944,7 +993,70 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} + + - name: "Install PyPy" + run: .\uv.exe python install pypy3.9 + + - name: "Create a virtual environment" + run: | + .\uv.exe venv -p pypy3.9 --python-preference only-managed + + - name: "Check for executables" + shell: python + run: | + import sys + from pathlib import Path + + def binary_exist(binary): + binaries_path = Path(".venv\\Scripts") + if (binaries_path / binary).exists(): + return True + print(f"Executable '{binary}' not found in folder '{binaries_path}'.") + + all_found = True + expected_binaries = [ + "pypy3.9.exe", + "pypy3.9w.exe", + "pypy3.exe", + "pypyw.exe", + "python.exe", + "python3.9.exe", + "python3.exe", + "pythonw.exe", + ] + for binary in expected_binaries: + if not binary_exist(binary): + all_found = False + + if not all_found: + print("One or more expected executables were not found.") + sys.exit(1) + + - name: "Check version" + run: | + & .venv\Scripts\pypy3.9.exe --version + & .venv\Scripts\pypy3.exe --version + & .venv\Scripts\python.exe --version + + - name: "Check install" + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + run: | + .\uv.exe pip install anyio + + integration-test-pypy-windows-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "integration test | pypy on windows" + runs-on: github-windows-11-aarch64-4 + + steps: + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} - name: "Install PyPy" run: .\uv.exe python install pypy3.9 @@ -1066,9 +1178,9 @@ jobs: run: | ./uv pip install anyio - integration-test-graalpy-windows: + integration-test-graalpy-windows-x86_64: timeout-minutes: 10 - needs: build-binary-windows + needs: build-binary-windows-x86_64 name: "integration test | graalpy on windows" runs-on: windows-latest @@ -1080,7 +1192,70 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} + + - name: Graalpy info + run: Get-Command graalpy + + - name: "Create a virtual environment" + run: | + $graalpy = (Get-Command graalpy).source + .\uv.exe venv -p $graalpy + + - name: "Check for executables" + shell: python + run: | + import sys + from pathlib import Path + + def binary_exist(binary): + binaries_path = Path(".venv\\Scripts") + if (binaries_path / binary).exists(): + return True + print(f"Executable '{binary}' not found in folder '{binaries_path}'.") + + all_found = True + expected_binaries = [ + "graalpy.exe", + "python.exe", + "python3.exe", + ] + for binary in expected_binaries: + if not binary_exist(binary): + all_found = False + + if not all_found: + print("One or more expected executables were not found.") + sys.exit(1) + + - name: "Check version" + run: | + & .venv\Scripts\graalpy.exe --version + & .venv\Scripts\python3.exe --version + & .venv\Scripts\python.exe --version + + - name: "Check install" + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + run: | + .\uv.exe pip install anyio + + integration-test-graalpy-windows-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "integration test | graalpy on windows" + runs-on: github-windows-11-aarch64-4 + + steps: + - uses: timfel/setup-python@fc9bcb4a04f5b1ea7d678c2ca7ea1c479a2468d7 + with: + python-version: "graalpy24.1" + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} - name: Graalpy info run: Get-Command graalpy @@ -1614,8 +1789,8 @@ jobs: system-test-windows-python-310: timeout-minutes: 10 - needs: build-binary-windows - name: "check system | python3.10 on windows" + needs: build-binary-windows-x86_64 + name: "check system | python3.10 on windows x86_64" runs-on: windows-latest env: # Avoid debug build stack overflows. @@ -1630,7 +1805,33 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} + + - name: "Print Python path" + run: echo $(which python) + + - name: "Validate global Python install" + run: py -3.10 ./scripts/check_system_python.py --uv ./uv.exe + + system-test-windows-python-310-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "check system | python3.10 on windows aarch64" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} - name: "Print Python path" run: echo $(which python) @@ -1640,7 +1841,7 @@ jobs: system-test-windows-x86-python-310: timeout-minutes: 10 - needs: build-binary-windows + needs: build-binary-windows-x86_64 name: "check system | python3.10 on windows x86" runs-on: windows-latest env: @@ -1657,18 +1858,45 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} - name: "Print Python path" run: echo $(which python) - name: "Validate global Python install" run: python ./scripts/check_system_python.py --uv ./uv.exe + + system-test-windows-aarch64-python-310: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "check system | python3.10 on windows aarch64" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + steps: + - uses: actions/checkout@v4 - system-test-windows-python-313: + - uses: actions/setup-python@v5 + with: + python-version: "3.10" + architecture: "aarch64" + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} + + - name: "Print Python path" + run: echo $(which python) + + - name: "Validate global Python install" + run: python ./scripts/check_system_python.py --uv ./uv.exe + + system-test-windows-x86_64-python-313: timeout-minutes: 10 - needs: build-binary-windows - name: "check system | python3.13 on windows" + needs: build-binary-windows-x86_64 + name: "check system | python3.13 on windows x86_64" runs-on: windows-latest env: # Avoid debug build stack overflows. @@ -1685,7 +1913,35 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} + + - name: "Print Python path" + run: echo $(which python) + + - name: "Validate global Python install" + run: py -3.13 ./scripts/check_system_python.py --uv ./uv.exe + + system-test-windows-aarch64-python-313: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "check system | python3.13 on windows aarch64" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-python@v5 + with: + python-version: "3.13" + allow-prereleases: true + cache: pip + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} - name: "Print Python path" run: echo $(which python) @@ -1695,7 +1951,7 @@ jobs: system-test-choco: timeout-minutes: 10 - needs: build-binary-windows + needs: build-binary-windows-x86_64 name: "check system | python3.12 via chocolatey" runs-on: windows-latest env: @@ -1710,7 +1966,7 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} - name: "Print Python path" run: echo $(which python3) @@ -1718,6 +1974,32 @@ jobs: - name: "Validate global Python install" run: py -3.9 ./scripts/check_system_python.py --uv ./uv.exe + system-test-choco-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "check system | python3.12 via chocolatey" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + steps: + - uses: actions/checkout@v4 + + - name: "Install Python" + run: choco install python3 --verbose --version=3.9.13 + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} + + - name: "Print Python path" + run: echo $(which python3) + + - name: "Validate global Python install" + run: py -3.9 ./scripts/check_system_python.py --uv ./uv.exe + + system-test-pyenv: timeout-minutes: 10 needs: build-binary-linux @@ -1789,7 +2071,7 @@ jobs: system-test-conda: timeout-minutes: 10 needs: - [build-binary-windows, build-binary-macos-aarch64, build-binary-linux] + [build-binary-windows-x86_64, build-binary-windows-aarch64, build-binary-macos-aarch64, build-binary-linux] name: check system | conda${{ matrix.python-version }} on ${{ matrix.os }} runs-on: ${{ matrix.runner }} strategy: @@ -1799,7 +2081,8 @@ jobs: python-version: ["3.8", "3.11"] include: - { os: "linux", target: "linux", runner: "ubuntu-latest" } - - { os: "windows", target: "windows", runner: "windows-latest" } + - { os: "windows", target: "windows-x86_64", runner: "windows-latest" } + - { os: "windows", target: "windows-aarch64", runner: "github-windows-11-aarch64-4" } - { os: "macos", target: "macos-aarch64", runner: "macos-14" } steps: - uses: actions/checkout@v4 @@ -1869,8 +2152,8 @@ jobs: system-test-windows-embedded-python-310: timeout-minutes: 10 - needs: build-binary-windows - name: "check system | embedded python3.10 on windows" + needs: build-binary-windows-x86_64 + name: "check system | embedded python3.10 on windows x86_64" runs-on: windows-latest env: # Avoid debug build stack overflows. @@ -1881,7 +2164,7 @@ jobs: - name: "Download binary" uses: actions/download-artifact@v4 with: - name: uv-windows-${{ github.sha }} + name: uv-windows-x86_64-${{ github.sha }} # Download embedded Python. - name: "Download embedded Python" @@ -1902,6 +2185,41 @@ jobs: - name: "Validate embedded Python install" run: python ./scripts/check_embedded_python.py --uv ./uv.exe + system-test-windows-embedded-python-310-aarch64: + timeout-minutes: 10 + needs: build-binary-windows-aarch64 + name: "check system | embedded python3.10 on windows aarch64" + runs-on: github-windows-11-aarch64-4 + env: + # Avoid debug build stack overflows. + UV_STACK_SIZE: 3000000 # 3 megabyte, triple the default on windows + steps: + - uses: actions/checkout@v4 + + - name: "Download binary" + uses: actions/download-artifact@v4 + with: + name: uv-windows-aarch64-${{ github.sha }} + + # Download embedded Python. + - name: "Download embedded Python" + run: curl -LsSf https://www.python.org/ftp/python/3.11.8/python-3.11.8-embed-arm64.zip -o python-3.11.8-embed-arm64.zip + + - name: "Unzip embedded Python" + run: 7z x python-3.11.8-embed-arm64.zip -oembedded-python + + - name: "Show embedded Python contents" + run: ls embedded-python + + - name: "Set PATH" + run: echo "${{ github.workspace }}\embedded-python" >> $env:GITHUB_PATH + + - name: "Print Python path" + run: echo "${{ github.workspace }}\embedded-python" >> $env:GITHUB_PATH; echo $(which python) + + - name: "Validate embedded Python install" + run: echo "${{ github.workspace }}\embedded-python" >> $env:GITHUB_PATH; python ./scripts/check_embedded_python.py --uv ./uv.exe + benchmarks: runs-on: ubuntu-latest needs: determine_changes From 6e26dac9dff9fe475ca01a32828a9bf993514d7a Mon Sep 17 00:00:00 2001 From: Divyanshu Kalra Date: Sun, 12 Jan 2025 19:12:57 +0530 Subject: [PATCH 25/25] added building aarch64 using x86 windows. --- .github/workflows/ci.yml | 66 ++++++++-------------------------------- 1 file changed, 13 insertions(+), 53 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e66d4e61e7de..404b4e05ad05 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -532,7 +532,7 @@ jobs: if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} runs-on: labels: windows-latest-large - name: "build binary | windows" + name: "build binary | windows x86_64" steps: - uses: actions/checkout@v4 @@ -561,69 +561,29 @@ jobs: build-binary-windows-aarch64: needs: determine_changes - timeout-minutes: 30 + timeout-minutes: 25 if: ${{ github.repository == 'astral-sh/uv' && !contains(github.event.pull_request.labels.*.name, 'no-test') && (needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main') }} runs-on: - labels: github-windows-11-aarch64-4 + labels: windows-latest-large name: "build binary | windows aarch64" steps: - - name: Download LLVM (aarch64) - uses: robinraju/release-downloader@v1 - with: - repository: "llvm/llvm-project" - tag: "llvmorg-19.1.5" - filename: "LLVM-19.1.5-woa64.exe" - - - name: Install LLVM (aarch64) - run: | - Start-Process -FilePath "LLVM-19.1.5-woa64.exe" -ArgumentList '/S' -NoNewWindow -Wait - - - name: Install Build Tools (aarch64) - run: | - Set-ExecutionPolicy Bypass -Scope Process -Force - [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072 - iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) - Add-Content -Path $env:GITHUB_PATH -Value "C:\ProgramData\chocolatey\bin" -Encoding utf8 - choco install visualstudio2022buildtools -y --no-progress --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621 --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang --add Microsoft.VisualStudio.Component.VC.CMake.Project" - choco cache list -v - - - name: Add clang to PATH and check if clang exists - run: | - $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" - Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin" -Encoding utf8 - clang --version - - - name: Add cmake to PATH and check if cmake exists - run: | - $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\" - Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin" -Encoding utf8 - cmake --version - - - name: Install Nightly Rust (aarch64) - run: | - Add-Content -Path $env:GITHUB_PATH -Value "$env:USERPROFILE\.cargo\bin" -Encoding utf8 - Invoke-WebRequest -Uri "https://win.rustup.rs/aarch64" -OutFile "$env:RUNNER_TEMP\rustup-init.exe" - & "$env:RUNNER_TEMP\rustup-init.exe" --default-host aarch64-pc-windows-msvc --default-toolchain nightly -y + - uses: actions/checkout@v4 - - name: Download Git for Windows (aarch64) - uses: robinraju/release-downloader@v1 - with: - repository: "git-for-windows/git" - tag: "v2.48.0-rc1.windows.1" - filename: "Git-2.48.0-rc1-arm64.exe" + - name: Create Dev Drive using ReFS + run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1 - - name: Install Git for Windows (aarch64) + # actions/checkout does not let us clone into anywhere outside ${{ github.workspace }}, so we have to copy the clone... + - name: Copy Git Repo to Dev Drive run: | - Start-Process -FilePath "Git-2.48.0-rc1-arm64.exe" -ArgumentList "/VERYSILENT" -NoNewWindow -Wait - Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\cmd" -Encoding utf8 - Add-Content -Path $env:GITHUB_PATH -Value "C:\Program Files\Git\bin" -Encoding utf8 - - - uses: actions/checkout@v4 + Copy-Item -Path "${{ github.workspace }}" -Destination "${{ env.UV_WORKSPACE }}" -Recurse - uses: Swatinem/rust-cache@v2 + with: + workspaces: ${{ env.UV_WORKSPACE }} - name: "Build" - run: $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin"; $env:Path += ";C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\"; cargo build --target aarch64-pc-windows-msvc + working-directory: ${{ env.UV_WORKSPACE }} + run: cargo build --target aarch64-pc-windows-msvc - name: "Upload binary" uses: actions/upload-artifact@v4