!!!滴滴滴,今天编代码又发现了新的问题,本来一个很简单的爬虫,结果还没四五行代码就卡住了。代码如下:
import requests
url = 'https://nba.hupu.com/players/jamesharden-3306.html'
headers = {
'user-agent':'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.25 Safari/537.36 Core/1.70.3861.400 QQBrowser/10.7.4313.400'
}
type = sys.getfilesystemencoding()