From 0f432bafebfe8c2c8e11eaaf1e8f70ef54678e5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ion=20Gazta=C3=B1aga?= Date: Sat, 13 Dec 2025 17:21:06 +0100 Subject: [PATCH] Make apt update more robust adding sleeps betwen retries --- .github/workflows/ci.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7f43aa4..a82bf97 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -441,7 +441,9 @@ jobs: echo "GHA_CONTAINER=${{matrix.container}}" >> $GITHUB_ENV if [ -f "/etc/debian_version" ] then - apt-get -o Acquire::Retries=$NET_RETRY_COUNT update + for i in $(seq 1 $NET_RETRY_COUNT); do + apt-get update && break || sleep 5 + done if [ "$(apt-cache search "^python-is-python3$" | wc -l)" -ne 0 ] then PYTHON_PACKAGE="python-is-python3" @@ -507,7 +509,9 @@ jobs: done done fi - sudo apt-get -o Acquire::Retries=$NET_RETRY_COUNT update + for i in $(seq 1 $NET_RETRY_COUNT); do + apt-get update && break || sleep 5 + done sudo apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y ${{join(matrix.install, ' ')}} - name: Setup GCC Toolchain