API request error handling, rate-limiting, and batching
Closed this issue · 0 comments
JWCook commented
Moving this from #16. Getting occasional TooManyRequestsForUrl
response from iNaturalist API when loading lots of taxon thumbnails. Mainly for children of the currently selected taxon (esp. when listing a large number of species under a genus)
- Exception handling
- Throttling for large requests
- Batching for large requests (instead of several small requests for each taxon)
- But also check API request cache for individual taxa before making batch request?
- Delayed retries
- Keep track of requests per minute and per hour to stay under limits
- Fine-tuning for request caching? It works, but it's not very intelligent right now.