You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I try to use VCR with my code that uses urllib3 connection pools, I get the following exception:
defauthenticate_user(self, response, **kwargs):
"""Handles user authentication with gssapi/kerberos"""host=urlparse(response.url).hostnametry:
auth_header=self.generate_request_header(response, host)
exceptKerberosExchangeError:
# GSS Failure, return existing responsereturnresponselog.debug("authenticate_user(): Authorization header: {0}".format(
auth_header))
response.request.headers['Authorization'] =auth_header# Consume the content so we can reuse the connection for the next# request.response.content>response.raw.release_conn()
EAttributeError: 'VCRHTTPResponse'objecthasnoattribute'release_conn'. Didyoumean: '_close_conn'?
I can see that in urllib3_stubs.py we set urllib3 classes as base classes for VCRRequestsHTTPConnection and VCRRequestsHTTPSConnection.
Is the solution to add a similar snippet in urllib3_stubs.py to set the base class of `VCRHTTPResponse?
The text was updated successfully, but these errors were encountered:
Similar slightly to #117
The urllib3 library's response class has the method
release_conn()
, intended for use with connection pools:https://urllib3.readthedocs.io/en/latest/reference/urllib3.response.html#urllib3.response.BaseHTTPResponse.release_conn
When I try to use VCR with my code that uses urllib3 connection pools, I get the following exception:
I can see that in
urllib3_stubs.py
we set urllib3 classes as base classes forVCRRequestsHTTPConnection
andVCRRequestsHTTPSConnection
.Is the solution to add a similar snippet in
urllib3_stubs.py
to set the base class of `VCRHTTPResponse?The text was updated successfully, but these errors were encountered: