Comparing version 4.0.0 to 4.0.1
import { rename, writeFile } from 'node:fs/promises'; | ||
import { basename, dirname, join } from 'node:path'; | ||
import { fileURLToPath } from 'node:url'; | ||
import retry from 'async-retry'; | ||
// Returns a temporary file | ||
@@ -38,3 +39,7 @@ // Example: for /some/file will return /some/.file.tmp | ||
await writeFile(this.#tempFilename, data, 'utf-8'); | ||
await rename(this.#tempFilename, this.#filename); | ||
await retry(async () => { | ||
await rename(this.#tempFilename, this.#filename); | ||
}, { | ||
minTimeout: 100, | ||
}); | ||
// Call resolve | ||
@@ -41,0 +46,0 @@ this.#prev?.[0](); |
{ | ||
"name": "steno", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"description": "Specialized fast async file writer", | ||
@@ -51,2 +51,3 @@ "keywords": [ | ||
"@sindresorhus/tsconfig": "^5.0.0", | ||
"@types/async-retry": "^1.4.8", | ||
"@types/node": "^20.8.3", | ||
@@ -61,3 +62,6 @@ "@typicode/eslint-config": "^1.2.0", | ||
"node": ">=18" | ||
}, | ||
"dependencies": { | ||
"async-retry": "^1.3.3" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6665
84
1
11
+ Addedasync-retry@^1.3.3
+ Addedasync-retry@1.3.3(transitive)
+ Addedretry@0.13.1(transitive)