Q: How to specify more than one coordinates for geocode parameter of API.search in Tweepy I want to search tweets based on more than one coordinates. So, I tried this but it doesn't return any results:
total = 0
for status in tweepy.Cursor(api.search, q='cricket', lang="en",
                            geocode="24.8607,67.0011,25mi OR 40.7128,74.0060,20mi"
                           ).items(10):
    total+=1

print(total)


A: It's been a while since @Tayyap Mazhar shared the post, but just in case, the code below will work as expected. Just remember, do not put comma while declaring geoc variable!
import tweepy
import pandas as pd

CONSUMER_KEY = "?"
CONSUMER_SECRET = "?"
OAUTH_TOKEN = "?"
OAUTH_TOKEN_SECRET = "?"

auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
auth.set_access_token(OAUTH_TOKEN, OAUTH_TOKEN_SECRET)
auth.secure = True
api = tweepy.API(auth, wait_on_rate_limit=True,
wait_on_rate_limit_notify=True)

if (not api):
    print ("Can't Authenticate")
    sys.exit(-1)

tweet_lst=[]
geoc=[('41.0,28.9499962,1km'),('41.1062629083,29.0264182277,1km'),('41.072833042,29.022833242,1km'),('41.05,28.91,1km')]


for geocode in geoc:
    for tweet in tweepy.Cursor(api.search,geocode=geocode).items(1000):
        tweetDate = tweet.created_at.date()
        if(tweet.coordinates !=None):
            tweet_lst.append([tweetDate,tweet.id,tweet.
            coordinates['coordinates'][0],
            tweet.coordinates['coordinates'][1],
            tweet.user.screen_name,
            tweet.user.name, tweet.text,
            tweet.user._json['geo_enabled']])
            tweet_df = pd.DataFrame(tweet_lst, columns=['tweet_dt', 'id', 'long','lat','username', 'name', 'tweet','geo'])```


