2biLSrSSKrSSKrSSKJrJr SSKJr SSKJ r SSKJ r J r J r Jr SSKJr SSKJrJr SS KJr SS KJrJr SS KJr SS KJr SS KJr SSKJr SSK J!r!J"r" SSK#J$r$ SSK%J&r&J'r'J r J(r(J)r)J*r*JrJ+r+J,r,Jr SSK-J.r. SSK/J0r0 SSK1J2r2J3r3J4r4J5r5J6r6J7r7J8r8 SSK9J:r: SrSr?"SS5r@"SS\@5rAg!\;a Sr:N)f=f)z requests.adapters ~~~~~~~~~~~~~~~~~ This module contains the transport adapters that Requests uses to define and maintain connections. N)ClosedPoolErrorConnectTimeoutError) HTTPError) InvalidHeader)LocationValueError MaxRetryErrorNewConnectionError ProtocolError) ProxyError)ReadTimeoutError ResponseError)SSLError) PoolManagerproxy_from_url)Timeout) parse_url)Retry)_basic_auth_str) basestringurlparse)extract_cookies_to_jar) ConnectionErrorConnectTimeoutrInvalidProxyURL InvalidSchema InvalidURLr ReadTimeout RetryErrorr)Response)CaseInsensitiveDict)DEFAULT_CA_BUNDLE_PATHextract_zipped_pathsget_auth_from_urlget_encoding_from_headersprepend_scheme_if_needed select_proxy urldefragauth)SOCKSProxyManagerc[S5e)Nz'Missing dependencies for SOCKS support.)r)argskwargss ڏ/builddir/build/BUILDROOT/alt-python313-pip-23.3.1-3.el8.x86_64/opt/alt/python313/lib/python3.13/site-packages/pip/_vendor/requests/adapters.pyr)r)<sEFFF c>^\rSrSrSrU4SjrSSjrSrSrU=r $) BaseAdapterFzThe Base Transport Adapterc">[TU]5 gN)super__init__)self __class__s r-r6BaseAdapter.__init__Is r.c[e)aSends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. NotImplementedError)r7requeststreamtimeoutverifycertproxiess r-sendBaseAdapter.sendLs ""!r.c[e)z!Cleans up adapter specific items.r;)r7s r-closeBaseAdapter.close_s!!r.FNTNN) __name__ __module__ __qualname____firstlineno____doc__r6rCrF__static_attributes__ __classcell__r8s@r-r1r1Fs!$TX"&""r.r1c^\rSrSrSr/SQr\\\\4U4Sjjr Sr Sr \4Sjr Sr S rS rSS jrS rS rSrSrSSjrSrU=r$) HTTPAdapterda?The built-in HTTP Adapter for urllib3. Provides a general-case interface for Requests sessions to contact HTTP and HTTPS urls by implementing the Transport Adapter interface. This class will usually be created by the :class:`Session ` class under the covers. :param pool_connections: The number of urllib3 connection pools to cache. :param pool_maxsize: The maximum number of connections to save in the pool. :param max_retries: The maximum number of retries each connection should attempt. Note, this applies only to failed DNS lookups, socket connections and connection timeouts, never to requests where data has made it to the server. By default, Requests does not retry failed connections. If you need granular control over the conditions under which we retry a request, import urllib3's ``Retry`` class and pass that instead. :param pool_block: Whether the connection pool should block for connections. Usage:: >>> import requests >>> s = requests.Session() >>> a = requests.adapters.HTTPAdapter(max_retries=3) >>> s.mount('http://', a) ) max_retriesconfig_pool_connections _pool_maxsize _pool_blockc>U[:Xa[SSS9UlO[R"U5Ul0Ul0Ul[ TU]5 XlX l X@l URXUS9 g)NrF)readblock) DEFAULT_RETRIESrrUfrom_intrV proxy_managerr5r6rWrXrYinit_poolmanager)r7pool_connections pool_maxsizerU pool_blockr8s r-r6HTTPAdapter.__init__sm / )$QU3D $~~k:D   !1)% .JOr.c ZURVs0sHo[XS5_M sn$s snfr4) __attrs__getattr)r7attrs r- __getstate__HTTPAdapter.__getstate__s(<@NNKNDgd$//NKKKs(c0Ul0UlUR5Hup#[XU5 M UR UR UR URS9 g)Nr\)r`rVitemssetattrrarWrXrY)r7staterivalues r- __setstate__HTTPAdapter.__setstate__s]   ;;=KD D &)   " "D$6$6d>N>N  r.c PXlX lX0l[SUUUS.UD6Ulg)aInitializes a urllib3 PoolManager. This method should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param connections: The number of urllib3 connection pools to cache. :param maxsize: The maximum number of connections to save in the pool. :param block: Block when no free connections are available. :param pool_kwargs: Extra keyword arguments used to initialize the Pool Manager. ) num_poolsmaxsizer]NrH)rWrXrYr poolmanager)r7 connectionsrur] pool_kwargss r-raHTTPAdapter.init_poolmanagers;"-$ & !   r.c XR;aURUnU$UR5RS5(aM[U5upE[ U4UUUR UR URS.UD6=o0RU'U$URU5n[U4UUR UR URS.UD6=o0RU'U$)aReturn urllib3 ProxyManager for the given proxy. This method should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param proxy: The proxy to return a urllib3 ProxyManager for. :param proxy_kwargs: Extra keyword arguments used to configure the Proxy Manager. :returns: ProxyManager :rtype: urllib3.ProxyManager socks)usernamepasswordrtrur]) proxy_headersrtrur]) r`lower startswithr$r)rWrXrYr~r)r7proxy proxy_kwargsmanagerr|r}r~s r-proxy_manager_forHTTPAdapter.proxy_manager_fors && &((/G.-[[] % %g . .!25!9 H2C3!!00**&& 33 G((/(!..u5M2@3+00**&& 3  3 G((/r.cUR5RS5(aU(aSnUSLaUnU(d[[5nU(a$[R R U5(d[SU35eSUl[R RU5(dXQl OXQl OSUlSUl SUl U(a[U[5(dUSUlUSUlO XAlSUlUR(aF[R R UR5(d[S UR35eUR(aG[R R UR5(d[S UR35eggg) aVerify a SSL certificate. This method should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param conn: The urllib3 connection object associated with the cert. :param url: The requested URL. :param verify: Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: The SSL certificate to verify. httpsNTzCCould not find a suitable TLS CA certificate bundle, invalid path: CERT_REQUIRED CERT_NONErrz7Could not find the TLS certificate file, invalid path: z/Could not find the TLS key file, invalid path: )rrr#r"ospathexistsOSError cert_reqsisdirca_certs ca_cert_dir isinstancer cert_filekey_file)r7connurlr@rAcert_locs r- cert_verifyHTTPAdapter.cert_verifysd 99; ! !' * *vHT!!/0FG277>>(#;#;%%-J0 -DN77==** ( #+ (DN DM#D  dJ//!%a $Q !% $ ~~bggnnT^^&D&D%%)^^$46}}RWW^^DMM%B%BEdmm_U&C} r.c[5n[USS5Ul[[US055Ul[ UR5UlX#lURRUl[UR[5(a!URRS5Ul OURUl [URX5 XlXlU$)a~Builds a :class:`Response ` object from a urllib3 response. This should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter ` :param req: The :class:`PreparedRequest ` used to generate the response. :param resp: The urllib3 response object. :rtype: requests.Response statusNheaderszutf-8)r rh status_coder!rr%encodingrawreasonrrbytesdecodercookiesr= connection)r7reqrespresponses r-build_responseHTTPAdapter.build_response&s: 'tXt</wtY/KL6h6F6FG ",,-- cggu % %77>>'2HL77HL x//;"r.cD[X5nU(aW[US5n[U5nUR(d [ S5eUR U5nUR U5nU$[U5nUR5nURR U5nU$)a\Returns a urllib3 connection for the given URL. This should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param url: The URL to connect to. :param proxies: (optional) A Requests-style dictionary of proxies used on this request. :rtype: urllib3.ConnectionPool httpzFPlease check proxy URL. It is malformed and could be missing the host.) r'r&rhostrrconnection_from_urlrgeturlrv)r7rrBr proxy_urlr`rparseds r-get_connectionHTTPAdapter.get_connectionKsS* ,UF;E!%(I>>%5!2259M 44S9D c]F--/C##77`. :param request: The :class:`PreparedRequest ` being sent. :param proxies: A dictionary of schemes or schemes and hosts to proxy URLs. :rtype: str rFr{)r'rrschemerrpath_urlr() r7r=rBrris_proxied_http_requestusing_socks_proxy proxy_schemers r- request_urlHTTPAdapter.request_urlrsW[['2'++&--"'"=Fg,=! #E?11779L , 7 7 @  "+< ,C r.c g)aAdd any headers needed by the connection. As of v2.0 this does nothing by default, but is left for overriding by users that subclass the :class:`HTTPAdapter `. This should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param request: The :class:`PreparedRequest ` to add headers to. :param kwargs: The keyword arguments from the call to send(). NrH)r7r=r,s r- add_headersHTTPAdapter.add_headerss r.cN0n[U5up4U(a[X45US'U$)aReturns a dictionary of the headers to add to any request sent through a proxy. This works with urllib3 magic to ensure that they are correctly sent to the proxy, rather than in a tunnelled request if CONNECT is being used. This should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter `. :param proxy: The url of the proxy being used for this request. :rtype: dict zProxy-Authorization)r$r)r7rrr|r}s r-r~HTTPAdapter.proxy_headerss..u5 -4a`n[U[85(a [;XS9e[U[@5(a [CXS9e[U[D5(a [GXS9eeSnAff=f) aSends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response )r=N)r>r?r@rArBzContent-Length)connectr[zInvalid timeout za. Pass a (connect, read) timeout tuple, or a single float to set both timeouts to the same value.F) methodrbodyrredirectassert_same_hostpreload_contentdecode_contentretriesr?chunked)%rrrrrrrrrrtuple TimeoutSauce ValueErrorurlopenrrUr rrrrrr rr r _ProxyErrorr _SSLErrorrr _HTTPErrorr r_InvalidHeaderrr)r7r=r>r?r@rArBrerrrr[rerrs r-rCHTTPAdapter.sends& 1&&w{{G??(<<!((M22 44!((K00 44!((I..q22!!5 5 6!!5 5 Q- :& !Y''q22A/00!!55A~..#A77 snD D9 AE D6( D11D69EK%& E// K%rs OBJ EJ@G<.0!(+   +GC""