ci: use uv to run tests #2222
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| on: | |
| push: | |
| pull_request: | |
| schedule: | |
| - cron: '30 13 * * *' | |
| permissions: { } | |
| jobs: | |
| linux: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| image: | |
| - 'manylinux2014_aarch64' | |
| - 'musllinux_1_1_aarch64' | |
| - 'musllinux_1_2_aarch64' | |
| - 'manylinux2014_i686' | |
| - 'musllinux_1_2_i686' | |
| - 'manylinux2014_ppc64le' | |
| - 'musllinux_1_2_ppc64le' | |
| - 'manylinux2014_s390x' | |
| - 'musllinux_1_2_s390x' | |
| - 'manylinux2014_x86_64' | |
| - 'musllinux_1_1_x86_64' | |
| - 'musllinux_1_2_x86_64' | |
| py: | |
| - 'cp39-cp39' | |
| - 'cp310-cp310' | |
| - 'cp311-cp311' | |
| - 'cp312-cp312' | |
| - 'cp313-cp313' | |
| - 'cp314-cp314' | |
| exclude: | |
| - image: 'musllinux_1_1_aarch64' | |
| py: 'cp314-cp314' | |
| - image: 'musllinux_1_1_x86_64' | |
| py: 'cp314-cp314' | |
| runs-on: ${{ endsWith(matrix.image, 'aarch64') && 'ubuntu-22.04-arm' || 'ubuntu-22.04' }} | |
| steps: | |
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| with: | |
| persist-credentials: false | |
| - name: Set up QEMU | |
| if: ${{ endsWith(matrix.image, 'ppc64le') || endsWith(matrix.image, 's390x') }} | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Build Wheel | |
| run: | | |
| docker run -e PYPATH=/opt/python/${{ matrix.py }} -e ZSTD_WARNINGS_AS_ERRORS=1 --rm -v `pwd`:/project quay.io/pypa/${{ matrix.image }} /project/ci/build-manylinux-wheel.sh | |
| - name: Upload Wheel | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 | |
| with: | |
| name: linux-${{ matrix.py }}-${{ matrix.image }} | |
| path: dist | |
| macos: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| py: | |
| - 'cp39' | |
| - 'cp310' | |
| - 'cp311' | |
| - 'cp312' | |
| - 'cp313' | |
| - 'cp314' | |
| arch: | |
| - 'arm64' | |
| - 'x86_64' | |
| runs-on: ${{ matrix.arch == 'x86_64' && 'macos-13' || 'macos-14' }} | |
| env: | |
| CIBW_ARCHS: ${{ matrix.arch }} | |
| CIBW_BUILD: ${{ matrix.py }}-* | |
| CIBW_BUILD_VERBOSITY: '1' | |
| ZSTD_WARNINGS_AS_ERRORS: '1' | |
| steps: | |
| - name: Set up Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0 | |
| with: | |
| python-version: '3.13' | |
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| with: | |
| persist-credentials: false | |
| - name: Install Dependencies | |
| run: | | |
| python -m pip install --require-hashes -r ci/requirements.macoswheels.txt | |
| - name: Build Wheel | |
| run: | | |
| cibuildwheel --output-dir dist | |
| - name: Upload Wheel | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 | |
| with: | |
| name: macos-${{ matrix.py }}-${{ matrix.arch }} | |
| path: dist | |
| windows: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| py: | |
| - '3.9' | |
| - '3.10' | |
| - '3.11' | |
| - '3.12' | |
| - '3.13' | |
| - '3.14' | |
| arch: | |
| - 'x86' | |
| - 'x64' | |
| - 'arm64' | |
| exclude: | |
| - py: '3.8' | |
| arch: 'arm64' | |
| - py: '3.9' | |
| arch: 'arm64' | |
| - py: '3.10' | |
| arch: 'arm64' | |
| runs-on: ${{ matrix.arch == 'arm64' && 'windows-11-arm' || 'windows-2022' }} | |
| env: | |
| ZSTD_WARNINGS_AS_ERRORS: '1' | |
| steps: | |
| - name: Set up Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0 | |
| with: | |
| python-version: ${{ matrix.py }} | |
| architecture: ${{ matrix.arch }} | |
| allow-prereleases: true | |
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| with: | |
| persist-credentials: false | |
| - name: Build Wheel | |
| run: | | |
| python -m pip wheel -w dist . | |
| - name: Upload Wheel | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 | |
| with: | |
| name: windows-${{ matrix.py }}-${{ matrix.arch }} | |
| path: dist |