Traceback (most recent call last): File "G:/PyCharm/workspace/baike_spider/spider_main.py", line 45, in <module> obj_spider.craw(root_url) File "G:/PyCharm/workspace/baike_spider/spider_main.py", line 27, in craw html_cont = self.downloader.download(new_url) File "G:\PyCharm\workspace\baike_spider\html_downloader.py", line 14, in download response = urllib.request.urlopen(url) File "G:\Python36\lib\urllib\request.py", line 223, in urlopencraw 1 : <bound method UrlManager.get_new_url of <url_manager.UrlManager object at 0x000001BDA7F82A58>> return opener.open(url, data, timeout) File "G:\Python36\lib\urllib\request.py", line 517, in open req.timeout = timeoutAttributeError: 'method' object has no attribute 'timeout'Process finished with exit code 1上面是错误信息 下面是它说出错的地方。最后两个定位在 request模块里 让我有点懵逼
添加回答
举报
0/150
提交
取消