forked from pool/python-google-auth
37 lines
1.6 KiB
Diff
37 lines
1.6 KiB
Diff
|
Index: google-auth-2.17.3/google/auth/transport/urllib3.py
|
||
|
===================================================================
|
||
|
--- google-auth-2.17.3.orig/google/auth/transport/urllib3.py
|
||
|
+++ google-auth-2.17.3/google/auth/transport/urllib3.py
|
||
|
@@ -95,8 +95,8 @@ class Request(transport.Request):
|
||
|
credentials.refresh(request)
|
||
|
|
||
|
Args:
|
||
|
- http (urllib3.request.RequestMethods): An instance of any urllib3
|
||
|
- class that implements :class:`~urllib3.request.RequestMethods`,
|
||
|
+ http (urllib3._request_methods.RequestMethods): An instance of any urllib3
|
||
|
+ class that implements :class:`~urllib3._request_methods.RequestMethods`,
|
||
|
usually :class:`urllib3.PoolManager`.
|
||
|
|
||
|
.. automethod:: __call__
|
||
|
@@ -184,7 +184,7 @@ def _make_mutual_tls_http(cert, key):
|
||
|
return http
|
||
|
|
||
|
|
||
|
-class AuthorizedHttp(urllib3.request.RequestMethods):
|
||
|
+class AuthorizedHttp(urllib3._request_methods.RequestMethods):
|
||
|
"""A urllib3 HTTP class with credentials.
|
||
|
|
||
|
This class is used to perform requests to API endpoints that require
|
||
|
@@ -197,8 +197,9 @@ class AuthorizedHttp(urllib3.request.Req
|
||
|
response = authed_http.request(
|
||
|
'GET', 'https://www.googleapis.com/storage/v1/b')
|
||
|
|
||
|
- This class implements :class:`urllib3.request.RequestMethods` and can be
|
||
|
- used just like any other :class:`urllib3.PoolManager`.
|
||
|
+ This class implements
|
||
|
+ :class:`urllib3._request_methods.RequestMethods` and can be used
|
||
|
+ just like any other :class:`urllib3.PoolManager`.
|
||
|
|
||
|
The underlying :meth:`urlopen` implementation handles adding the
|
||
|
credentials' headers to the request and refreshing credentials as needed.
|