2

SSLCertVerificationError Traceback (most recent call last) File /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/urllib/request.py:1344, in AbstractHTTPHandler.do_open(self, http_class, req, **http_conn_args) 1343 try: -> 1344 h.request(req.get_method(), req.selector, req.data, headers, 1345 encode_chunked=req.has_header('Transfer-encoding')) 1346 except OSError as err: # timeout error

File /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/http/client.py:1336, in HTTPConnection.request(self, method, url, body, headers, encode_chunked) 1335 """Send a complete request to the server.""" -> 1336 self._send_request(method, url, body, headers, encode_chunked)

File /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/http/client.py:1382, in HTTPConnection._send_request(self, method, url, body, headers, encode_chunked) 1381 body = _encode(body, 'body') -> 1382 self.endheaders(body, encode_chunked=encode_chunked)

File /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/http/client.py:1331, in HTTPConnection.endheaders(self, message_body, encode_chunked) 1330 raise CannotSendHeader() -> 1331 self._send_output(message_body, encode_chunked=encode_chunked)

File /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/http/client.py:1091, in HTTPConnection._send_output(self, message_body, encode_chunked) 1090 del self._buffer[:] -> 1091 self.send(msg) 1093 if message_body is not None: 1094 ... -> 1347 raise URLError(err) 1348 r = h.getresponse() 1349 except:

URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)>

1 Answer 1

0

Pandas uses urllib. You can try using requests instead.

import pandas as pd
import requests

url = "https://www.example.com/"
response = requests.get(url)

df = pd.read_csv(response.text)
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.