Viewing File: /opt/alt/python35/lib/python3.5/site-packages/pip/_vendor/__pycache__/six.cpython-35.pyc



t_oM@sdZddlmZddlZddlZddlZddlZddlZdZdZ	ej
ddkZej
ddkZej
dddkZ
erefZefZefZeZeZejZnefZeefZeejfZeZeZejjd	r'edZnWGdd
d
eZ ye!e Wne"k
rnedZYn
XedZ[ ddZ#ddZ$GdddeZ%Gddde%Z&Gdddej'Z(Gddde%Z)GdddeZ*e*e+Z,Gddde(Z-e)ddd d!e)d"d#d$d%d"e)d&d#d#d'd&e)d(d)d$d*d(e)d+d)d,e)d-d#d$d.d-e)d/d0d0d1d/e)d2d0d0d/d2e)d3d4d5e)d6d)d$d7d6e)d8d)e
rd9nd:d;e)d<d)d=e)d>d?d@dAe)d!d!d e)dBdBdCe)dDdDdCe)dEdEdCe)d7d)d$d7d6e)dFd#d$dGdFe)dHd#d#dIdHe&d$d)e&dJdKe&dLdCej
dkrdMndCe&dNdOe&dPdQdRe&dSdTdUe&dVdWej
dkr*dVndYe&dZd[d\e&d]d^d_e&d`dadbe&dcdddee&dfdgdhe&didjdke&dldmdne&dodpdqe&drdsdte&dudvdwe&dxdxdye&dzdzdye&d{d{dye&d|d|d}e&d~de&dde&dde&dYddYe&dde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&ddde&de+dde&de+dde&de+de+de&ddde&ddde&dddgBZ.ejdkre.e&ddg7Z.xGe.D]?Z/e0e-e/j1e/e2e/e&re,j3e/de/j1qW[/e.e-_.e-e+dZ4e,j3e4dGddde(Z5e)ddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)dAdde)ddde)ddde)ddde)ddddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)ddde)dddgZ6x!e6D]Z/e0e5e/j1e/qW[/e6e5_.e,j3e5e+dddGddde(Z7e)ddde)ddde)dddgZ8x!e8D]Z/e0e7e/j1e/qT	W[/e8e7_.e,j3e7e+dddGddde(Z9e)ddde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ej+dkrvej1e+krveje=PqvW[[ejje,dS(z6Utilities for writing code that runs on Python 2 and 3)absolute_importNz'Benjamin Peterson <benjamin@python.org>z1.15.0javac@seZdZddZdS)XcCsdS)Nrrl)selfr
r
~/builddir/build/BUILDROOT/alt-python35-pip-20.2.4-1.el7.x86_64/opt/alt/python35/lib/python3.5/site-packages/pip/_vendor/six.py__len__>sz	X.__len__N)__name__
__module____qualname__r
r
r
r
rr	<sr	?cCs
||_dS)z Add documentation to a function.N)__doc__)funcdocr
r
r_add_docKsrcCst|tj|S)z7Import module, returning the module after the last dot.)
__import__sysmodules)namer
r
r_import_modulePs
rc@s(eZdZddZddZdS)
_LazyDescrcCs
||_dS)N)r)rrr
r
r__init__Xsz_LazyDescr.__init__cCsO|j}t||j|yt|j|jWntk
rJYnX|S)N)_resolvesetattrrdelattr	__class__AttributeError)robjtpresultr
r
r__get__[s
z_LazyDescr.__get__N)rrrrr%r
r
r
rrVsrcs=eZdZdfddZddZddZS)MovedModuleNcsGtt|j|tr:|dkr.|}||_n	||_dS)N)superr&rPY3mod)rroldnew)r r
rriszMovedModule.__init__cCs
t|jS)N)rr))rr
r
rrrszMovedModule._resolvecCs/|j}t||}t||||S)N)rgetattrr)rattr_modulevaluer
r
r__getattr__uszMovedModule.__getattr__)rrrrrr0r
r
)r rr&gs	r&cs4eZdZfddZddZgZS)_LazyModulecs)tt|j||jj|_dS)N)r'r1rr r)rr)r r
rr~sz_LazyModule.__init__cCs*ddg}|dd|jD7}|S)NrrcSsg|]}|jqSr
)r).0r-r
r
r
<listcomp>s	z'_LazyModule.__dir__.<locals>.<listcomp>)_moved_attributes)rattrsr
r
r__dir__sz_LazyModule.__dir__)rrrrr6r4r
r
)r rr1|sr1cs4eZdZddfddZddZS)MovedAttributeNcstt|j|trj|dkr.|}||_|dkr^|dkrX|}n|}||_n$||_|dkr|}||_dS)N)r'r7rr(r)r-)rrold_modnew_modold_attrnew_attr)r r
rrs			zMovedAttribute.__init__cCst|j}t||jS)N)rr)r,r-)rmoduler
r
rrszMovedAttribute._resolve)rrrrrr
r
)r rr7sr7c@seZdZdZddZddZddZdd	d
ZddZd
dZ	ddZ
ddZeZdS)_SixMetaPathImporterz
    A meta path importer to import six.moves and its submodules.

    This class implements a PEP302 finder and loader. It should be compatible
    with Python 2.5 and all existing versions of Python3
    cCs||_i|_dS)N)r
known_modules)rsix_module_namer
r
rrs	z_SixMetaPathImporter.__init__cGs-x&|D]}||j|jd|<qWdS)N.)r>r)rr)	fullnamesfullnamer
r
r_add_modules
z _SixMetaPathImporter._add_modulecCs|j|jd|S)Nr@)r>r)rrBr
r
r_get_modulesz _SixMetaPathImporter._get_moduleNcCs||jkr|SdS)N)r>)rrBpathr
r
rfind_modulesz _SixMetaPathImporter.find_modulecCs8y|j|SWn"tk
r3td|YnXdS)Nz!This loader does not know module )r>KeyErrorImportError)rrBr
r
r__get_modules
z!_SixMetaPathImporter.__get_modulecCskytj|SWntk
r#YnX|j|}t|trQ|j}n	||_|tj|<|S)N)rrrG _SixMetaPathImporter__get_module
isinstancer&r
__loader__)rrBr)r
r
rload_modules
	
z _SixMetaPathImporter.load_modulecCst|j|dS)z
        Return true, if the named module is a package.

        We need this method to get correct spec objects with
        Python 3.4 (see PEP451)
        __path__)hasattrrJ)rrBr
r
r
is_packagesz_SixMetaPathImporter.is_packagecCs|j|dS)z;Return None

        Required, if is_package is implementedN)rJ)rrBr
r
rget_codes
z_SixMetaPathImporter.get_code)
rrrrrrCrDrFrJrMrPrQ
get_sourcer
r
r
rr=s	r=c@seZdZdZgZdS)_MovedItemszLazy loading of moved objectsN)rrrrrNr
r
r
rrSsrS	cStringIOioStringIOfilter	itertoolsbuiltinsifilterfilterfalseifilterfalseinput__builtin__	raw_inputinternrmapimapgetcwdosZgetcwdugetcwdb	getoutputcommands
subprocessrangexrange
reload_module	importlibimpreloadreduce	functoolsshlex_quoteZpipesshlexquoteUserDictcollectionsUserList
UserStringzipizipzip_longestizip_longestconfigparserConfigParsercollections_abczcollections.abccopyregcopy_regdbm_gnugdbmzdbm.gnudbm_ndbmdbmzdbm.ndbm
_dummy_threaddummy_thread	_threadhttp_cookiejar	cookielibzhttp.cookiejarhttp_cookiesCookiezhttp.cookies
html_entitieshtmlentitydefsz
html.entitieshtml_parser
HTMLParserzhtml.parserhttp_clienthttplibzhttp.clientemail_mime_basezemail.MIMEBasezemail.mime.baseemail_mime_imagezemail.MIMEImagezemail.mime.imageemail_mime_multipartzemail.MIMEMultipartzemail.mime.multipartemail_mime_nonmultipartzemail.MIMENonMultipartzemail.mime.nonmultipartemail_mime_textzemail.MIMETextzemail.mime.textBaseHTTPServerzhttp.server
CGIHTTPServerSimpleHTTPServercPicklepicklequeueQueuereprlibreprsocketserverSocketServerthreadtkinterTkintertkinter_dialogDialogztkinter.dialogtkinter_filedialog
FileDialogztkinter.filedialogtkinter_scrolledtextScrolledTextztkinter.scrolledtexttkinter_simpledialogSimpleDialogztkinter.simpledialogtkinter_tixTixztkinter.tixtkinter_ttkttkztkinter.ttktkinter_constantsTkconstantsztkinter.constantstkinter_dndTkdndztkinter.dndtkinter_colorchoosertkColorChooserztkinter.colorchoosertkinter_commondialogtkCommonDialogztkinter.commondialogtkinter_tkfiledialogtkFileDialogtkinter_fonttkFontztkinter.fonttkinter_messageboxtkMessageBoxztkinter.messageboxtkinter_tksimpledialogtkSimpleDialogurllib_parsez.moves.urllib_parsezurllib.parseurllib_errorz.moves.urllib_errorzurllib.errorurllibz
.moves.urlliburllib_robotparserrobotparserzurllib.robotparser
xmlrpc_client	xmlrpclibz
xmlrpc.client
xmlrpc_serverSimpleXMLRPCServerz
xmlrpc.serverwin32winreg_winregzmoves.z.movesmovesc@seZdZdZdS)Module_six_moves_urllib_parsez7Lazy loading of moved objects in six.moves.urllib_parseN)rrrrr
r
r
rrDsrParseResulturlparseSplitResultparse_qs	parse_qsl	urldefragurljoinurlsplit
urlunparse
urlunsplit
quote_plusunquoteunquote_plusunquote_to_bytes	urlencode
splitquerysplittag	splituser
splitvalue
uses_fragmentuses_netlocuses_params
uses_query
uses_relativezmoves.urllib_parsezmoves.urllib.parsec@seZdZdZdS)Module_six_moves_urllib_errorz7Lazy loading of moved objects in six.moves.urllib_errorN)rrrrr
r
r
rrnsrURLErrorurllib2	HTTPErrorContentTooShortErrorz.moves.urllib.errorzmoves.urllib_errorzmoves.urllib.errorc@seZdZdZdS)Module_six_moves_urllib_requestz9Lazy loading of moved objects in six.moves.urllib_requestN)rrrrr
r
r
rrsrurlopenzurllib.requestinstall_openerbuild_openerpathname2urlurl2pathname
getproxiesRequestOpenerDirectorHTTPDefaultErrorHandlerHTTPRedirectHandlerHTTPCookieProcessorProxyHandlerBaseHandlerHTTPPasswordMgrHTTPPasswordMgrWithDefaultRealmAbstractBasicAuthHandlerHTTPBasicAuthHandlerProxyBasicAuthHandlerAbstractDigestAuthHandlerHTTPDigestAuthHandlerProxyDigestAuthHandlerHTTPHandlerHTTPSHandlerFileHandler
FTPHandlerCacheFTPHandlerUnknownHandlerHTTPErrorProcessorurlretrieve
urlcleanup	URLopenerFancyURLopenerproxy_bypassparse_http_listparse_keqv_listz.moves.urllib.requestzmoves.urllib_requestzmoves.urllib.requestc@seZdZdZdS) Module_six_moves_urllib_responsez:Lazy loading of moved objects in six.moves.urllib_responseN)rrrrr
r
r
rrsraddbasezurllib.responseaddclosehookaddinfo
addinfourlz.moves.urllib.responsezmoves.urllib_responsezmoves.urllib.responsec@seZdZdZdS)#Module_six_moves_urllib_robotparserz=Lazy loading of moved objects in six.moves.urllib_robotparserN)rrrrr
r
r
rrsrRobotFileParserz.moves.urllib.robotparserzmoves.urllib_robotparserzmoves.urllib.robotparserc@sseZdZdZgZejdZejdZejdZ	ejdZ
ejdZddZd	S)
Module_six_moves_urllibzICreate a six.moves.urllib namespace that resembles the Python 3 namespacezmoves.urllib_parsezmoves.urllib_errorzmoves.urllib_requestzmoves.urllib_responsezmoves.urllib_robotparsercCsdddddgS)Nparseerrorrequestresponserr
)rr
r
rr6szModule_six_moves_urllib.__dir__N)
rrrrrN	_importerrDrrrrrr6r
r
r
rrsrzmoves.urllibcCstt|j|dS)zAdd an item to six.moves.N)rrSr)mover
r
radd_movesrcCs`ytt|WnHtk
r[ytj|=Wn%tk
rVtd|fYnXYnXdS)zRemove item from six.moves.zno such move, %rN)rrSr!r__dict__rG)rr
r
rremove_moves

