From 8701e6025b28739b6f87efdd0ebad668260adde0 Mon Sep 17 00:00:00 2001 From: "Vitor M. A. da Cruz" Date: Fri, 5 Jul 2013 16:48:30 -0300 Subject: [PATCH] Removing patch for plain http using requests during reset The patch was not removed, so subsequent connections were affected --- vcr/patch.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vcr/patch.py b/vcr/patch.py index 95c5c49..82bc3d8 100644 --- a/vcr/patch.py +++ b/vcr/patch.py @@ -8,7 +8,8 @@ _HTTPSConnection = httplib.HTTPSConnection try: import requests.packages.urllib3.connectionpool - _VerifiedHTTPSConnection = requests.packages.urllib3.connectionpool.VerifiedHTTPSConnection + _VerifiedHTTPSConnection = requests.packages.urllib3.connectionpool.VerifiedHTTPSConnection + _HTTPConnection = requests.packages.urllib3.connectionpool.HTTPConnection except ImportError: pass @@ -55,6 +56,7 @@ def reset(): try: import requests.packages.urllib3.connectionpool requests.packages.urllib3.connectionpool.VerifiedHTTPSConnection = _VerifiedHTTPSConnection + requests.packages.urllib3.connectionpool.HTTPConnection = _HTTPConnection except ImportError: pass