From f7e6ea4d199f63af036410de158e195946bc60ff Mon Sep 17 00:00:00 2001 From: "John T. Wodder II" Date: Fri, 20 Dec 2024 10:46:55 -0500 Subject: [PATCH] Continue retrying downloads on retriable statuses --- dandi/download.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/dandi/download.py b/dandi/download.py index c7dfc1cba..f4b58e3a0 100644 --- a/dandi/download.py +++ b/dandi/download.py @@ -1141,8 +1141,12 @@ def _check_if_more_attempts_allowed( exc, ) else: - lgr.debug("%s - download failed: %s", path, exc) - return None + lgr.debug( + "%s - download failed on attempt #%d: %s, will sleep a bit and retry", + path, + attempt, + exc, + ) elif attempt >= attempts_allowed: lgr.debug("%s - download failed after %d attempts: %s", path, attempt, exc) return None