Skip to content

Fix retry logic

Compare
Choose a tag to compare
@dotX12 dotX12 released this 25 Feb 01:12
· 21 commits to master since this release
f088e77

It looks like the current timeout time is not enough, our end up in max attempts + max timeout 30 seconds and after 429 error.
A fix has been added to increase this max_timeout to 60 seconds.

And also if 60 seconds is not enough for you, you can override the wait timeout.

shazam = Shazam(
    http_client=HTTPClient(
        retry_options=ExponentialRetry(attempts=12, max_timeout=204.8, statuses={500, 502, 503, 504, 429}),
    ),
)