12
0
Fork 0
mirror of https://github.com/actions/setup-go.git synced 2026-07-01 02:30:46 +00:00

Bump @actions/cache to 5.1.0, log cache write denied (#758)

* Bump @actions/cache to 5.1.0, log cache write denied

* Add cache save tests

* Re-trigger CI
This commit is contained in:
Jason Ginchereau 2026-06-22 09:14:01 -10:00 committed by GitHub
parent 4a2405e6ae
commit e91cc3bfe0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 258 additions and 17 deletions

View file

@ -81,6 +81,10 @@ const cachePackages = async () => {
const cacheId = await cache.saveCache(cachePaths, primaryKey);
if (cacheId === -1) {
// saveCache returns -1 without throwing when the cache was not saved, e.g.
// a reserve collision or a read-only token (fork PR). @actions/cache has
// already logged the reason at the appropriate severity, so just trace it.
core.debug(`Cache was not saved for the key: ${primaryKey}`);
return;
}
core.info(`Cache saved with the key: ${primaryKey}`);