From 68a5017d5b42269911ac6088c253cd718bd55417 Mon Sep 17 00:00:00 2001 From: moveson Date: Wed, 19 Aug 2026 11:07:36 -0600 Subject: [PATCH] Fail fast and retry when apt hangs installing libvips The Install libvips step has twice hung for 40+ minutes on a wedged apt mirror (two shards each on 2026-08-18 and 2026-08-19), forcing a manual cancel and rerun. Bound each apt command with a timeout and retry up to three times, with a 5-minute ceiling on the whole step. Co-Authored-By: Claude Fable 5 --- .github/workflows/verify.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index fa080bf55..992d55b56 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -185,7 +185,17 @@ jobs: cache-version: ${{ steps.runner-image.outputs.fingerprint }} - name: Install libvips - run: sudo apt-get update && sudo apt-get install -y --no-install-recommends libvips42 + timeout-minutes: 5 + run: | + for attempt in 1 2 3; do + if timeout 90 sudo apt-get update -o Acquire::Retries=3 -o Acquire::http::Timeout=15 && + timeout 90 sudo apt-get install -y --no-install-recommends -o Acquire::Retries=3 -o Acquire::http::Timeout=15 libvips42; then + exit 0 + fi + echo "apt attempt ${attempt} failed or timed out; retrying" + sleep 5 + done + exit 1 - name: Download assets uses: actions/download-artifact@v8