From 34991dbe113e03fe7cdde557a25ed3fbb64b3eb3 Mon Sep 17 00:00:00 2001 From: Hirek193 Date: Wed, 11 Nov 2026 20:08:59 +0000 Subject: [PATCH] apt timeout and retry (#329) --- .github/workflows/build.yml | 8 ++++++++ .github/workflows/build_bin.yml | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d189382fa..758b4c8d5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -41,8 +41,16 @@ jobs: with: python-version: '3.14' + # A mirror that stops answering used to hold this step for over an hour. + # Time out each download, retry it, and give up on the whole step early. - name: Install build dependencies + timeout-minutes: 15 run: | + printf '%s\n' \ + 'Acquire::Retries "3";' \ + 'Acquire::http::Timeout "60";' \ + 'Acquire::https::Timeout "60";' \ + | sudo tee /etc/apt/apt.conf.d/80-ci-retries > /dev/null sudo apt-get update -y sudo apt-get install -y \ build-essential \ diff --git a/.github/workflows/build_bin.yml b/.github/workflows/build_bin.yml index ce4731dd0..41c2c35f0 100644 --- a/.github/workflows/build_bin.yml +++ b/.github/workflows/build_bin.yml @@ -209,8 +209,16 @@ jobs: with: python-version: "3.14" + # A mirror that stops answering used to hold this step for over an hour. + # Time out each download, retry it, and give up on the whole step early. - name: Install Linux dependencies + timeout-minutes: 15 run: | + printf '%s\n' \ + 'Acquire::Retries "3";' \ + 'Acquire::http::Timeout "60";' \ + 'Acquire::https::Timeout "60";' \ + | sudo tee /etc/apt/apt.conf.d/80-ci-retries > /dev/null sudo apt-get update sudo apt-get install -y \