Python Can';我无法在Tweepy中获取有关状态方法的全文
我无法获取状态的全文。 我试过“status.full_text”和一些类似的东西,但是status没有这样的属性 相反,Python Can';我无法在Tweepy中获取有关状态方法的全文,python,api,twitter,tweepy,Python,Api,Twitter,Tweepy,我无法获取状态的全文。 我试过“status.full_text”和一些类似的东西,但是status没有这样的属性 相反, tweets = api.search(q='athens', tweet_mode='extended') for tweet in tweets: print(tweet.full_text) 这很管用。tweet似乎有“全文”属性,但没有状态 那么,为了获得状态的全文,我必须在下面的代码中更改什么 class MyStreamListener(tweepy
tweets = api.search(q='athens', tweet_mode='extended')
for tweet in tweets:
print(tweet.full_text)
这很管用。tweet似乎有“全文”属性,但没有状态
那么,为了获得状态的全文,我必须在下面的代码中更改什么
class MyStreamListener(tweepy.StreamListener):
def on_status(self, status):
print(status.text)
my_stream_listener = MyStreamListener()
my_stream = tweepy.Stream(auth=api.auth, listener=myStreamListener, tweet_mode='extended')
my_stream.filter(track=['Athens'])
尝试
status.extended_tweet[“全文”]
,如前所述