Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ayon_api/server_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1419,7 +1419,7 @@ def _download_file_to_stream(
requests.exceptions.Timeout,
requests.exceptions.ConnectionError,
):
if attempt == retries:
if attempt == retries - 1:
Copy link
Contributor Author

@rdelillo rdelillo Mar 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

range(3) == [0, 1, 2]

raise
progress.next_attempt()

Expand Down Expand Up @@ -1838,7 +1838,7 @@ def _upload_file(
requests.exceptions.Timeout,
requests.exceptions.ConnectionError,
):
if attempt == retries:
if attempt == retries - 1:
raise
progress.next_attempt()
progress.reset_transferred()
Expand Down
Loading