用python對twitter進行數據挖掘之TimeoutError

問題一:

TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connectio n failed because connected host has failed to respond

解決:
打開vpn的全局代理,重啓jupyter notebook因爲PAC智能代理並不能在程序中使用。關於科學上網,實在有需要就留言。

問題二:
HttpError
{“errors”:[{“message”:”Could not authenticate you”,”code”:32}]}

解決:
在twitter API的網頁下(就是你哪裏獲得授權令牌的),點擊

egenerating the access token  按鈕

這裏寫圖片描述

最後重新輸入各項信息就行啦。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章