How do I save a webpage that returns “Max retries exceeded with url”?

  Kiến thức lập trình

I am trying to save this page:

https://edge.nhl.com/en/skater/20232024-regular-8480188

I am using pywebcopy save_webpage in Python 3.7:

url = ‘https://edge.nhl.com/en/skater/20232024-regular-8480188’
download_folder = ‘/Users/myname/Downloads/’

kwargs = {‘bypass_robots’: True}

save_webpage(url, download_folder, **kwargs)

I get the following error:

requests.exceptions.SSLError: HTTPSConnectionPool(host=’edge.nhl.com’, port=443): Max retries exceeded with url: /en/skater/20232024-regular-8480188 (Caused by SSLError(SSLCertVerificationError(1, ‘[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1091)’)))

What is going wrong here with the certificate?

I do see that this page calls wss://edge.nhl.com/en/skater/20232024-regular-8480188, and it keeps pinging the server indefinitely.

LEAVE A COMMENT