Skip to content
This repository has been archived by the owner on Nov 10, 2024. It is now read-only.

get_timeline() retryonratelimit = T not working for me #462

Closed
ValweM opened this issue Jan 8, 2021 · 6 comments
Closed

get_timeline() retryonratelimit = T not working for me #462

ValweM opened this issue Jan 8, 2021 · 6 comments
Labels

Comments

@ValweM
Copy link

ValweM commented Jan 8, 2021

Hi there,

I tried to use your great function get_timeline() but unfortunately the retryonratelime = TRUE is not working for me. Maybe it's some bug?

Thanks for the help!

@llrs
Copy link
Collaborator

llrs commented Jan 8, 2021

Could you provide more information: What does it mean it is not working for me? Do you get an error, a message, nothing? What code and rtweet version are you using?

@ValweM
Copy link
Author

ValweM commented Jan 8, 2021

Thanks for your quick answer. I used this code:

timeline <- get_timeline(x, n =3200, retryonratelimit = T, include_rts =T)

If I run this code, after a while, I get an Error:
"Warnung: Rate limit exceeded - 88"

Edit: I ran the code yesterday, there was no problem.

@llrs
Copy link
Collaborator

llrs commented Jan 8, 2021

retryonratelimit is not a parameter of get_timeline on version 0.7.0. Are you using the premium API or a modified/older version of rtweet?

@ValweM
Copy link
Author

ValweM commented Jan 9, 2021

Yes I'm working with version 0.7.0. That is odd, on thursday I could extract the same tweets of the same number of accounts without an error. So this means I have to basically use a loop to extract the tweets of more than 52 accounts? Seen like here: #136 ?

@llrs
Copy link
Collaborator

llrs commented Jan 9, 2021

Yes, basically with the APIv1 you can't get around this, that I know of. Maybe the new API of twitter can handle this, but it is not currently supported on rtweet

@Arf9999
Copy link

Arf9999 commented Jan 10, 2021

The endpoint to the API for get_timeline has a rate limit of 900 requests per 15 minutes. Each request will deliver up to 200 statuses. So for each timeline of 3200 statuses (the max the API will deliver), you'll use 16 requests. So the maximum that you'll be able to pull in 15 minutes is around 56 accounts if all have 3200 or more statuses.

To overcome this issue, you can loop and create your own ratelimit pause using the rate_limits("get_timeline") function. The "reset" column will give you a report on how long it is until the rate_limit is reset.

@llrs llrs mentioned this issue Feb 15, 2021
@llrs llrs added the question label Feb 18, 2021
@llrs llrs closed this as completed Feb 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants