Retry directory deletion to avoid Windows file locking issues.
Co-authored-by: Andrew Eisenberg <aeisenberg@github.com>
This commit is contained in:
parent
86940df49f
commit
d63f798314
3 changed files with 3 additions and 3 deletions
|
|
@ -425,7 +425,7 @@ export async function runFinalize(
|
|||
|
||||
// After switching to Node16, this entire block can be replaced with `await fs.promises.rm(outputDir, { recursive: true, force: true });`.
|
||||
try {
|
||||
await fs.promises.rmdir(outputDir, { recursive: true });
|
||||
await fs.promises.rmdir(outputDir, { recursive: true, maxRetries: 5 });
|
||||
} catch (error: any) {
|
||||
if (error?.code !== "ENOENT") {
|
||||
throw error;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue