@@ -25,10 +25,6 @@ permissions:
2525
2626env :
2727 XGRAMMAR_VERSION : ${{ inputs.version || '0.2.4' }}
28- UV_EXTRA_INDEX_URL : https://pypi.riseproject.dev/simple/
29- UV_INDEX_STRATEGY : unsafe-best-match
30- UV_ONLY_BINARY : ' :all:'
31- MANYLINUX_RISCV64_IMAGE : quay.io/pypa/manylinux_2_39_riscv64
3228
3329jobs :
3430 build_wheels :
@@ -53,40 +49,28 @@ jobs:
5349 submodules : recursive
5450 persist-credentials : false
5551
56- - name : Install Python
57- uses : astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
58- with :
59- python-version : ' 3.12'
60- activate-environment : true
61- enable-cache : false
62-
63- - name : Install cibuildwheel
64- run : uv pip install cibuildwheel
65-
6652 - name : Build wheels
67- run : python -m cibuildwheel --output-dir wheelhouse
53+ uses : pypa/cibuildwheel@1828c10ab37f080699c7b81cea34097c684a7074 # v4.2.0
54+ with :
55+ output-dir : wheelhouse/
56+ only : ${{ matrix.python }}-manylinux_riscv64
6857 env :
69- CIBW_BUILD : ${{ matrix.python }}-manylinux_riscv64
7058 # pyproject pins [tool.cibuildwheel.linux] archs to x86_64+aarch64;
7159 # override so this native riscv runner builds the riscv64 wheel.
7260 CIBW_ARCHS : riscv64
73- CIBW_SKIP : ' *-musllinux_*'
74- CIBW_MANYLINUX_RISCV64_IMAGE : ${{ env.MANYLINUX_RISCV64_IMAGE }}
7561 # Override upstream's build-frontend = "build[uv]". cibuildwheel's audit
7662 # step creates a venv on the *host* runner (not in the container) and,
7763 # when the frontend is build[uv], insists on a host `uv` binary.
7864 # The self-hosted riscv runner has no host uv, so use plain `build`
7965 # (pip/virtualenv on the host) instead.
8066 CIBW_BUILD_FRONTEND : build
8167 # CIBW_ENVIRONMENT applies to both build and test phases.
82- # Point pip/uv at our registry so build-time deps (apache-tvm-ffi
83- # riscv64 wheel) and test-time deps resolve correctly.
68+ # Point pip at our registry so build-time deps (apache-tvm-ffi riscv64
69+ # wheel) and test-time deps resolve correctly.
8470 # Do NOT set ONLY_BINARY here: scikit-build-core itself is a build dep
8571 # that installs from sdist if needed.
8672 CIBW_ENVIRONMENT : >-
8773 PIP_EXTRA_INDEX_URL=https://pypi.riseproject.dev/simple/
88- UV_EXTRA_INDEX_URL=https://pypi.riseproject.dev/simple/
89- UV_INDEX_STRATEGY=unsafe-best-match
9074 # Skip tests for cp314t: numpy, tokenizers and safetensors (runtime
9175 # deps pulled in via transformers) have no free-threaded riscv64
9276 # wheels on any index yet, so the test-install step fails. The wheel
9579 # Test phase only: force wheels-only so a missing riscv64 wheel for a
9680 # heavy test dep (torch, tokenizers) fails fast instead of silently
9781 # kicking off a multi-hour source build on the runner.
98- CIBW_TEST_ENVIRONMENT : >-
99- PIP_ONLY_BINARY=:all:
100- UV_ONLY_BINARY=:all:
82+ CIBW_TEST_ENVIRONMENT : " PIP_ONLY_BINARY=:all:"
10183 # Mirror upstream's test-command from pyproject.toml
10284 # (pytest {project}/tests -m "not hf_token_required"), but omit the
10385 # hf_token_required marker filter: conftest.py already auto-skips those
0 commit comments