Skip to content

Commit a6db13b

Browse files
therealalephclaude
andcommitted
ci: download release artifacts from GitHub Release page, not artifacts API
The commit-releases job's `actions/download-artifact@v4` step has failed twice in a row (v1.7.5 retrigger, v1.7.6) with the same shape: ~10 artifacts download successfully, then "Unable to download artifact(s): Artifact download failed after 5 retries" on the 11th-13th. The 10 that complete print their SHA256 digests cleanly; the failure is unambiguously inside actions/download- artifact, not on our side. Workaround: pull from `gh release download` instead. The `release` job populated the GitHub Release page a few seconds earlier with the same artifacts; pulling from there reads from a different CDN (Release-page blob store) with different retry / rate-limit characteristics. Empirically more reliable for our 13-artifact release size. Filtered to *.tar.gz / *.zip / *.apk so we only fetch the user- facing artifacts (skipping anything like checksum sidecars that softprops/action-gh-release@v2 might add later). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent aba5393 commit a6db13b

1 file changed

Lines changed: 32 additions & 4 deletions

File tree

.github/workflows/release.yml

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -676,10 +676,38 @@ jobs:
676676
ref: main
677677
fetch-depth: 0
678678

679-
- uses: actions/download-artifact@v4
680-
with:
681-
path: artifacts
682-
merge-multiple: true
679+
# Pull artifacts from the GitHub Release page (which the `release`
680+
# job populated a few seconds earlier) rather than the workflow
681+
# artifacts API. The artifacts API path —
682+
# `actions/download-artifact@v4` with `merge-multiple: true` —
683+
# has been failing with "artifact download failed after 5
684+
# retries" on one of the ~13 artifacts on multiple consecutive
685+
# runs (v1.7.5 retrigger, v1.7.6). The 10 fast downloads that
686+
# complete first all succeed; the 11th-13th hit the error.
687+
# `gh release download` reads from GitHub's Release-page CDN,
688+
# which is independent of the artifacts blob store and has a
689+
# different retry / rate-limit profile. Same files, more
690+
# reliable surface.
691+
- name: Download artifacts from the GitHub Release page
692+
env:
693+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
694+
run: |
695+
set -euo pipefail
696+
VER="${{ inputs.version || github.ref_name }}"
697+
# Strip leading `v` to normalize, then re-add — the Release
698+
# tag is `vX.Y.Z`, but for the rest of the workflow we use
699+
# bare `X.Y.Z`. Mirror the same pattern here so a downstream
700+
# readme update can use the bare version.
701+
VER="${VER#v}"
702+
mkdir -p artifacts
703+
gh release download "v${VER}" \
704+
--repo "${{ github.repository }}" \
705+
--dir artifacts \
706+
--pattern '*.tar.gz' \
707+
--pattern '*.zip' \
708+
--pattern '*.apk'
709+
echo "--- artifacts/ contents ---"
710+
ls -la artifacts/
683711
684712
- name: Refresh releases/ folder
685713
run: |

0 commit comments

Comments
 (0)