From 0dd7fa0446f7629e448f35ca722cb94150747910 Mon Sep 17 00:00:00 2001 From: Arvind Arikatla Date: Fri, 24 Apr 2026 19:03:29 -0700 Subject: [PATCH] ci: remove redundant PyPI fetch to fix CDN cache race condition --- .github/workflows/release.yml | 5 ++--- .github/workflows/update-formula.yml | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b88a8ec..e58d8b8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -47,10 +47,9 @@ jobs: run: | VERSION="${{ steps.meta.outputs.version }}" mkdir -p dist/ - # Fetch PyPI metadata and extract both URLs - curl -sf "https://pypi.org/pypi/gemstack/$VERSION/json" > pypi.json + # Use PyPI metadata already fetched by the Wait step if [ ! -s pypi.json ]; then - echo "::error::Failed to fetch PyPI metadata for gemstack $VERSION" + echo "::error::PyPI metadata file missing or empty!" exit 1 fi WHEEL_URL=$(python3 -c "import sys,json; urls=json.load(open('pypi.json'))['urls']; print(next(u['url'] for u in urls if u['packagetype']=='bdist_wheel'))") diff --git a/.github/workflows/update-formula.yml b/.github/workflows/update-formula.yml index 490b29c..d900602 100644 --- a/.github/workflows/update-formula.yml +++ b/.github/workflows/update-formula.yml @@ -42,8 +42,7 @@ jobs: id: sha run: | VERSION="${{ steps.version.outputs.version }}" - # Fetch PyPI metadata - curl -sf "https://pypi.org/pypi/gemstack/$VERSION/json" > pypi.json + # Use PyPI metadata already fetched by the Wait step URL=$(python3 -c "import sys,json; urls=json.load(open('pypi.json'))['urls']; print(next(u['url'] for u in urls if u['packagetype']=='sdist'))") echo "Downloading $URL" curl -fSL "$URL" -o gemstack.tar.gz