From 55ca534c5016eb9078c3fa6d10d83cc3a75cdefd Mon Sep 17 00:00:00 2001 From: GitBib <15717621+GitBib@users.noreply.github.com> Date: Sun, 2 Aug 2026 16:42:59 +0300 Subject: [PATCH] ci: make fixture download resumable and retry transient stalls A macOS runner failed the 71 MB fixture download with "curl: (56) Recv failure: Operation timed out" and needed a manual re-run. --retry does not cover a stall mid-transfer, only connection errors and transient HTTP codes, so that class of failure never retried. Each attempt also restarted from zero. - --retry-all-errors so a mid-transfer stall is retried - --continue-at - to resume into the existing .part instead of restarting, and bump retries to 5 - ignore .DS_Store, which is not covered today Verified: a fresh download and a resume from a 5 MB partial produce the same sha256; a 404 still aborts and leaves nothing behind; a stale .part resumes into an invalid file, which the existing "recognized" check catches before pytest with the make clean hint. --- .gitignore | 3 +++ Makefile | 10 +++++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index f534e8b..d040974 100644 --- a/.gitignore +++ b/.gitignore @@ -113,3 +113,6 @@ tests/file.mkv tests/file-test.mkv tests/file_2.mkv .profiles + +# macOS +.DS_Store diff --git a/Makefile b/Makefile index 14fce26..cba71c7 100644 --- a/Makefile +++ b/Makefile @@ -7,9 +7,13 @@ TEST_TWO_FILE := tests/file_2.mkv TEST_DIR := tests/ -# --fail makes curl exit non-zero on HTTP errors instead of writing the error -# body into the target file, which would leave a corrupt "MKV" behind. -CURL := curl -sSL --fail --retry 3 --retry-delay 2 +# --fail exits non-zero on HTTP errors instead of writing the error body into the +# target file, which would leave a corrupt "MKV" behind. +# --retry alone does not cover a stall mid-transfer ("curl: (56) Recv failure"), +# which is how a 71 MB download actually fails on a flaky runner, so +# --retry-all-errors is needed. --continue-at - resumes into the same .part file +# rather than restarting from zero on every attempt. +CURL := curl -sSL --fail --retry 5 --retry-delay 2 --retry-all-errors --continue-at - .PHONY: test clean