Skip to content

Commit 3a3d169

Browse files
committed
feat: log errors on retry
1 parent a5c7f26 commit 3a3d169

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/cli.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,12 @@ const cmd = command({
252252
try {
253253
await retry(() => item.download(args.outDir, options), {
254254
retries: args.maxRetries,
255+
onRetry(e, r) {
256+
console.error(e);
257+
console.error(
258+
`Download failed. Retrying. (${r}/${args.maxRetries})`
259+
);
260+
},
255261
});
256262
} catch (e) {
257263
err = e;

0 commit comments

Comments
 (0)