Python的获取和发布请求因Connection和GetAddrinfo而失败

时间:2019-11-27 13:15:29

标签: python get python-requests

import requests
r = requests.get('http://http2bin.org/get')

我遇到以下错误:

raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError:
HTTPConnectionPool(host='http2bin.org', port=80): Max retries exceeded
with url: /get (Caused by
NewConnectionError('<urllib3.connection.HTTPConnection object at
0x031CAB08>: Failed to establish a new connection: [Errno 11004]
getaddrinfo failed'))

可能是什么原因?与代理有关吗?

1 个答案:

答案 0 :(得分:1)

这是一个网站问题。请务必与其他网站一起尝试。

相关问题