From 212bc89293db1fa0c4d8a0ef64632626d77b0d54 Mon Sep 17 00:00:00 2001 From: christophe dervieux Date: Thu, 23 Apr 2026 12:20:35 +0200 Subject: [PATCH 1/2] Cache Playwright browsers and bound install timeout in CI MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Install Playwright Browsers step in test-smokes.yml currently has no timeout and re-downloads browser binaries on every run. A recent CI run showed three ubuntu buckets stuck for 2+ hours on this step while another bucket finished the same step in 41 seconds on a sibling runner — the failure mode looks like transient runner/network hangs rather than slow installs. Set PLAYWRIGHT_BROWSERS_PATH at job level to pin the browsers install location to a path under github.workspace that is identical across Linux, Windows, and macOS. This lets a single actions/cache entry restore browsers on any runner OS without the default-per-OS path variance, and ensures install + test steps agree on the location. Cache is keyed on the resolved Playwright version (read via node -p on the installed @playwright/test package.json so the key tracks what npm actually resolved, not the stale lockfile). Keep --with-deps as-is per upstream guidance (microsoft/playwright#20603). Add timeout-minutes: 10 so a stuck runner fails fast instead of blocking the matrix until the 6h job cap. --- .github/workflows/test-smokes.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.github/workflows/test-smokes.yml b/.github/workflows/test-smokes.yml index a5146bb1df..84aef3ad3e 100644 --- a/.github/workflows/test-smokes.yml +++ b/.github/workflows/test-smokes.yml @@ -58,6 +58,8 @@ jobs: - os: windows-latest time-test: true runs-on: ${{ matrix.os }} + env: + PLAYWRIGHT_BROWSERS_PATH: ${{ github.workspace }}/ms-playwright-browsers steps: - name: Checkout Repo uses: actions/checkout@v6 @@ -98,8 +100,26 @@ jobs: working-directory: ./tests/integration/playwright shell: bash + - name: Get Playwright version + if: ${{ runner.os != 'Windows' || github.event_name == 'schedule' }} + run: | + VERSION=$(node -p "require('@playwright/test/package.json').version") + echo "PLAYWRIGHT_VERSION=$VERSION" >> "$GITHUB_ENV" + working-directory: ./tests/integration/playwright + shell: bash + + - name: Cache Playwright browsers + if: ${{ runner.os != 'Windows' || github.event_name == 'schedule' }} + uses: actions/cache@v5 + with: + path: ${{ env.PLAYWRIGHT_BROWSERS_PATH }} + key: ${{ runner.os }}-playwright-${{ env.PLAYWRIGHT_VERSION }} + restore-keys: | + ${{ runner.os }}-playwright- + - name: Install Playwright Browsers if: ${{ runner.os != 'Windows' || github.event_name == 'schedule' }} + timeout-minutes: 10 run: npx playwright install --with-deps working-directory: ./tests/integration/playwright From 56af1dcf2a5d262bc1b09f87b8980bfbc8e6b3c7 Mon Sep 17 00:00:00 2001 From: christophe dervieux Date: Thu, 23 Apr 2026 16:05:53 +0200 Subject: [PATCH 2/2] Trigger second CI run for cache-hit verification