From: Harmon Date: Sat, 22 Oct 2022 00:55:53 +0000 (-0500) Subject: Improve documentation for wait_on_rate_limit parameter for streaming X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=7f0d5871bf4afd4bbe0a5b4a47f62e298d2caa7e;p=tweepy.git Improve documentation for wait_on_rate_limit parameter for streaming Resolves part of #1986 --- diff --git a/tweepy/asynchronous/streaming.py b/tweepy/asynchronous/streaming.py index b8bebf5..58eba22 100644 --- a/tweepy/asynchronous/streaming.py +++ b/tweepy/asynchronous/streaming.py @@ -570,7 +570,9 @@ class AsyncStreamingClient(AsyncBaseClient, AsyncBaseStream): return_type : type[dict | requests.Response | Response] Type to return from requests to the API wait_on_rate_limit : bool - Whether to wait when rate limit is reached + Whether or not to wait before retrying when a rate limit is + encountered. This applies to requests besides those that connect to a + stream (see ``max_retries``). max_retries: int | None Number of times to attempt to (re)connect the stream. proxy : str | None diff --git a/tweepy/streaming.py b/tweepy/streaming.py index 9228a9e..145f71d 100644 --- a/tweepy/streaming.py +++ b/tweepy/streaming.py @@ -563,7 +563,9 @@ class StreamingClient(BaseClient, BaseStream): return_type : type[dict | requests.Response | Response] Type to return from requests to the API wait_on_rate_limit : bool - Whether to wait when rate limit is reached + Whether or not to wait before retrying when a rate limit is + encountered. This applies to requests besides those that connect to a + stream (see ``max_retries``). chunk_size : int The default socket.read size. Default to 512, less than half the size of a Tweet so that it reads Tweets with the minimal latency of 2 reads