diff --git a/.github/workflows/build-binaries.yml b/.github/workflows/build-binaries.yml index 8bfdc26827b00..669597eda29a4 100644 --- a/.github/workflows/build-binaries.yml +++ b/.github/workflows/build-binaries.yml @@ -33,377 +33,23 @@ env: RUSTUP_MAX_RETRIES: 10 jobs: - sdist: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: "Build sdist" - uses: PyO3/maturin-action@v1 - with: - command: sdist - args: --out dist - - name: "Test sdist" - run: | - pip install dist/${{ env.PACKAGE_NAME }}-*.tar.gz --force-reinstall - ${{ env.MODULE_NAME }} --help - python -m ${{ env.MODULE_NAME }} --help - - name: "Upload sdist" - uses: actions/upload-artifact@v4 - with: - name: wheels-sdist - path: dist - - macos-x86_64: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: macos-latest - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - architecture: x64 - - name: "Build wheels - x86_64" - uses: PyO3/maturin-action@v1 - with: - target: x86_64 - args: --release --locked --out dist - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-macos-x86_64 - path: dist - - name: "Archive binary" - run: | - TARGET=x86_64-apple-darwin - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-macos-x86_64 - path: | - *.tar.gz - *.sha256 - - macos-universal: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: macos-latest - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - architecture: x64 - - name: "Build wheels - universal2" - uses: PyO3/maturin-action@v1 - with: - args: --release --locked --target universal2-apple-darwin --out dist - - name: "Test wheel - universal2" - run: | - pip install dist/${{ env.PACKAGE_NAME }}-*universal2.whl --force-reinstall - ${{ env.MODULE_NAME }} --help - python -m ${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-aarch64-apple-darwin - path: dist - - name: "Archive binary" - run: | - TARGET=aarch64-apple-darwin - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-aarch64-apple-darwin - path: | - *.tar.gz - *.sha256 - - windows: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: windows-latest - strategy: - matrix: - platform: - - target: x86_64-pc-windows-msvc - arch: x64 - - target: i686-pc-windows-msvc - arch: x86 - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - architecture: ${{ matrix.platform.arch }} - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.platform.target }} - args: --release --locked --out dist - - name: "Test wheel" - if: ${{ !startsWith(matrix.platform.target, 'aarch64') }} - shell: bash - run: | - python -m pip install dist/${{ env.PACKAGE_NAME }}-*.whl --force-reinstall - ${{ env.MODULE_NAME }} --help - python -m ${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.platform.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - ARCHIVE_FILE=uv-${{ matrix.platform.target }}.zip - 7z a $ARCHIVE_FILE ./target/${{ matrix.platform.target }}/release/uv.exe - sha256sum $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.platform.target }} - path: | - *.zip - *.sha256 - - linux: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - strategy: - matrix: - target: - - x86_64-unknown-linux-gnu - - i686-unknown-linux-gnu - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - architecture: x64 - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.target }} - manylinux: auto - args: --release --locked --out dist - # See: https://github.com/sfackler/rust-openssl/issues/2036#issuecomment-1724324145 - before-script-linux: | - # If we're running on rhel centos, install needed packages. - if command -v yum &> /dev/null; then - yum update -y && yum install -y perl-core openssl openssl-devel pkgconfig libatomic - - # If we're running on i686 we need to symlink libatomic - # in order to build openssl with -latomic flag. - if [[ ! -d "/usr/lib64" ]]; then - ln -s /usr/lib/libatomic.so.1 /usr/lib/libatomic.so - fi - else - # If we're running on debian-based system. - apt update -y && apt-get install -y libssl-dev openssl pkg-config - fi - - name: "Test wheel" - if: ${{ startsWith(matrix.target, 'x86_64') }} - run: | - pip install dist/${{ env.PACKAGE_NAME }}-*.whl --force-reinstall - ${{ env.MODULE_NAME }} --help - python -m ${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - set -euo pipefail - - TARGET=${{ matrix.target }} - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.target }} - path: | - *.tar.gz - *.sha256 - linux-arm: if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} runs-on: ubuntu-latest strategy: matrix: platform: - - target: aarch64-unknown-linux-gnu - arch: aarch64 - # see https://github.com/astral-sh/ruff/issues/3791 - # and https://github.com/gnzlbg/jemallocator/issues/170#issuecomment-1503228963 - maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16 - - target: armv7-unknown-linux-gnueabihf +# - target: aarch64-unknown-linux-gnu +# arch: aarch64 +# # see https://github.com/astral-sh/ruff/issues/3791 +# # and https://github.com/gnzlbg/jemallocator/issues/170#issuecomment-1503228963 +# maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16 +# - target: armv7-unknown-linux-gnueabihf +# arch: armv7 + - target: armv7-unknown-linux-musleabihf arch: armv7 - - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.platform.target }} - manylinux: 2_28 - docker-options: ${{ matrix.platform.maturin_docker_options }} - args: --release --locked --out dist - - uses: uraimo/run-on-arch-action@v2 - if: matrix.platform.arch != 'ppc64' - name: Test wheel - with: - arch: ${{ matrix.platform.arch }} - distro: ubuntu20.04 - githubToken: ${{ github.token }} - install: | - apt-get update - apt-get install -y --no-install-recommends python3 python3-pip - pip3 install -U pip - run: | - pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall - ${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.platform.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - set -euo pipefail - - TARGET=${{ matrix.platform.target }} - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.platform.target }} - path: | - *.tar.gz - *.sha256 - - # Like `linux-arm`, but use `--no-default-features --features flate2/rust_backend` when - # building uv. - linux-s390x: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - strategy: - matrix: - platform: - - target: s390x-unknown-linux-gnu - arch: s390x - - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.platform.target }} - manylinux: auto - docker-options: ${{ matrix.platform.maturin_docker_options }} - args: --release --locked --out dist --no-default-features --features flate2/rust_backend - - uses: uraimo/run-on-arch-action@v2 - if: matrix.platform.arch != 'ppc64' - name: Test wheel - with: - arch: ${{ matrix.platform.arch }} - distro: ubuntu20.04 - githubToken: ${{ github.token }} - install: | - apt-get update - apt-get install -y --no-install-recommends python3 python3-pip - pip3 install -U pip - run: | - pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall - ${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.platform.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - set -euo pipefail - - TARGET=${{ matrix.platform.target }} - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.platform.target }} - path: | - *.tar.gz - *.sha256 - - # Like `linux-arm`, but use `--no-default-features --features flate2/rust_backend` when - # building uv, and install the `gcc-powerpc64-linux-gnu` package. - linux-powerpc: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - strategy: - matrix: - platform: - - target: powerpc64le-unknown-linux-gnu - arch: ppc64le - - target: powerpc64-unknown-linux-gnu - arch: ppc64 +# - target: arm-unknown-linux-musleabihf +# arch: armv7 steps: - uses: actions/checkout@v4 @@ -424,7 +70,7 @@ jobs: yum update -y yum -y install epel-release yum repolist - yum install -y gcc-powerpc64-linux-gnu + yum install -y gcc-arm-linux-gnu fi - uses: uraimo/run-on-arch-action@v2 if: matrix.platform.arch != 'ppc64' @@ -465,126 +111,3 @@ jobs: path: | *.tar.gz *.sha256 - - musllinux: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - strategy: - matrix: - target: - - x86_64-unknown-linux-musl - - i686-unknown-linux-musl - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - architecture: x64 - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.target }} - manylinux: musllinux_1_2 - args: --release --locked --out dist - - name: "Test wheel" - if: matrix.target == 'x86_64-unknown-linux-musl' - uses: addnab/docker-run-action@v3 - with: - image: alpine:latest - options: -v ${{ github.workspace }}:/io -w /io - run: | - apk add python3 - python -m venv .venv - .venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall - .venv/bin/${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - set -euo pipefail - - TARGET=${{ matrix.target }} - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.target }} - path: | - *.tar.gz - *.sha256 - - musllinux-cross: - if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: ubuntu-latest - strategy: - matrix: - platform: - - target: aarch64-unknown-linux-musl - arch: aarch64 - maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16 - - target: armv7-unknown-linux-musleabihf - arch: armv7 - - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: "Build wheels" - uses: PyO3/maturin-action@v1 - with: - target: ${{ matrix.platform.target }} - manylinux: musllinux_1_2 - args: --release --locked --out dist - docker-options: ${{ matrix.platform.maturin_docker_options }} - - uses: uraimo/run-on-arch-action@v2 - name: Test wheel - with: - arch: ${{ matrix.platform.arch }} - distro: alpine_latest - githubToken: ${{ github.token }} - install: | - apk add python3 - run: | - python -m venv .venv - .venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall - .venv/bin/${{ env.MODULE_NAME }} --help - - name: "Upload wheels" - uses: actions/upload-artifact@v4 - with: - name: wheels-${{ matrix.platform.target }} - path: dist - - name: "Archive binary" - shell: bash - run: | - set -euo pipefail - - TARGET=${{ matrix.platform.target }} - ARCHIVE_NAME=uv-$TARGET - ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz - - mkdir -p $ARCHIVE_NAME - cp target/$TARGET/release/uv $ARCHIVE_NAME/uv - tar czvf $ARCHIVE_FILE $ARCHIVE_NAME - shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256 - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: artifacts-${{ matrix.platform.target }} - path: | - *.tar.gz - *.sha256 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index 13bd576b64f14..0000000000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,539 +0,0 @@ -name: CI - -on: - push: - branches: [main] - pull_request: - workflow_dispatch: - -concurrency: - group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.event.pull_request.number || github.sha }} - cancel-in-progress: true - -env: - CARGO_INCREMENTAL: 0 - CARGO_NET_RETRY: 10 - CARGO_TERM_COLOR: always - RUSTUP_MAX_RETRIES: 10 - PYTHON_VERSION: "3.12" - -jobs: - cargo-fmt: - name: "cargo fmt" - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: "Install Rust toolchain" - run: rustup component add rustfmt - - name: "rustfmt" - run: cargo fmt --all --check - - cargo-clippy: - name: "cargo clippy" - strategy: - matrix: - os: [ubuntu-latest, windows-latest] - fail-fast: false - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - name: "Install Rust toolchain" - run: rustup component add clippy - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref == 'refs/heads/main' }} - - name: "Clippy" - run: cargo clippy --workspace --all-targets --all-features --locked -- -D warnings - - cargo-test: - strategy: - matrix: - include: - # We use the large GitHub actions runners - # For Ubuntu and Windows, this requires Organization-level configuration - # See: https://docs.github.com/en/actions/using-github-hosted-runners/about-larger-runners/about-larger-runners#about-ubuntu-and-windows-larger-runners - - { os: "ubuntu", runner: "ubuntu-latest-large" } - - { os: "windows", runner: "windows-latest-large" } - - { os: "macos", runner: "macos-14" } - fail-fast: false - runs-on: - labels: ${{ matrix.runner }} - name: "cargo test | ${{ matrix.os }}" - steps: - - uses: actions/checkout@v4 - - - if: ${{ matrix.os == 'macos' }} - name: "Install bootstrap dependencies" - run: brew install coreutils - - - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: "Install pipx" - run: pip install pipx - - - name: "Install required Python versions" - run: pipx run scripts/bootstrap/install.py - - - name: "Install Rust toolchain" - run: rustup show - - - name: "Install cargo nextest" - uses: taiki-e/install-action@v2 - with: - tool: cargo-nextest - - - if: ${{ matrix.os != 'windows' }} - uses: rui314/setup-mold@v1 - - - uses: Swatinem/rust-cache@v2 - - - name: "Cargo test" - run: | - cargo nextest run --workspace --status-level skip --failure-output immediate-final --no-fail-fast -j 12 --final-status-level slow - - - name: "Smoke test (unix)" - if: ${{ matrix.os != 'windows' }} - run: | - uv="./target/debug/uv" - $uv venv - $uv pip install ruff - - - name: "Smoke test (windows)" - if: ${{ matrix.os == 'windows' }} - run: | - Set-Alias -Name uv -Value ./target/debug/uv - uv venv - uv pip install ruff - - # Separate job for the nightly crate - windows-trampoline: - runs-on: windows-latest - name: "check windows trampoline" - steps: - - uses: actions/checkout@v4 - - name: "Install Rust toolchain" - working-directory: crates/uv-trampoline - run: | - rustup target add x86_64-pc-windows-msvc - rustup component add clippy rust-src --toolchain nightly-2024-01-23-x86_64-pc-windows-msvc - - uses: rui314/setup-mold@v1 - - uses: Swatinem/rust-cache@v2 - with: - workspaces: "crates/uv-trampoline" - - name: "Clippy" - working-directory: crates/uv-trampoline - run: cargo clippy --all-features --locked --target x86_64-pc-windows-msvc -- -D warnings - - name: "Build" - working-directory: crates/uv-trampoline - run: cargo build --release --target x86_64-pc-windows-msvc - - build-binary-linux: - runs-on: - labels: ubuntu-latest-large - name: "build binary | linux" - steps: - - uses: actions/checkout@v4 - - - uses: rui314/setup-mold@v1 - - - name: "Setup musl" - run: | - sudo apt-get install musl-tools - rustup target add x86_64-unknown-linux-musl - - - uses: Swatinem/rust-cache@v2 - - name: "Build" - run: cargo build --target x86_64-unknown-linux-musl - - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - path: ./target/x86_64-unknown-linux-musl/debug/uv - retention-days: 1 - - build-binary-macos-aarch64: - runs-on: - labels: macos-14 - name: "build binary | macos" - steps: - - uses: actions/checkout@v4 - - - uses: rui314/setup-mold@v1 - - - uses: Swatinem/rust-cache@v2 - - name: "Build" - run: cargo build - - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: uv-macos-aarch64-${{ github.sha }} - path: ./target/debug/uv - retention-days: 1 - - build-binary-windows: - runs-on: - labels: windows-latest-large - name: "build binary | windows" - steps: - - uses: actions/checkout@v4 - - - uses: rui314/setup-mold@v1 - - - uses: Swatinem/rust-cache@v2 - - name: "Build" - run: cargo build - - - name: "Upload binary" - uses: actions/upload-artifact@v4 - with: - name: uv-windows-${{ github.sha }} - path: ./target/debug/uv.exe - retention-days: 1 - - system-test-debian: - needs: build-binary-linux - name: "check system | python on debian" - runs-on: ubuntu-latest - container: debian:bullseye - steps: - - uses: actions/checkout@v4 - - - name: "Install Python" - run: apt-get update && apt-get install -y python3.9 python3-pip python3.9-venv - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3.9) - - - name: "Validate global Python install" - run: python3.9 scripts/check_system_python.py --uv ./uv - - system-test-ubuntu: - needs: build-binary-linux - name: "check system | python on ubuntu" - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python) - - - name: "Validate global Python install" - run: python scripts/check_system_python.py --uv ./uv - - system-test-centos: - needs: build-binary-linux - name: "check system | python on centos" - runs-on: ubuntu-latest - container: centos:8 - steps: - - uses: actions/checkout@v4 - - - name: "Install Python" - run: | - # Add CentOS stream repositories, you cannot install from the EOL CentOS 8 mirrors - dnf -y --disablerepo '*' --enablerepo extras swap centos-linux-repos centos-stream-repos - # `python` gives you `python3.6` which we do not support - dnf install python39 python39-pip which -y - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3) - - - name: "Validate global Python install" - run: python3 scripts/check_system_python.py --uv ./uv - - system-test-pypy: - needs: build-binary-linux - name: "check system | pypy on ubuntu" - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - uses: actions/setup-python@v5 - with: - python-version: "pypy3.9" - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which pypy) - - - name: "Validate global Python install" - run: pypy scripts/check_system_python.py --uv ./uv - - system-test-pyston: - needs: build-binary-linux - name: "check system | pyston" - runs-on: ubuntu-latest - container: pyston/pyston:2.3.5 - steps: - - uses: actions/checkout@v4 - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which pyston) - - - name: "Validate global Python install" - run: pyston scripts/check_system_python.py --uv ./uv - - system-test-alpine: - needs: build-binary-linux - name: "check system | alpine" - runs-on: ubuntu-latest - container: alpine:latest - steps: - - uses: actions/checkout@v4 - - - name: "Install Python" - run: apk add --update --no-cache python3 py3-pip - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3) - - - name: "Validate global Python install" - run: python3 scripts/check_system_python.py --uv ./uv --externally-managed - - system-test-macos: - needs: build-binary-macos-aarch64 - name: "check system | python on macos" - runs-on: macos-14 - steps: - - uses: actions/checkout@v4 - - - name: "Install Python" - run: brew install python@3.8 - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-macos-aarch64-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3.11) - - - name: "Validate global Python install" - run: python3.11 scripts/check_system_python.py --uv ./uv - - system-test-windows-python-310: - needs: build-binary-windows - name: "check system | python3.10 on windows" - runs-on: windows-latest - 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-${{ 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-313: - needs: build-binary-windows - name: "check system | python3.13 on windows" - runs-on: windows-latest - 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-${{ 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-choco: - needs: build-binary-windows - name: "check system | python3.12 via chocolatey" - runs-on: windows-latest - 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-${{ 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: - needs: build-binary-linux - name: "check system | python via pyenv" - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - name: "Install pyenv" - uses: "gabrielfalcao/pyenv-action@v18" - with: - default: 3.9.7 - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3.9) - - - name: "Validate global Python install" - run: python3.9 scripts/check_system_python.py --uv ./uv - - system-test-conda: - needs: - [build-binary-windows, build-binary-macos-aarch64, build-binary-linux] - name: check system | conda${{ matrix.python-version }} on ${{ matrix.os }} - runs-on: ${{ matrix.runner }} - strategy: - fail-fast: false - matrix: - os: ["linux", "windows", "macos"] - python-version: ["3.8", "3.11"] - include: - - { os: "linux", target: "linux", runner: "ubuntu-latest" } - - { os: "windows", target: "windows", runner: "windows-latest" } - - { os: "macos", target: "macos-aarch64", runner: "macos-14" } - steps: - - uses: actions/checkout@v4 - - - uses: conda-incubator/setup-miniconda@v3 - with: - miniconda-version: "latest" - activate-environment: uv - python-version: ${{ matrix.python-version }} - - - name: Conda info - shell: bash -el {0} - run: conda info - - - name: Conda list - shell: pwsh - run: conda list - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-${{ matrix.target }}-${{ github.sha }} - - - name: "Prepare binary" - if: ${{ matrix.os != 'windows' }} - run: chmod +x ./uv - - - name: "Print Python path" - shell: bash -el {0} - run: echo $(which python) - - - name: "Validate global Python install" - shell: bash -el {0} - run: python ./scripts/check_system_python.py --uv ./uv - - system-test-amazonlinux: - needs: build-binary-linux - name: "check system | amazonlinux" - runs-on: ubuntu-latest - container: amazonlinux:2023 - steps: - - name: "Install base requirements" - run: | - # Needed for `actions/checkout` - yum install tar gzip which -y - - uses: actions/checkout@v4 - - name: "Install Python" - run: yum install python3 python3-pip -y - - - name: "Download binary" - uses: actions/download-artifact@v4 - with: - name: uv-linux-${{ github.sha }} - - - name: "Prepare binary" - run: chmod +x ./uv - - - name: "Print Python path" - run: echo $(which python3) - - - name: "Validate global Python install" - run: python3 scripts/check_system_python.py --uv ./uv