-
Notifications
You must be signed in to change notification settings - Fork 136
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
Rate Limit Exceeded with Fast argument ON #24
Comments
I'm having the same issue |
i'm having the same problem as well, did anyone find a solution? |
@ebravofm @joaoakio @jimeneztyler
botornot.character <- function(x, fast = FALSE) { to botornot.character <- function(x, fast = FALSE) {
library(devtools)
I've also opened a pull request to make those changes to this repo to fix this issue. |
@Jupaoqq thanks so much! This worked for me |
Hi, i'm back again with the same issue. I have a large list of user names and keep getting the rate limit exceeded message when running tweetbotornot. I edited the code to include @Jupaoqq suggestion, which worked previously but isn't this time. Any ideas on whats going on? or is anyone else having this issue? |
Hi!
I'm running this snippet on a csv file containing 200 user names:
library("tweetbotornot")
rts <- read.csv(file="rts.csv", header=TRUE, sep=",")
data <- tweetbotornot(rts$Twitter.Name, fast = TRUE)
I'm setting the fast argument on, however I'm getting this error:
Warning message:
“Rate limit exceeded - 88”
Error in if (n%/%200 < n.times) {: argument is of length zero
Traceback:
. parse = TRUE, check = TRUE, token = NULL)
. check = TRUE, token = NULL, ...)
. {
. stopifnot(is_n(n), is.atomic(user), is.atomic(max_id), is.logical(home))
. if (home) {
. query <- "statuses/home_timeline"
. }
. else {
. query <- "statuses/user_timeline"
. }
. if (length(user) > 1) {
. stop("can only return tweets for one user at a time.",
. call. = FALSE)
. }
. token <- check_token(token)
. if (check) {
. rl <- rate_limit(token, query)
. n.times <- rl[["remaining"]]
. if (n%/%200 < n.times) {
. n.times <- ceiling(n/200L)
. }
. }
. else {
. rl <- NULL
. n.times <- ceiling(n/200L)
. }
. if (n.times == 0L) {
. if (!is.null(rl)) {
. reset <- round(as.numeric(rl[["reset"]], "mins"),
. 2)
. }
. else {
. reset <- "An unknown number of"
. }
. warning("rate limit exceeded. ", round(reset, 2), " mins until rate limit resets.",
. call. = FALSE)
. return(data.frame())
. }
. if (n < 200) {
. count <- n
. }
. else {
. count <- 200
. }
. params <- list(user_type = user, count = count, max_id = max_id,
. tweet_mode = "extended", ...)
. names(params)[1] <- .id_type(user)
. url <- make_url(query = query, param = params)
. tm <- scroller(url, n, n.times, type = "timeline", token)
. if (parse) {
. tm <- tweets_with_users(tm)
. }
. tm
. })(user = dots[[1L]][[1L]], n = dots[[2L]][[1L]], home = dots[[3L]][[1L]],
. max_id = NULL, parse = TRUE, check = TRUE, token = NULL)
Am i doing something wrong?
Thanks!
The text was updated successfully, but these errors were encountered: