From 6561396429ad8f6bcbce596b650718d99734030b Mon Sep 17 00:00:00 2001 From: krishanbhasin-gc Date: Fri, 21 Apr 2023 16:27:00 +0100 Subject: [PATCH] add a fallback restore-key for poetry cache --- src/cache-distributions/poetry-cache.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cache-distributions/poetry-cache.ts b/src/cache-distributions/poetry-cache.ts index c31fb05d4..2dcf761a1 100644 --- a/src/cache-distributions/poetry-cache.ts +++ b/src/cache-distributions/poetry-cache.ts @@ -48,7 +48,7 @@ class PoetryCache extends CacheDistributor { const hash = await glob.hashFiles(this.patterns); // "v2" is here to invalidate old caches of this cache distributor, which were created broken: const primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-v2-${hash}`; - const restoreKey = undefined; + const restoreKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-`; return { primaryKey, restoreKey