This commit is contained in:
Lonami 2020-05-13 18:50:37 +02:00 committed by GitHub
parent 9ba93285f8
commit 8edf59e565
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -92,6 +92,8 @@ class UserMethods:
self._flood_waited_requests\
[request.CONSTRUCTOR_ID] = time.time() + e.seconds
# In test servers, FLOOD_WAIT_0 has been observed, and sleeping for
# such a short amount will cause retries very fast leading to issues.
if e.seconds == 0:
e.seconds = 1