From 6795522199251391c63d96635c37a1411b5130c2 Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 14 Feb 2026 11:15:18 +0000 Subject: [PATCH] fix: improve yarn cache strategy to prevent immutable lockfile errors - Cache .yarn/cache instead of node_modules to avoid inconsistencies - Include both yarn.lock and package.json in cache key hash - Update restore-keys to be more specific with package.json hash - This prevents CI from using stale caches after dependency updates https://claude.ai/code/session_015R3U3kiprQiNTTNNt31Sg6 --- .github/workflows/build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e5156277..dbee3965 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -38,11 +38,11 @@ jobs: id: yarn-cache with: path: | - node_modules + .yarn/cache .yarn/install-state.gz - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock', 'package.json') }} restore-keys: | - ${{ runner.os }}-yarn- + ${{ runner.os }}-yarn-${{ hashFiles('package.json') }}- - name: Install dependencies env: