我正在使用 tweepy 通过这里包含的脚本从用户的时间线中获取推文。 但是,推文被截断了:
auth = tweepy.OAuthHandler(consumer_key, consumer_secret)
auth.set_access_token(access_key, access_secret)
api = tweepy.API(auth)
new_tweets = api.user_timeline(screen_name = screen_name,count=200, full_text=True)
返回:
Status(contributors=None,
truncated=True,
text=u"#Hungary's new bill allows the detention of asylum seekers
& push backs to #Serbia. We've seen push backs before so\u2026 https://
t.co/iDswEs3qYR",
is_quote_status=False,
...
也就是说,对于一些i,new_tweets[i].text.encode("utf-8")
看起来像是这样的
#Hungary's new bill allows the detention of asylum seekers &
push backs to #Serbia. We've seen push backs before so…https://t.co/
iDswEs3qYR
在后者中,...
代替了通常会在Twitter上显示的文本。
有人知道我怎样才能覆盖truncated=True
从而在我的请求中获取完整的文本吗?
new_tweets[0]
。 - atkat12