diff --git a/clearml/backend_api/utils.py b/clearml/backend_api/utils.py index c5f78c82..0b34c28b 100644 --- a/clearml/backend_api/utils.py +++ b/clearml/backend_api/utils.py @@ -129,7 +129,10 @@ def get_http_session_with_retry( session.trust_env = False if backoff_max is not None: - Retry.DEFAULT_BACKOFF_MAX = backoff_max + if "BACKOFF_MAX" in vars(Retry): + Retry.BACKOFF_MAX = backoff_max + else: + Retry.DEFAULT_BACKOFF_MAX = backoff_max retry = Retry( total=total, connect=connect, read=read, redirect=redirect, status=status,