Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit Exceeded #18

Closed
scoobie-bot opened this issue Dec 27, 2021 · 4 comments
Closed

Limit Exceeded #18

scoobie-bot opened this issue Dec 27, 2021 · 4 comments

Comments

@scoobie-bot
Copy link

I have been trying to keep an updated price of an ASA.
It was originally checking at 10 second intervals, I have also tried it at 30 second intervals.
It can run happily for anywhere between 2 and 8 hrs, but then I get the 429 error and limit exceeded message.
Once banned / blocked, there doesn't seem to be any clue as to when I will be unblocked.

The error comes directly from calling:
pool = client.fetch_pool
then
quote = pool.fetch_fixed_input_swap_quote
I'm using the standard example code for getting the swap quotes

  1. What are the API limits?
  2. Is there any way to catch this before it triggers the block / ban?
  3. Is this something tinyman-py-sdk should handle, or is it an algod issue?

I haven't been able to find anything about the API rate limit online

@efe
Copy link
Contributor

efe commented Dec 27, 2021

@scoobie-bot
3) The response comes from the algod. I think that this is not responsibility of the tinyman-py-sdk package. It is depends on the algod server which you use.

@majestique
Copy link

@scoobie-bot 3) The response comes from the algod. I think that this is not responsibility of the tinyman-py-sdk package. It is depends on the algod server which you use.

Does this mean the limit is on the VPS server we're on? If it's algod's API limit, is there documentation on limits? I can't seem to find it

@efe
Copy link
Contributor

efe commented Jan 17, 2022

Does this mean the limit is on the VPS server we're on?
You shouldn't have got HTTP 429 if it is a limitation of VPS.

algod is an actually a client for Algod Server. In this case, the response comes from (most probably AlgoExplorer server). Then, algod just displays the 429 response.

I don't know that is there a documentation of Algoexplorer APIs.

My suggestion is that just put time.sleep() between your requests and try to avoid rate limiting.

@gokselcoban
Copy link
Contributor

Looks like this page has some info about default rate limiting. Please check ConnectionsRateLimitingCount, ConnectionsRateLimitingWindowSeconds settings. I think they are subject to change for each node runner.

I am closing this issue because the topic is not related to the SDK. Thank you for your contributions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants