Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin Su <[email protected]>
  • Loading branch information
pingsutw committed Mar 21, 2024
1 parent ffc0316 commit 912bd06
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions s3fs/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,13 +118,13 @@ async def _error_wrapper(func, *, args=(), kwargs=None, retries):
except ClientError as e:
logger.debug("Client error (maybe retryable): %s", e)
err = e
wait_time = asyncio.sleep(min(1.7**i * 0.1, 15))
wait_time = min(1.7**i * 0.1, 15)
if "SlowDown" in str(e):
await wait_time
await asyncio.sleep(wait_time)
elif "reduce your request rate" in str(e):
await wait_time
await asyncio.sleep(wait_time)
elif "XAmzContentSHA256Mismatch" in str(e):
await wait_time
await asyncio.sleep(wait_time)
else:
break
except Exception as e:
Expand Down

0 comments on commit 912bd06

Please sign in to comment.