Skip to content

Commit 7d8d370

Browse files
committed
ci: clear npm cache on Windows to prevent corruption
Windows GitHub Actions runners have a known issue with npm cache corruption that causes 'ECOMPROMISED: Lock compromised' errors. This adds a cache clean step before tests on Windows to work around the issue. The step uses continue-on-error to ensure it doesn't fail if the cache is already clean.
1 parent 5ddb551 commit 7d8d370

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/test.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,11 @@ jobs:
7676
with:
7777
node-version: "24"
7878

79+
- name: Clear npm cache on Windows
80+
if: runner.os == 'Windows'
81+
run: npm cache clean --force
82+
continue-on-error: true
83+
7984
- uses: astral-sh/setup-uv@v7
8085
with:
8186
enable-cache: true

0 commit comments

Comments
 (0)