Skip to content

Commit 9e88127

Browse files
committed
Be graceful about concurrent attempts to cache the artifact
Just warn the user about it, and move on. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent ca6bd93 commit 9e88127

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

main.ts

+6-2
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,12 @@ async function run(): Promise<void> {
4747
verbose.match(/^\d+$/) ? parseInt(verbose) : verbose === 'true'
4848
)
4949

50-
if (useCache && !(await saveCache([outputDirectory], id))) {
51-
core.warning(`Failed to cache ${id}`)
50+
try {
51+
if (useCache && !(await saveCache([outputDirectory], id))) {
52+
core.warning(`Failed to cache ${id}`)
53+
}
54+
} catch (e) {
55+
core.warning(`Failed to cache ${id}: ${e.message}`)
5256
}
5357
}
5458

0 commit comments

Comments
 (0)