a /h- @sdZddlZddlZddlZddlmZddZddZzeejejWn.e e fyxe d ejejeYn0z\z ddl Z WneydZ Yn0ee d d sdd lmZedd lmZeeWneyYn0ddlmZededdlmZmZmZmZddlmZmZmZmZddlmZm Z ddl!m"Z"ddl!m#Z#ddl$m%Z%m&Z&m'Z'ddl(m)Z)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0ddl1m2Z2m3Z3ddl4m5Z5ddlm6Z6m7Z7m8Z8m9Z9m:Z:m;Z;mZ>ddl?Z?ddl?m@Z@e?AeBCe@ejde>> import requests >>> r = requests.get('https://www.python.org') >>> r.status_code 200 >>> b'Python is a programming language' in r.content True ... or POST: >>> payload = dict(key1='value1', key2='value2') >>> r = requests.post('https://httpbin.org/post', data=payload) >>> print(r.text) { ... "form": { "key1": "value1", "key2": "value2" }, ... } The other HTTP methods are supported - see `requests.api`. Full documentation is at . :copyright: (c) 2017 by Kenneth Reitz. :license: Apache 2.0, see LICENSE for more details. N)RequestsDependencyWarningcCs|d}|dgksJt|dkr.|d|\}}}t|t|t|}}}|dks`J|dkslJ|dksxJ|ddd\}}}t|t|t|}}}d |||fkrd ksnJdS) N.dev0r)r rr)rr)splitlenappendint)Zurllib3_versionZchardet_versionmajorminorpatchr5/usr/lib/python3.9/site-packages/requests/__init__.pycheck_compatibility1s       rcCsTzttt|d}Wnty,YdS0|gdkrPd|}t|tdS)Nr)rr z4Old version of cryptography ({}) may cause slowdown.) listmaprr ValueErrorformatwarningswarnr)cryptography_versionZwarningrrr_check_cryptographyHs   rz?urllib3 ({}) or chardet ({}) doesn't match a supported version!ZHAS_SNIF) pyopenssl) __version__)DependencyWarningignore) __title____description____url__r ) __build__ __author____author_email__ __license__) __copyright____cake__)utils)packages)RequestResponsePreparedRequest)requestgetheadpostrputdeleteoptions)sessionSession)codes) RequestExceptionTimeout URLRequiredTooManyRedirects HTTPErrorConnectionErrorFileModeWarningConnectTimeout ReadTimeout) NullHandlerdefaultT)r)D__doc__Zurllib3Zchardetr exceptionsrrrr AssertionErrorrrrZssl ImportErrorgetattrZurllib3.contribrZinject_into_urllib3Z cryptographyrZurllib3.exceptionsr! simplefilterr#r$r%r&r'r(r)r*r+r,r-Zmodelsr.r/r0Zapir1r2r3r4rr5r6r7Zsessionsr8r9Z status_codesr:r;r<r=r>r?r@rArBrCZloggingrDZ getLogger__name__Z addHandlerrrrrsT#               ( ,