r!__func____self____closure____code____defaults____globals__im_funcZim_selfZfunc_closure	func_codeZ
func_defaultsZfunc_globalscCs
|jS)N)next)itr
r
radvance_iteratorsr,cCs tddt|jDS)Ncss|]}d|jkVqdS)__call__N)r )r2klassr
r
r	<genexpr>szcallable.<locals>.<genexpr>)anytype__mro__)r"r
r
rcallablesr3cCs|S)Nr
)unboundr
r
rget_unbound_function sr5cCs|S)Nr
)rclsr
r
rcreate_unbound_method%sr7cCs|jS)N)r()r4r
r
rr5*scCstj|||jS)N)types
MethodTyper )rr"r
r
rcreate_bound_method-sr:cCstj|d|S)N)r8r9)rr6r
r
rr70sc@seZdZddZdS)IteratorcCst|j|S)N)r1__next__)rr
r
rr*5sz
Iterator.nextN)rrrr*r
r
r
rr;3sr;z3Get the function out of a possibly unbound functioncKst|j|S)N)iterkeys)dkwr
r
riterkeysFsrAcKst|j|S)N)r=values)r?r@r
r
r
itervaluesIsrCcKst|j|S)N)r=items)r?r@r
r
r	iteritemsLsrEcKst|j|S)N)r=lists)r?r@r
r
r	iterlistsOsrGr>rBrDcKs
|j|S)N)rA)r?r@r
r
rrAXscKs
|j|S)N)rC)r?r@r
r
rrC[scKs
|j|S)N)rE)r?r@r
r
rrE^scKs
|j|S)N)rG)r?r@r
r
rrGasviewkeys
viewvalues	viewitemsz1Return an iterator over the keys of a dictionary.z3Return an iterator over the values of a dictionary.z?Return an iterator over the (key, value) pairs of a dictionary.zBReturn an iterator over the (key, [values]) pairs of a dictionary.cCs
|jdS)Nzlatin-1)encode)sr
r
rbssrMcCs|S)Nr
)rLr
r
ruvsrNz>BassertCountEqualZassertRaisesRegexpZassertRegexpMatchesZassertNotRegexpMatchesassertRaisesRegexassertRegexassertNotRegexcCs|S)Nr
)rLr
r
rrMscCst|jdddS)Nz\\z\\\\Zunicode_escape)unicodereplace)rLr
r
rrNscCst|dS)Nr)ord)bsr
r
rbyte2intsrWcCst||S)N)rU)bufir
r
r
indexbytessrZZassertItemsEqualzByte literalzText literalcOst|t||S)N)r,_assertCountEqual)rargskwargsr
r
rrOscOst|t||S)N)r,_assertRaisesRegex)rr\r]r
r
rrPscOst|t||S)N)r,_assertRegex)rr\r]r
r
rrQscOst|t||S)N)r,_assertNotRegex)rr\r]r
r
rrRsexecc
CsQz=|dkr|}|j|k	r6|j||Wdd}d}XdS)N)
__traceback__with_traceback)r#r/tbr
r
rreraises	
recCs_|dkr?tjd}|j}|dkr9|j}~n|dkrQ|}tddS)zExecute code in a namespace.Nrzexec _code_ in _globs_, _locs_)r	_getframe	f_globalsf_localsra)Z_code_Z_globs_Z_locs_framer
r
rexec_s		rjzedef reraise(tp, value, tb=None):
    try:
        raise tp, value, tb
    finally:
        tb = None
zrdef raise_from(value, from_value):
    try:
        raise value from from_value
    finally:
        value = None
cCs
|dS)Nr
)r/
from_valuer
r
r
raise_fromsrlprintc
s|jdtjdkr%dSfdd}d}|jdd}|dk	rt|trsd}nt|tstd|jd	d}|dk	rt|trd}nt|tstd
|rtd|sx$|D]}t|trd}PqW|r?td}td
}nd}d
}|dkr]|}|dkro|}x4t|D]&\}	}|	r||||q|W||dS)z4The new-style print function for Python 2.4 and 2.5.fileNcst|tst|}ttrt|trjdk	rtdd}|dkrld}|jj|}j|dS)Nerrorsstrict)	rK
basestringstrrnrSencodingr,rKwrite)dataro)fpr
rrtszprint_.<locals>.writeFsepTzsep must be None or a stringendzend must be None or a stringz$invalid keyword arguments to print()
 )poprstdoutrKrSrr	TypeError	enumerate)
r\r]rtZwant_unicoderwrxargnewlinespacerYr
)rvrprint_sL		

rcOsT|jdtj}|jdd}t|||rP|dk	rP|jdS)NrnflushF)getrr|r{_printr)r\r]rvrr
r
rrs

zReraise an exception.c
CsxI|D]A}yt||}Wntk
r7wYqXt|||qWx0|D](}t||jt||iqSW||_|S)N)r,r!rupdate__wrapped__)wrapperwrappedassignedupdatedr-r/r
r
r_update_wrapper.s


&	rcCstjtd|d|d|S)Nrrr)rppartialr)rrrr
r
rwraps>srcs5Gfdddt}tj|dfiS)z%Create a base class with a metaclass.cs@eZdZfddZefddZdS)z!with_metaclass.<locals>.metaclasscsWtjdddkrAtj}|k	rG|d<n}|||S)Nrr__orig_bases__)rr)rversion_infor8
resolve_bases)r6r
this_basesr?resolved_bases)basesmetar
r__new__Os
z)with_metaclass.<locals>.metaclass.__new__csj|S)N)__prepare__)r6rr)rrr
rrZsz-with_metaclass.<locals>.metaclass.__prepare__N)rrrrclassmethodrr
)rrr
r	metaclassMsrtemporary_class)r1r)rrrr
)rrrwith_metaclassHsrcsfdd}|S)z6Class decorator for creating a class with a metaclass.cs|jj}|jd}|dk	r`t|trB|g}x|D]}|j|qIW|jdd|jddt|dr|j|d<|j|j	|S)N	__slots__r __weakref__r)
r copyrrKrrr{rOrr	__bases__)r6	orig_varsslots	slots_var)rr
rrbs	

zadd_metaclass.<locals>.wrapperr
)rrr
)rr
add_metaclass`s
rzutf-8rpcCsLt|tr|St|tr2|j||Stdt|dS)zCoerce **s** to six.binary_type.

    For Python 2:
      - `unicode` -> encoded to `str`
      - `str` -> `str`

    For Python 3:
      - `str` -> encoded to `bytes`
      - `bytes` -> `bytes`
    znot expecting type '%s'N)rKbinary_type	text_typerKr}r1)rLrsror
r
r
ensure_binaryrs
rcCst|tkr|Str;t|tr;|j||Str`t|tr`|j||St|ttfst	dt||S)zCoerce *s* to `str`.

    For Python 2:
      - `unicode` -> encoded to `str`
      - `str` -> `str`

    For Python 3:
      - `str` -> `str`
      - `bytes` -> decoded to `str`
    znot expecting type '%s')
r1rrPY2rKrrKr(rdecoder})rLrsror
r
r
ensure_strsrcCsLt|tr|j||St|tr2|Stdt|dS)zCoerce *s* to six.text_type.

    For Python 2:
      - `unicode` -> `unicode`
      - `str` -> `unicode`

    For Python 3:
      - `str` -> `str`
      - `bytes` -> decoded to `str`
    znot expecting type '%s'N)rKrrrr}r1)rLrsror
r
rensure_texts
rcCsGtrCd|jkr(td|j|j|_dd|_|S)a
    A class decorator that defines __unicode__ and __str__ methods under Python 2.
    Under Python 3 it does nothing.

    To support Python 2 and 3 with a single code base, define a __str__ method
    returning text and apply this decorator to the class.
    __str__zY@python_2_unicode_compatible cannot be applied to %s because it doesn't define __str__().cSs|jjdS)Nzutf-8)__unicode__rK)rr
r
r<lambda>sz-python_2_unicode_compatible.<locals>.<lambda>)rr 
ValueErrorrrr)r.r
r
rpython_2_unicode_compatibles
r__spec__)rrlilill)rr)rr)r)rr)rr)r
__future__rrprXoperatorrr8
__author____version__rrr(PY34rrstring_typesint
integer_typesr1class_typesrbytesrmaxsizeMAXSIZErqlongZ	ClassTyperSplatform
startswithobjectr	len
OverflowErrorrrrr&
ModuleTyper1r7r=rrrSr4r-rrrKrCrr_urllib_parse_moved_attributesr_urllib_error_moved_attributesr _urllib_request_moved_attributesr!_urllib_response_moved_attributesr$_urllib_robotparser_moved_attributesrrr!
_meth_func
_meth_self
_func_closure
_func_code_func_defaults
_func_globalsr*r,	NameErrorr3r5r9r:r7r;
attrgetterget_method_functionget_method_selfget_function_closureget_function_codeget_function_defaultsget_function_globalsrArCrErGmethodcallerrHrIrJrMrNchrunichrstructStructpackint2byte
itemgetterrWgetitemrZr=	iterbytesrUrVBytesIOr[r^r_r`rrbrUrOrPrQrRr,rYrjrerlrrWRAPPER_ASSIGNMENTSWRAPPER_UPDATESrupdate_wrapperrrrrrrrrN__package__globalsrrsubmodule_search_locations	meta_pathr~rYimporterappendr
r
r
r<module>s				
>$$			
	
	

	

	

	

	

	



		

					



5
			

Back to Directory File Manager