-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Continue retrying downloads on retriable statuses #1558
Conversation
dandi/download.py
Outdated
path, | ||
attempt, | ||
exc, | ||
) | ||
elif attempt >= attempts_allowed: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yarikoptic Question: Shouldn't this check be at the top of the function? Otherwise, if we keep hitting, say, 500 responses, it'll keep retrying beyong the maximum number of attempts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indeed. But after potential increment of attempts_allowed
in the "aggressive" mode.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in bb05a23.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1558 +/- ##
==========================================
+ Coverage 88.38% 88.53% +0.14%
==========================================
Files 78 78
Lines 10736 10735 -1
==========================================
+ Hits 9489 9504 +15
+ Misses 1247 1231 -16
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
I think this is legit, I want to propose further changes. Will follow up with a PR "shortly". |
🚀 PR was released in |
Closes #1556.