From ee5aaa20015b090512182432f31e8bcce226459f Mon Sep 17 00:00:00 2001 From: Igor Sirotin Date: Thu, 21 May 2026 10:15:00 +0100 Subject: [PATCH] ci: bump nimble deps cache key + add restore-keys The nimbledeps cache key was based only on hashFiles(nimble.lock, ...), which hasn't changed, so PRs kept restoring a stale, incomplete master cache. GitHub caches are immutable per key, so that poisoned cache was never refreshed and `make all` re-resolved/re-downloaded deps every run. Add a bumpable NIMBLE_CACHE_VERSION token to abandon the poisoned cache and restore-keys for warm starts. `nimble setup --localdeps` fully installs the locked dep set, so a fresh v2 cache will be complete. Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/workflows/ci.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 21343b1b1..979f16790 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,6 +16,8 @@ env: NIMFLAGS: "--parallelBuild:${NPROC} --colors:off -d:chronicles_colors:none" NIM_VERSION: '2.2.4' NIMBLE_VERSION: '0.22.3' + # Bump to invalidate the nimble deps cache (GitHub caches are immutable per key). + NIMBLE_CACHE_VERSION: 'v2' jobs: changes: # changes detection @@ -108,7 +110,9 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + restore-keys: | + ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}- - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' @@ -187,7 +191,9 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + restore-keys: | + ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}- - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' @@ -268,7 +274,9 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + restore-keys: | + ${{ runner.os }}-nimbledeps-${{ env.NIMBLE_CACHE_VERSION }}-nimble${{ env.NIMBLE_VERSION }}- - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true'