import os # The location of my CA File cert_file = '/Users/hamel/Downloads/mitmproxy-ca-cert.pem' os.environ['REQUESTS_CA_BUNDLE'] = cert_file os.environ['SSL_CERT_FILE'] = cert_file os.environ['HTTPS_PROXY'] = 'http://127.0.0.1:8080'