File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -345,15 +345,20 @@ function download_verify(
345345 mkpath (dirname (dest))
346346
347347 # Download the file, optionally continuing
348- f = retry (delays = fill (1.0 , 3 )) do
348+ attempts = 3
349+ for i in 1 : attempts
349350 try
350351 download (url, dest; verbose= verbose || ! quiet_download)
351352 catch err
352- @debug " download and verify failed" url dest err
353- rethrow ()
353+ @debug " download and verify failed on attempt $i /$attempts " url dest err
354+ # for system errors like `no space left on device` exit after first try
355+ if err isa SystemError || i == attempts
356+ rethrow ()
357+ else
358+ sleep (1 )
359+ end
354360 end
355361 end
356- f ()
357362 if hash != = nothing && ! verify (dest, hash; verbose= verbose)
358363 # If the file already existed, it's possible the initially downloaded chunk
359364 # was bad. If verification fails after downloading, auto-delete the file
You can’t perform that action at this time.
0 commit comments