This is my code:
query = '"covid vaccine" lang:en'
tweets = tweepy.Cursor(api.search,
q=query,
tweet_mode='extended',
).items(100000)
json_data = [r._json for r in tweets]
I tried to scrape tweets with “covid vaccine” keyword but I got this error:
TweepError: Failed to send request: (‘Connection aborted.’, ConnectionResetError(104, ‘Connection reset by peer’))
I don’t think it’s a cause of unreliable internet connection, because I that error doesn’t show up when scraping data with other keys, I several things but nothing would seem to help.
- tried to scrape data with 3 different networks
- tried with LAN for more reliable connection
- tried sleeping 5 seconds after every request
but nothing worked
How and where are you connecting from? It still seems like a Firewall / Network issue.
Hi! I´m using rtweet in R to extract tweets but today I get the following message:
"Warning: 89 - Invalid or expired token.
Warning message:
rate limit exceeded. mins until rate limit resets. "
I reset, update and by last, create a new token but still I get the same response. Any idea? help!
You shouldn’t reset your token after a rate limit error, the rate limit will still apply. The HTTP headers will contain the timestamp for when the rate limit resets (it’s 15 minute windows)
1 Like
I’m connecting from Armenia with a LAN cable, I tried connecting to different networks and different internet providers, but every time I get the same result . When I scrape small amount of tweets(like 5000, or 10000) everything is ok, but when when I scrape 30000, 40000, or more the issue still remains
2 Likes
system
Closed
#7
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.