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

get_pow_ : Too Many Requests (HTTP 429) #836

Closed
samueltsw opened this issue Aug 4, 2020 · 1 comment
Closed

get_pow_ : Too Many Requests (HTTP 429) #836

samueltsw opened this issue Aug 4, 2020 · 1 comment
Labels
Milestone

Comments

@samueltsw
Copy link

samueltsw commented Aug 4, 2020

Hi,

A few days ago, I was able to pull data from POWO using get_pow_ by inputting a vector of scientific names.
powo_data <- get_pow_(unlist(test_data_unique), messages = FALSE)

However, there are errors even I am just trying to pull one scientific name. It seems to be related to the rate limits mentioned in #598
Error: Too Many Requests (HTTP 429) & Error: Bad Gateway (HTTP 502).

Update:
I use a for loop instead to pull data with the use of trycatchand sys.sleep and it's okay now.

Thanks,
Samuel

@sckott
Copy link
Contributor

sckott commented Aug 4, 2020

Thanks for the issue @samueltsw Yes, its related to that issue - and see #598 (comment) - i'll add that information on rate limits to the docs.

your solution is the one i'd use too, sys.sleep between requests

note that they may change rate limits through time, so code that works now may work differently in the future (i.e., need to add more sleep time, or could use less, depending on whether they decreased or increased rate limit)

@sckott sckott added the docs label Aug 4, 2020
@sckott sckott added this to the v0.9.98 milestone Aug 4, 2020
@sckott sckott closed this as completed in 1a1e224 Aug 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants