Open seratch opened 3 years ago
I've implemented a similar thing in the Discovery API SDK: https://github.com/slackapi/python-slack-discovery-sdk/blob/main/slack_discovery_sdk/rate_limit_support.py The ones for the APIs supported by this SDK (especially the Web APIs) would require a bit more complex logic, though.
Now that we have a built-in retry handler for rate limited errors in v3.9, retrying a request after getting rate-limited is much easier than before.
However, getting rate-limited results in a much longer execution time as the whole operation. As a solution for this pain point, we will add a built-in traffic control layer like we do in the Java SDK: https://slack.dev/java-slack-sdk/guides/web-api-basics#rate-limits
A few points to consider for implementing this feature:
time.sleep
in asyncio apps)Category (place an
x
in each of the[ ]
)Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.