Skip to content

Commit

Permalink
Workaround for actions/toolkit#1377
Browse files Browse the repository at this point in the history
  • Loading branch information
azrsh committed Jul 19, 2023
1 parent 6d9f211 commit 4add2c2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
4 changes: 3 additions & 1 deletion dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -58581,7 +58581,9 @@ function bundleInstall() {
restoreKeys: [baseKey],
};
core.info(`cache options: ${JSON.stringify(cacheOptions)}`);
const cacheHit = yield cache.restoreCache(cacheOptions.paths, cacheOptions.primaryKey, cacheOptions.restoreKeys);
const cacheHit = yield cache.restoreCache(
// https://github.com/actions/toolkit/issues/1377
cacheOptions.paths.slice(), cacheOptions.primaryKey, cacheOptions.restoreKeys);
core.info(`cache hit: ${cacheHit}`);
core.info(`cache options: ${JSON.stringify(cacheOptions)}`);
yield exec.exec("bundle", ["install"], execOptions);
Expand Down
2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion src/bundler_cache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@ export async function bundleInstall() {

core.info(`cache options: ${JSON.stringify(cacheOptions)}`);
const cacheHit = await cache.restoreCache(
cacheOptions.paths,
// https://github.com/actions/toolkit/issues/1377
cacheOptions.paths.slice(),
cacheOptions.primaryKey,
cacheOptions.restoreKeys
);
Expand Down

0 comments on commit 4add2c2

Please sign in to comment.