From 3a1005e4e3ce680aef016c97117632436ed94166 Mon Sep 17 00:00:00 2001 From: Jax Liu Date: Mon, 31 Aug 2026 11:23:04 +0800 Subject: [PATCH] ci(release): widen the lock-sync retry window for PyPI propagation The 0.7.6 release published fine but the follow-up lock sync failed: all five uv add attempts (~80s total) still resolved against an index that only listed 0.7.5. Wait up to 10 minutes instead so a slow index update no longer turns a good release into a red job needing a manual re-run. Co-Authored-By: Claude Opus 5 (1M context) --- .github/workflows/sync-wren-core-py-lock.yml | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/.github/workflows/sync-wren-core-py-lock.yml b/.github/workflows/sync-wren-core-py-lock.yml index 88dc817eaa..3e44fd0a22 100644 --- a/.github/workflows/sync-wren-core-py-lock.yml +++ b/.github/workflows/sync-wren-core-py-lock.yml @@ -66,17 +66,22 @@ jobs: working-directory: core/wren run: | # uv add rewrites the pyproject floor in place and relocks in one step; - # --no-sync skips the heavy env. Retry for PyPI index lag after publish. - for attempt in 1 2 3 4 5; do + # --no-sync skips the heavy env. Retry for PyPI index lag after publish: + # the release is only resolvable once the new version reaches the index + # uv reads, which has taken longer than the old ~80s window (0.7.6 saw + # five straight "only wren-core-py<=0.7.5 is available" failures). + attempts=10 + delay=60 + for attempt in $(seq 1 "${attempts}"); do if uv add --no-sync "wren-core-py>=${VERSION}"; then exit 0 fi - if [ "${attempt}" -lt 5 ]; then - echo "uv add attempt ${attempt} failed; retrying after PyPI propagation delay" - sleep 20 + if [ "${attempt}" -lt "${attempts}" ]; then + echo "uv add attempt ${attempt}/${attempts} failed; retrying in ${delay}s for PyPI propagation" + sleep "${delay}" fi done - echo "::error::uv add did not succeed after retries" + echo "::error::uv add did not succeed after ${attempts} attempts" exit 1 - name: Validate lockfile is consistent