Add explicit process.exit() to avoid wait for hanging promises

When using the `@actions/cache` library to save cache entries, it seems that one
or more Promises remain unresolved after the save completes.
With Node20 this causes a delay when exiting the process: the default behaviour
now wait for these Promises to complete. Adding an explicit `Process.exit()`
removes the delay, returning to the Node 16 behaviour.

Fixes #1038
This commit is contained in:
daz 2024-01-16 17:43:55 -07:00
parent 346645706f
commit 42452daeb5
No known key found for this signature in database
7 changed files with 16 additions and 8 deletions

1
dist/main/index.js vendored
View file

@ -140762,6 +140762,7 @@ function run() {
core.info(error.stack);
}
}
process.exit();
});
}
exports.run = run;