zhulik / aiotractive

Asynchronous Python client for the Tractive REST API
MIT License
21 stars 6 forks source link

Wait and retry if too many requests #20

Closed bieniu closed 4 months ago

bieniu commented 1 year ago

A user with 5 trackers configured with his Tractive account reported a problem with the Too Many Requests API response: https://github.com/home-assistant/core/issues/99121#issuecomment-1702549320 I'm trying to find the perfect sleep value when we reach the limit of allowed requests.

@hupfis Sorry to disturb you. If I understand correctly, you have direct contact with Tractive. Maybe you can give some hint how long we should wait before making another request if we get Too Many Requests response?

bieniu commented 1 year ago

After testing several possibilities, 3 seconds seems like a good value. I mark the PR as ready for review.

bieniu commented 5 months ago

@zhulik Could we go back to reviewing this PR?

bieniu commented 4 months ago

@zhulik Could you please look at this change? Users have been waiting for this fix for a really long time.

bieniu commented 4 months ago

Thanks!