0

I want get tweets with tweepy 4.14.0. I tried this code:

auth = tweepy.OAuthHandler(consumer_key, consumer_secret)

auth.set_access_token(access_token, access_token_secret)

api = tweepy.API(auth)

api.search_tweets(q="nasa", geocode="40.699,-73.975,10km",
                  lang="en", result_type="popular",
                  count=100, until=since_date)

But I am facing the following error:

TweepyException: Failed to send request: ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))

But I am facing the following error. How can I fix this error?

Ali Hosein pour
  • 220
  • 4
  • 19
  • Twitter has a rate limit. You cannot exceed that, otherwise, the error you're generating will appear. View [this question](https://stackoverflow.com/q/44914315/9731347), which has a similar scenario. Follow up if this does not work for you. – SanguineL May 19 '23 at 15:12

0 Answers0