冲顶大会Python代码执行出现bug

时间:2020-12-22 23:24:49
Traceback (most recent call last):
File "D:\Python\lib\site-packages\urllib3\connection.py", line 141, in _new_conn
(self.host, self.port), self.timeout, **extra_kw)
File "D:\Python\lib\site-packages\urllib3\util\connection.py", line 83, in create_connection
raise err
File "D:\Python\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection
sock.connect(sa)
ConnectionRefusedError: [WinError 10061] 由于目标计算机积极拒绝,无法连接。

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 601, in urlopen
chunked=chunked)
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 357, in _make_request
conn.request(method, url, **httplib_request_kw)
File "D:\Python\lib\http\client.py", line 1239, in request
self._send_request(method, url, body, headers, encode_chunked)
File "D:\Python\lib\http\client.py", line 1285, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "D:\Python\lib\http\client.py", line 1234, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "D:\Python\lib\http\client.py", line 1026, in _send_output
self.send(msg)
File "D:\Python\lib\http\client.py", line 964, in send
self.connect()
File "D:\Python\lib\site-packages\urllib3\connection.py", line 166, in connect
conn = self._new_conn()
File "D:\Python\lib\site-packages\urllib3\connection.py", line 150, in _new_conn
self, "Failed to establish a new connection: %s" % e)
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x064558D0>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "D:\Python\lib\site-packages\requests\adapters.py", line 440, in send
timeout=timeout
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 639, in urlopen
_stacktrace=sys.exc_info()[2])
File "D:\Python\lib\site-packages\urllib3\util\retry.py", line 388, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='127.0.0.1', port=63816): Max retries exceeded with url: http://htpmsg.jiecaojingxuan.com/msg/current (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.HTTPConnection object at 0x064558D0>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积 极拒绝,无法连接。',)))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "F:\作弊工具\AnswerHelper-master\main.py", line 10, in <module>
result = problem_utils.get_result()
File "F:\作弊工具\AnswerHelper-master\problem_utils.py", line 56, in get_result
return get_chongding_by_api()
File "F:\作弊工具\AnswerHelper-master\problem_utils.py", line 38, in get_chongding_by_api
req = requests.get(url=api_url)
File "D:\Python\lib\site-packages\requests\api.py", line 72, in get
return request('get', url, params=params, **kwargs)
File "D:\Python\lib\site-packages\requests\api.py", line 58, in request
return session.request(method=method, url=url, **kwargs)
File "D:\Python\lib\site-packages\requests\sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "D:\Python\lib\site-packages\requests\sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "D:\Python\lib\site-packages\requests\adapters.py", line 502, in send
raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPConnectionPool(host='127.0.0.1', port=63816): Max retries exceeded with url: http://htpmsg.jiecaojingxuan.com/msg/current (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.HTTPConnection object at 0x064558D0>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极 拒绝,无法连接。',)))
求大神帮忙解决