ci: point uv build at Tsinghua PyPI mirror via UV_DEFAULT_INDEX
CI / CI (push) Failing after 4s

The self-hosted astral-uv runner is in China; pulling build deps
from pypi.org is slow and often times out. Set UV_DEFAULT_INDEX
on the 'Build package' step so uv's build-environment resolution
goes through the Tsinghua mirror.

This complements the [tool.uv.index] url=... block in
pyproject.toml — env wins over the file config when both are
present, so the mirror is used consistently.

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
tao.chen
2026-07-21 19:06:49 +08:00
co-authored by Claude
parent ac17a954b0
commit d40d19ae96
+5
View File
@@ -21,6 +21,11 @@ jobs:
uses: actions/checkout@v4
- name: Build package
env:
# Use the Tsinghua PyPI mirror for build-environment resolution;
# the self-hosted runner is in China and the default pypi.org is
# too slow / unreliable for build dependency install.
UV_DEFAULT_INDEX: "https://pypi.tuna.tsinghua.edu.cn/simple/"
run: uv build
- name: Upload wheel artifacts