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

Cache rate limiting info from Twitter API #154

Open
10 tasks
JSn1nj4 opened this issue Sep 20, 2023 — with Volta.net · 0 comments
Open
10 tasks

Cache rate limiting info from Twitter API #154

JSn1nj4 opened this issue Sep 20, 2023 — with Volta.net · 0 comments
Assignees

Comments

Copy link
Owner

JSn1nj4 commented Sep 20, 2023

Only reason this is separate from #135 is because I won't be posting enough from my website for this to become a problem. It's safe to implement this separately, after gathering some request logs.

  • Cache remaining rate limit
  • Cache time remaining until reset - rather, try for date (now() + seconds if that's what I'm given)
  • Ensure not currently rate limited
    • If under limit...
      • continue with posting
      • update remaining limit on success -- from header, not manually
    • If timer expired...
      • unset both and continue posting
      • re-cache both - maybeCacheRateLimit($headers) or similar method?
    • Otherwise fail with rate limited - failed result/error logging
@JSn1nj4 JSn1nj4 self-assigned this Oct 12, 2023
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

1 participant