2
在過去的2周左右,我的一個Twitter清理腳本停止工作。看起來,不再有用於刪除發送的DM的destroy_message屬性。這是刪除或重命名?這是我的代碼和錯誤。AttributeError:'Twython'對象沒有屬性'destroy_message'
for tweet in tweets:
print "Deleting: " + tweet["text"]
result = self._api.destroy_message(id = tweet["id"])
以下是錯誤:
Getting sent DMs....
Deleting: Sure no problem
Traceback (most recent call last):
File "scrub_twitter.py", line 127, in <module>
obj.delete_sent_dms()
File "scrub_twitter.py", line 102, in delete_sent_dms
result = self._api.destroy_message(id = tweet["id"])
AttributeError: 'Twython' object has no attribute 'destroy_message'
謝謝主席先生,我一直想知道爲什麼在發送和接收摧毀沒有合併。這解決了它。 – killpacket 2015-02-24 03:02:22