HTTPSConnectionPool(host='xxxxx', port=443): Max retries exceeded with url:xxxxxxxx (Caused by NewConnectionError('<urllib3.connect,Max retries exceeded with ,(Caused by NewConnectionError

HTTPSConnectionPool(host='f6ws-sha8re-o88k.s3.ama66zaws.com', port=443): Max retries exceeded with url: /uploads/website/auctions/items/full/3076380_1.jpg 
(Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003C5F3C8>:
Failed to establish a new connection: [Errno 10060]
',))

  http连接太多没有关闭导致的

  1、增加重试连接次数

    requests.adapters.DEFAULT_RETRIES = 5

  2、关闭多余的连接

    s = requests.session()

    s.keep_alive = False

  3、升级requests

    pip install --upgrade requests

  

原文地址:https://www.cnblogs.com/xuchunlin/p/6774380.html