报的错误是这样子的。
HTTPConnectionPool(host='119.5.1.36', port=808): Max retries exceeded with url: http://www.jobbole.com/ (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.HTTPConnection object at 0x000000000433B0B8>: Failed to establish a new connection: [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。',)))
还有是这样子的:
HTTPConnectionPool(host='183.159.92.82', port=18118): Max retries exceeded with url: http://www.jobbole.com/ (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.HTTPConnection object at 0x000000000433D080>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。',)))
并且程序执行3次就停掉了,但是我的数据库里有西刺网不止3个IP
这个怎么解决啊???
带你彻底掌握Scrapy,用Django+Elasticsearch搭建搜索引擎
了解课程