From de5307dfa04e57027875b8c3bc4218b3f26e78b0 Mon Sep 17 00:00:00 2001 From: Mohamed Boudra Date: Fri, 19 Jun 2026 05:11:52 +0700 Subject: [PATCH] Retry browser test dependency installs --- .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2afaecff5..ae37945f7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -189,8 +189,19 @@ jobs: node-version: "22" cache: "npm" - - name: Install dependencies - run: npm ci + - name: Install dependencies with retry + run: | + for attempt in 1 2 3; do + if npm ci; then + exit 0 + else + exit_code=$? + fi + if [ "$attempt" -eq 3 ]; then + exit $exit_code + fi + sleep $((attempt * 20)) + done - name: Install Playwright browsers timeout-minutes: 10 @@ -241,8 +252,19 @@ jobs: node-version: "22" cache: "npm" - - name: Install dependencies - run: npm ci + - name: Install dependencies with retry + run: | + for attempt in 1 2 3; do + if npm ci; then + exit 0 + else + exit_code=$? + fi + if [ "$attempt" -eq 3 ]; then + exit $exit_code + fi + sleep $((attempt * 20)) + done - name: Install Playwright browsers timeout-minutes: 10