--------------------------------------------------------------------------- SSLCertVerificationError Traceback (most recent call last) File ~\Anaconda3\lib\site-packages\urllib3\connectionpool.py:703, in HTTPConnectionPool.urlopen(self, method, url, body, headers, retries, redirect, assert_same_host, timeout, pool_timeout, release_conn, chunked, body_pos, **response_kw) 702 # Make the request on the httplib connection object. --> 703 httplib_response = self._make_request( 704 conn, 705 method, 706 url, 707 timeout=timeout_obj, 708 body=body, 709 headers=headers, 710 chunked=chunked, 711 ) 713 # If we're going to release the connection in ``finally:``, then 714 # the response doesn't need to know about the connection. Otherwise 715 # it will also try to release it and we'll have a double-release 716 # mess. File ~\Anaconda3\lib\site-packages\urllib3\connectionpool.py:386, in HTTPConnectionPool._make_request(self, conn, method, url, timeout, chunked, **httplib_request_kw) 385 try: --> 386 self._validate_conn(conn) 387 except (SocketTimeout, BaseSSLError) as e: 388 # Py2 raises this as a BaseSSLError, Py3 raises it as socket timeout. File ~\Anaconda3\lib\site-packages\urllib3\connectionpool.py:1040, in HTTPSConnectionPool._validate_conn(self, conn) 1039 if not getattr(conn, "sock", None): # AppEngine might not have `.sock` -> 1040 conn.connect() 1042 if not conn.is_verified: File ~\Anaconda3\lib\site-packages\urllib3\connection.py:414, in HTTPSConnection.connect(self) 412 context.load_default_certs() --> 414 self.sock = ssl_wrap_socket( 415 sock=conn, 416 keyfile=self.key_file, 417 certfile=self.cert_file, 418 key_password=self.key_password, 419 ca_certs=self.ca_certs, 420 ca_cert_dir=self.ca_cert_dir, 421 ca_cert_data=self.ca_cert_data, 422 server_hostname=server_hostname, 423 ssl_context=context, 424 tls_in_tls=tls_in_tls, 425 ) 427 # If we're using all defaults and the connection 428 # is TLSv1 or TLSv1.1 we throw a DeprecationWarning 429 # for the host. File ~\Anaconda3\lib\site-packages\urllib3\util\ssl_.py:449, in ssl_wrap_socket(sock, keyfile, certfile, cert_reqs, ca_certs, server_hostname, ssl_version, ciphers, ssl_context, ca_cert_dir, key_password, ca_cert_data, tls_in_tls) 448 if send_sni: --> 449 ssl_sock = _ssl_wrap_socket_impl( 450 sock, context, tls_in_tls, server_hostname=server_hostname 451 ) 452 else: File ~\Anaconda3\lib\site-packages\urllib3\util\ssl_.py:493, in _ssl_wrap_socket_impl(sock, ssl_context, tls_in_tls, server_hostname) 492 if server_hostname: --> 493 return ssl_context.wrap_socket(sock, server_hostname=server_hostname) 494 else: File ~\Anaconda3\lib\ssl.py:500, in SSLContext.wrap_socket(self, sock, server_side, do_handshake_on_connect, suppress_ragged_eofs, server_hostname, session) 494 def wrap_socket(self, sock, server_side=False, 495 do_handshake_on_connect=True, 496 suppress_ragged_eofs=True, 497 server_hostname=None, session=None): 498 # SSLSocket class handles server_hostname encoding before it calls 499 # ctx._wrap_socket() --> 500 return self.sslsocket_class._create( 501 sock=sock, 502 server_side=server_side, 503 do_handshake_on_connect=do_handshake_on_connect, 504 suppress_ragged_eofs=suppress_ragged_eofs, 505 server_hostname=server_hostname, 506 context=self, 507 session=session 508 ) File ~\Anaconda3\lib\ssl.py:1040, in SSLSocket._create(cls, sock, server_side, do_handshake_on_connect, suppress_ragged_eofs, server_hostname, context, session) 1039 raise ValueError("do_handshake_on_connect should not be specified for non-blocking sockets") -> 1040 self.do_handshake() 1041 except (OSError, ValueError): File ~\Anaconda3\lib\ssl.py:1309, in SSLSocket.do_handshake(self, block) 1308 self.settimeout(None) -> 1309 self._sslobj.do_handshake() 1310 finally: SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129) During handling of the above exception, another exception occurred: MaxRetryError Traceback (most recent call last) File ~\Anaconda3\lib\site-packages\requests\adapters.py:440, in HTTPAdapter.send(self, request, stream, timeout, verify, cert, proxies) 439 if not chunked: --> 440 resp = conn.urlopen( 441 method=request.method, 442 url=url, 443 body=request.body, 444 headers=request.headers, 445 redirect=False, 446 assert_same_host=False, 447 preload_content=False, 448 decode_content=False, 449 retries=self.max_retries, 450 timeout=timeout 451 ) 453 # Send the request. 454 else: File ~\Anaconda3\lib\site-packages\urllib3\connectionpool.py:785, in HTTPConnectionPool.urlopen(self, method, url, body, headers, retries, redirect, assert_same_host, timeout, pool_timeout, release_conn, chunked, body_pos, **response_kw) 783 e = ProtocolError("Connection aborted.", e) --> 785 retries = retries.increment( 786 method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] 787 ) 788 retries.sleep() File ~\Anaconda3\lib\site-packages\urllib3\util\retry.py:592, in Retry.increment(self, method, url, response, error, _pool, _stacktrace) 591 if new_retry.is_exhausted(): --> 592 raise MaxRetryError(_pool, url, error or ResponseError(cause)) 594 log.debug("Incremented Retry for (url='%s'): %r", url, new_retry) MaxRetryError: HTTPSConnectionPool(host='a205143-use1-prod-results-custom.s3.amazonaws.com', port=443): Max retries exceeded with url: /8AD9BBDA1C3743C096FB1B1362348C5E/data/merged/merged-Data.csv.gz?AWSAccessKeyId=AKIATYZ2Y4ET3KM77E4C&Expires=1717612119&response-content-disposition=attachment%3B%20filename%3D_OnD_0x08f58ca3c649ee81.csv.gz&Signature=TxKOAz3GzezbwkilmEVOeXM4dI8%3D (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)'))) During handling of the above exception, another exception occurred: SSLError Traceback (most recent call last) Input In [5], in () 26 else: 27 requestHeaders={ 28 "Prefer":"respond-async", 29 "Content-Type":"text/plain", 30 "Accept-Encoding":"gzip", 31 "Authorization": "token " + token 32 } ---> 34 r4 = requests.get(requestUrl,headers=requestHeaders) 35 if useAws: 36 print ('Content response headers (AWS server): type: ' + r4.headers["Content-Type"] + '\n') File ~\Anaconda3\lib\site-packages\requests\api.py:75, in get(url, params, **kwargs) 64 def get(url, params=None, **kwargs): 65 r"""Sends a GET request. 66 67 :param url: URL for the new :class:`Request` object. (...) 72 :rtype: requests.Response 73 """ ---> 75 return request('get', url, params=params, **kwargs) File ~\Anaconda3\lib\site-packages\requests\api.py:61, in request(method, url, **kwargs) 57 # By using the 'with' statement we are sure the session is closed, thus we 58 # avoid leaving sockets open which can trigger a ResourceWarning in some 59 # cases, and look like a memory leak in others. 60 with sessions.Session() as session: ---> 61 return session.request(method=method, url=url, **kwargs) File ~\Anaconda3\lib\site-packages\requests\sessions.py:529, in Session.request(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, stream, verify, cert, json) 524 send_kwargs = { 525 'timeout': timeout, 526 'allow_redirects': allow_redirects, 527 } 528 send_kwargs.update(settings) --> 529 resp = self.send(prep, **send_kwargs) 531 return resp File ~\Anaconda3\lib\site-packages\requests\sessions.py:667, in Session.send(self, request, **kwargs) 664 if allow_redirects: 665 # Redirect resolving generator. 666 gen = self.resolve_redirects(r, request, **kwargs) --> 667 history = [resp for resp in gen] 668 else: 669 history = [] File ~\Anaconda3\lib\site-packages\requests\sessions.py:667, in (.0) 664 if allow_redirects: 665 # Redirect resolving generator. 666 gen = self.resolve_redirects(r, request, **kwargs) --> 667 history = [resp for resp in gen] 668 else: 669 history = [] File ~\Anaconda3\lib\site-packages\requests\sessions.py:237, in SessionRedirectMixin.resolve_redirects(self, resp, req, stream, timeout, verify, cert, proxies, yield_requests, **adapter_kwargs) 234 yield req 235 else: --> 237 resp = self.send( 238 req, 239 stream=stream, 240 timeout=timeout, 241 verify=verify, 242 cert=cert, 243 proxies=proxies, 244 allow_redirects=False, 245 **adapter_kwargs 246 ) 248 extract_cookies_to_jar(self.cookies, prepared_request, resp.raw) 250 # extract redirect url, if any, for the next loop File ~\Anaconda3\lib\site-packages\requests\sessions.py:645, in Session.send(self, request, **kwargs) 642 start = preferred_clock() 644 # Send the request --> 645 r = adapter.send(request, **kwargs) 647 # Total elapsed time of the request (approximately) 648 elapsed = preferred_clock() - start File ~\Anaconda3\lib\site-packages\requests\adapters.py:517, in HTTPAdapter.send(self, request, stream, timeout, verify, cert, proxies) 513 raise ProxyError(e, request=request) 515 if isinstance(e.reason, _SSLError): 516 # This branch is for urllib3 v1.22 and later. --> 517 raise SSLError(e, request=request) 519 raise ConnectionError(e, request=request) 521 except ClosedPoolError as e: SSLError: HTTPSConnectionPool(host='a205143-use1-prod-results-custom.s3.amazonaws.com', port=443): Max retries exceeded with url: /8AD9BBDA1C3743C096FB1B1362348C5E/data/merged/merged-Data.csv.gz?AWSAccessKeyId=AKIATYZ2Y4ET3KM77E4C&Expires=1717612119&response-content-disposition=attachment%3B%20filename%3D_OnD_0x08f58ca3c649ee81.csv.gz&Signature=TxKOAz3GzezbwkilmEVOeXM4dI8%3D (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)')))