【发布时间】:2020-07-18 12:05:47
【问题描述】:
我可以检查一条推文是否被我转发,但不能检查一条推文是否被收藏。有什么解决办法吗?
except tweet.id(retweeted):
ignore
except tweet.id(???)
ignore
【问题讨论】:
我可以检查一条推文是否被我转发,但不能检查一条推文是否被收藏。有什么解决办法吗?
except tweet.id(retweeted):
ignore
except tweet.id(???)
ignore
【问题讨论】:
id = 1272479136133627905
# fetching the status
status = api.get_status(id)
# fetching the favorited attribute
favorited = status.favorited
if favorited == True:
print("The authenticated user has liked the tweet.")
else:
print("The authenticated user has not liked the tweet.")```
【讨论】: