def uninstall_opener(): # httplib unpatch from wsgi_intercept.httplib_intercept import uninstall uninstall() # requests' unpatch from requests.packages.urllib3 import connectionpool connectionpool.HTTPConnection = connectionpool.old_http connectionpool.HTTPSConnection = connectionpool.old_https
def https_uninstall(): wsgi_intercept.debuglevel = _saved_debuglevel wsgi_intercept.remove_wsgi_intercept('some_hopefully_nonexistant_domain', 443) httplib_intercept.uninstall()