/opt/alt/python36/lib64/python3.6/__pycache__
NameSizeModeActions
abc.cpython-36.opt-1.pyc74870644editdlrm
abc.cpython-36.opt-2.pyc41230644editdlrm
abc.cpython-36.pyc75300644editdlrm
aifc.cpython-36.opt-1.pyc259580644editdlrm
aifc.cpython-36.opt-2.pyc207530644editdlrm
aifc.cpython-36.pyc259580644editdlrm
antigravity.cpython-36.opt-1.pyc7940644editdlrm
antigravity.cpython-36.opt-2.pyc6500644editdlrm
antigravity.cpython-36.pyc7940644editdlrm
argparse.cpython-36.opt-1.pyc600710644editdlrm
argparse.cpython-36.opt-2.pyc508300644editdlrm
argparse.cpython-36.pyc602050644editdlrm
ast.cpython-36.opt-1.pyc117190644editdlrm
ast.cpython-36.opt-2.pyc61340644editdlrm
ast.cpython-36.pyc117190644editdlrm
asynchat.cpython-36.opt-1.pyc68300644editdlrm
asynchat.cpython-36.opt-2.pyc54540644editdlrm
asynchat.cpython-36.pyc68300644editdlrm
asyncore.cpython-36.opt-1.pyc158530644editdlrm
asyncore.cpython-36.opt-2.pyc146490644editdlrm
asyncore.cpython-36.pyc158530644editdlrm
base64.cpython-36.opt-1.pyc169160644editdlrm
base64.cpython-36.opt-2.pyc113180644editdlrm
base64.cpython-36.pyc170740644editdlrm
bdb.cpython-36.opt-1.pyc170480644editdlrm
bdb.cpython-36.opt-2.pyc153220644editdlrm
bdb.cpython-36.pyc170480644editdlrm
binhex.cpython-36.opt-1.pyc121010644editdlrm
binhex.cpython-36.opt-2.pyc115680644editdlrm
binhex.cpython-36.pyc121010644editdlrm
bisect.cpython-36.opt-1.pyc26910644editdlrm
bisect.cpython-36.opt-2.pyc13950644editdlrm
bisect.cpython-36.pyc26910644editdlrm
bz2.cpython-36.opt-1.pyc112970644editdlrm
bz2.cpython-36.opt-2.pyc62400644editdlrm
bz2.cpython-36.pyc112970644editdlrm
calendar.cpython-36.opt-1.pyc258970644editdlrm
calendar.cpython-36.opt-2.pyc213700644editdlrm
calendar.cpython-36.pyc258970644editdlrm
cgi.cpython-36.opt-1.pyc286210644editdlrm
cgi.cpython-36.opt-2.pyc194820644editdlrm
cgi.cpython-36.pyc286210644editdlrm
cgitb.cpython-36.opt-1.pyc100950644editdlrm
cgitb.cpython-36.opt-2.pyc84960644editdlrm
cgitb.cpython-36.pyc100950644editdlrm
chunk.cpython-36.opt-1.pyc49150644editdlrm
chunk.cpython-36.opt-2.pyc27690644editdlrm
chunk.cpython-36.pyc49150644editdlrm
cmd.cpython-36.opt-1.pyc125900644editdlrm
cmd.cpython-36.opt-2.pyc71510644editdlrm
cmd.cpython-36.pyc125900644editdlrm
code.cpython-36.opt-1.pyc98510644editdlrm
code.cpython-36.opt-2.pyc45750644editdlrm
code.cpython-36.pyc98510644editdlrm
codecs.cpython-36.opt-1.pyc339150644editdlrm
codecs.cpython-36.opt-2.pyc180670644editdlrm
codecs.cpython-36.pyc339150644editdlrm
codeop.cpython-36.opt-1.pyc62850644editdlrm
codeop.cpython-36.opt-2.pyc22380644editdlrm
codeop.cpython-36.pyc62850644editdlrm
colorsys.cpython-36.opt-1.pyc33260644editdlrm
colorsys.cpython-36.opt-2.pyc27200644editdlrm
colorsys.cpython-36.pyc33260644editdlrm
compileall.cpython-36.opt-1.pyc82930644editdlrm
compileall.cpython-36.opt-2.pyc61550644editdlrm
compileall.cpython-36.pyc82930644editdlrm
configparser.cpython-36.opt-1.pyc452590644editdlrm
configparser.cpython-36.opt-2.pyc305710644editdlrm
configparser.cpython-36.pyc452590644editdlrm
contextlib.cpython-36.opt-1.pyc111730644editdlrm
contextlib.cpython-36.opt-2.pyc78270644editdlrm
contextlib.cpython-36.pyc111730644editdlrm
copy.cpython-36.opt-1.pyc70940644editdlrm
copy.cpython-36.opt-2.pyc47780644editdlrm
copy.cpython-36.pyc70940644editdlrm
copyreg.cpython-36.opt-1.pyc42240644editdlrm
copyreg.cpython-36.opt-2.pyc34200644editdlrm
copyreg.cpython-36.pyc42590644editdlrm
cProfile.cpython-36.opt-1.pyc43090644editdlrm
cProfile.cpython-36.opt-2.pyc38480644editdlrm
cProfile.cpython-36.pyc43090644editdlrm
crypt.cpython-36.opt-1.pyc22570644editdlrm
crypt.cpython-36.opt-2.pyc15930644editdlrm
crypt.cpython-36.pyc22570644editdlrm
csv.cpython-36.opt-1.pyc118700644editdlrm
csv.cpython-36.opt-2.pyc98310644editdlrm
csv.cpython-36.pyc118700644editdlrm
datetime.cpython-36.opt-1.pyc530730644editdlrm
datetime.cpython-36.opt-2.pyc442230644editdlrm
datetime.cpython-36.pyc545260644editdlrm
decimal.cpython-36.opt-1.pyc3660644editdlrm
decimal.cpython-36.opt-2.pyc3660644editdlrm
decimal.cpython-36.pyc3660644editdlrm
difflib.cpython-36.opt-1.pyc596190644editdlrm
difflib.cpython-36.opt-2.pyc250490644editdlrm
difflib.cpython-36.pyc596570644editdlrm
dis.cpython-36.opt-1.pyc141960644editdlrm
dis.cpython-36.opt-2.pyc106640644editdlrm
dis.cpython-36.pyc141960644editdlrm
doctest.cpython-36.opt-1.pyc753590644editdlrm
doctest.cpython-36.opt-2.pyc400320644editdlrm
doctest.cpython-36.pyc756040644editdlrm
dummy_threading.cpython-36.opt-1.pyc11170644editdlrm
dummy_threading.cpython-36.opt-2.pyc7440644editdlrm
dummy_threading.cpython-36.pyc11170644editdlrm
enum.cpython-36.opt-1.pyc234680644editdlrm
enum.cpython-36.opt-2.pyc191750644editdlrm
enum.cpython-36.pyc234680644editdlrm
filecmp.cpython-36.opt-1.pyc83200644editdlrm
filecmp.cpython-36.opt-2.pyc59030644editdlrm
filecmp.cpython-36.pyc83200644editdlrm
fileinput.cpython-36.opt-1.pyc131670644editdlrm
fileinput.cpython-36.opt-2.pyc76280644editdlrm
fileinput.cpython-36.pyc131670644editdlrm
fnmatch.cpython-36.opt-1.pyc28890644editdlrm
fnmatch.cpython-36.opt-2.pyc17000644editdlrm
fnmatch.cpython-36.pyc28890644editdlrm
formatter.cpython-36.opt-1.pyc175940644editdlrm
formatter.cpython-36.opt-2.pyc151540644editdlrm
formatter.cpython-36.pyc175940644editdlrm
fractions.cpython-36.opt-1.pyc184410644editdlrm
fractions.cpython-36.opt-2.pyc111550644editdlrm
fractions.cpython-36.pyc184410644editdlrm
ftplib.cpython-36.opt-1.pyc283720644editdlrm
ftplib.cpython-36.opt-2.pyc185680644editdlrm
ftplib.cpython-36.pyc283720644editdlrm
functools.cpython-36.opt-1.pyc240770644editdlrm
functools.cpython-36.opt-2.pyc181060644editdlrm
functools.cpython-36.pyc240770644editdlrm
genericpath.cpython-36.opt-1.pyc37410644editdlrm
genericpath.cpython-36.opt-2.pyc27480644editdlrm
genericpath.cpython-36.pyc37410644editdlrm
getopt.cpython-36.opt-1.pyc61980644editdlrm
getopt.cpython-36.opt-2.pyc36440644editdlrm
getopt.cpython-36.pyc62320644editdlrm
getpass.cpython-36.opt-1.pyc41920644editdlrm
getpass.cpython-36.opt-2.pyc30070644editdlrm
getpass.cpython-36.pyc41920644editdlrm
gettext.cpython-36.opt-1.pyc142120644editdlrm
gettext.cpython-36.opt-2.pyc135210644editdlrm
gettext.cpython-36.pyc142120644editdlrm
glob.cpython-36.opt-1.pyc42050644editdlrm
glob.cpython-36.opt-2.pyc33450644editdlrm
glob.cpython-36.pyc42740644editdlrm
gzip.cpython-36.opt-1.pyc162410644editdlrm
gzip.cpython-36.opt-2.pyc124350644editdlrm
gzip.cpython-36.pyc162410644editdlrm
hashlib.cpython-36.opt-1.pyc67070644editdlrm
hashlib.cpython-36.opt-2.pyc61350644editdlrm
hashlib.cpython-36.pyc67070644editdlrm
heapq.cpython-36.opt-1.pyc143070644editdlrm
heapq.cpython-36.opt-2.pyc113170644editdlrm
heapq.cpython-36.pyc143070644editdlrm
hmac.cpython-36.opt-1.pyc48510644editdlrm
hmac.cpython-36.opt-2.pyc30400644editdlrm
hmac.cpython-36.pyc48510644editdlrm
imaplib.cpython-36.opt-1.pyc399340644editdlrm
imaplib.cpython-36.opt-2.pyc278460644editdlrm
imaplib.cpython-36.pyc421530644editdlrm
imghdr.cpython-36.opt-1.pyc41650644editdlrm
imghdr.cpython-36.opt-2.pyc38500644editdlrm
imghdr.cpython-36.pyc41650644editdlrm
imp.cpython-36.opt-1.pyc97110644editdlrm
imp.cpython-36.opt-2.pyc73080644editdlrm
imp.cpython-36.pyc97110644editdlrm
inspect.cpython-36.opt-1.pyc794540644editdlrm
inspect.cpython-36.opt-2.pyc540390644editdlrm
inspect.cpython-36.pyc797540644editdlrm
io.cpython-36.opt-1.pyc34020644editdlrm
io.cpython-36.opt-2.pyc19110644editdlrm
io.cpython-36.pyc34020644editdlrm
ipaddress.cpython-36.opt-1.pyc624010644editdlrm
ipaddress.cpython-36.opt-2.pyc368150644editdlrm
ipaddress.cpython-36.pyc624010644editdlrm
keyword.cpython-36.opt-1.pyc17800644editdlrm
keyword.cpython-36.opt-2.pyc15120644editdlrm
keyword.cpython-36.pyc17800644editdlrm
linecache.cpython-36.opt-1.pyc37930644editdlrm
linecache.cpython-36.opt-2.pyc26880644editdlrm
linecache.cpython-36.pyc37930644editdlrm
locale.cpython-36.opt-1.pyc340600644editdlrm
locale.cpython-36.opt-2.pyc294350644editdlrm
locale.cpython-36.pyc340600644editdlrm
lzma.cpython-36.opt-1.pyc120070644editdlrm
lzma.cpython-36.opt-2.pyc58160644editdlrm
lzma.cpython-36.pyc120070644editdlrm
macpath.cpython-36.opt-1.pyc56560644editdlrm
macpath.cpython-36.opt-2.pyc43900644editdlrm
macpath.cpython-36.pyc56560644editdlrm
macurl2path.cpython-36.opt-1.pyc18820644editdlrm
macurl2path.cpython-36.opt-2.pyc15020644editdlrm
macurl2path.cpython-36.pyc18820644editdlrm
mailbox.cpython-36.opt-1.pyc636850644editdlrm
mailbox.cpython-36.opt-2.pyc545380644editdlrm
mailbox.cpython-36.pyc637670644editdlrm
mailcap.cpython-36.opt-1.pyc64930644editdlrm
mailcap.cpython-36.opt-2.pyc49750644editdlrm
mailcap.cpython-36.pyc64930644editdlrm
mimetypes.cpython-36.opt-1.pyc155680644editdlrm
mimetypes.cpython-36.opt-2.pyc95700644editdlrm
mimetypes.cpython-36.pyc155680644editdlrm
modulefinder.cpython-36.opt-1.pyc153190644editdlrm
modulefinder.cpython-36.opt-2.pyc144780644editdlrm
modulefinder.cpython-36.pyc153810644editdlrm
netrc.cpython-36.opt-1.pyc38510644editdlrm
netrc.cpython-36.opt-2.pyc36130644editdlrm
netrc.cpython-36.pyc38510644editdlrm
nntplib.cpython-36.opt-1.pyc337950644editdlrm
nntplib.cpython-36.opt-2.pyc212540644editdlrm
nntplib.cpython-36.pyc337950644editdlrm
ntpath.cpython-36.opt-1.pyc137650644editdlrm
ntpath.cpython-36.opt-2.pyc112940644editdlrm
ntpath.cpython-36.pyc137650644editdlrm
nturl2path.cpython-36.opt-1.pyc15140644editdlrm
nturl2path.cpython-36.opt-2.pyc11960644editdlrm
nturl2path.cpython-36.pyc15140644editdlrm
numbers.cpython-36.opt-1.pyc121570644editdlrm
numbers.cpython-36.opt-2.pyc81960644editdlrm
numbers.cpython-36.pyc121570644editdlrm
opcode.cpython-36.opt-1.pyc54280644editdlrm
opcode.cpython-36.opt-2.pyc52880644editdlrm
opcode.cpython-36.pyc54280644editdlrm
operator.cpython-36.opt-1.pyc139280644editdlrm
operator.cpython-36.opt-2.pyc114690644editdlrm
operator.cpython-36.pyc139280644editdlrm
optparse.cpython-36.opt-1.pyc480010644editdlrm
optparse.cpython-36.opt-2.pyc356460644editdlrm
optparse.cpython-36.pyc480690644editdlrm
os.cpython-36.opt-1.pyc296430644editdlrm
os.cpython-36.opt-2.pyc177940644editdlrm
os.cpython-36.pyc296430644editdlrm
pathlib.cpython-36.opt-1.pyc420220644editdlrm
pathlib.cpython-36.opt-2.pyc343800644editdlrm
pathlib.cpython-36.pyc420220644editdlrm
pdb.cpython-36.opt-1.pyc460520644editdlrm
pdb.cpython-36.opt-2.pyc319850644editdlrm
pdb.cpython-36.pyc461090644editdlrm
pickle.cpython-36.opt-1.pyc425890644editdlrm
pickle.cpython-36.opt-2.pyc378010644editdlrm
pickle.cpython-36.pyc427060644editdlrm
pickletools.cpython-36.opt-1.pyc651840644editdlrm
pickletools.cpython-36.opt-2.pyc564430644editdlrm
pickletools.cpython-36.pyc660350644editdlrm
pipes.cpython-36.opt-1.pyc78230644editdlrm
pipes.cpython-36.opt-2.pyc49500644editdlrm
pipes.cpython-36.pyc78230644editdlrm
pkgutil.cpython-36.opt-1.pyc162760644editdlrm
pkgutil.cpython-36.opt-2.pyc110160644editdlrm
pkgutil.cpython-36.pyc162760644editdlrm
platform.cpython-36.opt-1.pyc286460644editdlrm
platform.cpython-36.opt-2.pyc193980644editdlrm
platform.cpython-36.pyc286460644editdlrm
plistlib.cpython-36.opt-1.pyc280030644editdlrm
plistlib.cpython-36.opt-2.pyc247490644editdlrm
plistlib.cpython-36.pyc280700644editdlrm
poplib.cpython-36.opt-1.pyc133440644editdlrm
poplib.cpython-36.opt-2.pyc84130644editdlrm
poplib.cpython-36.pyc133440644editdlrm
posixpath.cpython-36.opt-1.pyc104380644editdlrm
posixpath.cpython-36.opt-2.pyc87170644editdlrm
posixpath.cpython-36.pyc104380644editdlrm
pprint.cpython-36.opt-1.pyc157840644editdlrm
pprint.cpython-36.opt-2.pyc137200644editdlrm
pprint.cpython-36.pyc158390644editdlrm
profile.cpython-36.opt-1.pyc137100644editdlrm
profile.cpython-36.opt-2.pyc107280644editdlrm
profile.cpython-36.pyc139160644editdlrm
pstats.cpython-36.opt-1.pyc218720644editdlrm
pstats.cpython-36.opt-2.pyc194180644editdlrm
pstats.cpython-36.pyc218720644editdlrm
pty.cpython-36.opt-1.pyc38760644editdlrm
pty.cpython-36.opt-2.pyc30230644editdlrm
pty.cpython-36.pyc38760644editdlrm
pyclbr.cpython-36.opt-1.pyc83800644editdlrm
pyclbr.cpython-36.opt-2.pyc55840644editdlrm
pyclbr.cpython-36.pyc83800644editdlrm
pydoc.cpython-36.opt-1.pyc834580644editdlrm
pydoc.cpython-36.opt-2.pyc742570644editdlrm
pydoc.cpython-36.pyc835110644editdlrm
py_compile.cpython-36.opt-1.pyc65590644editdlrm
py_compile.cpython-36.opt-2.pyc29550644editdlrm
py_compile.cpython-36.pyc65590644editdlrm
queue.cpython-36.opt-1.pyc87700644editdlrm
queue.cpython-36.opt-2.pyc49800644editdlrm
queue.cpython-36.pyc87700644editdlrm
quopri.cpython-36.opt-1.pyc56130644editdlrm
quopri.cpython-36.opt-2.pyc45770644editdlrm
quopri.cpython-36.pyc57880644editdlrm
random.cpython-36.opt-1.pyc193450644editdlrm
random.cpython-36.opt-2.pyc128040644editdlrm
random.cpython-36.pyc193450644editdlrm
re.cpython-36.opt-1.pyc140730644editdlrm
re.cpython-36.opt-2.pyc57930644editdlrm
re.cpython-36.pyc140730644editdlrm
reprlib.cpython-36.opt-1.pyc54150644editdlrm
reprlib.cpython-36.opt-2.pyc52590644editdlrm
reprlib.cpython-36.pyc54150644editdlrm
rlcompleter.cpython-36.opt-1.pyc57950644editdlrm
rlcompleter.cpython-36.opt-2.pyc31320644editdlrm
rlcompleter.cpython-36.pyc57950644editdlrm
runpy.cpython-36.opt-1.pyc79970644editdlrm
runpy.cpython-36.opt-2.pyc64540644editdlrm
runpy.cpython-36.pyc79970644editdlrm
sched.cpython-36.opt-1.pyc65790644editdlrm
sched.cpython-36.opt-2.pyc35390644editdlrm
sched.cpython-36.pyc65790644editdlrm
secrets.cpython-36.opt-1.pyc21770644editdlrm
secrets.cpython-36.opt-2.pyc11190644editdlrm
secrets.cpython-36.pyc21770644editdlrm
selectors.cpython-36.opt-1.pyc177120644editdlrm
selectors.cpython-36.opt-2.pyc137360644editdlrm
selectors.cpython-36.pyc177120644editdlrm
shelve.cpython-36.opt-1.pyc94730644editdlrm
shelve.cpython-36.opt-2.pyc53200644editdlrm
shelve.cpython-36.pyc94730644editdlrm
shlex.cpython-36.opt-1.pyc69850644editdlrm
shlex.cpython-36.opt-2.pyc64730644editdlrm
shlex.cpython-36.pyc69850644editdlrm
shutil.cpython-36.opt-1.pyc307190644editdlrm
shutil.cpython-36.opt-2.pyc199460644editdlrm
shutil.cpython-36.pyc307190644editdlrm
signal.cpython-36.opt-1.pyc25300644editdlrm
signal.cpython-36.opt-2.pyc23020644editdlrm
signal.cpython-36.pyc25300644editdlrm
site.cpython-36.opt-1.pyc161550644editdlrm
site.cpython-36.opt-2.pyc106050644editdlrm
site.cpython-36.pyc161550644editdlrm
smtpd.cpython-36.opt-1.pyc266980644editdlrm
smtpd.cpython-36.opt-2.pyc240790644editdlrm
smtpd.cpython-36.pyc266980644editdlrm
smtplib.cpython-36.opt-1.pyc354310644editdlrm
smtplib.cpython-36.opt-2.pyc190190644editdlrm
smtplib.cpython-36.pyc354920644editdlrm
sndhdr.cpython-36.opt-1.pyc69280644editdlrm
sndhdr.cpython-36.opt-2.pyc56530644editdlrm
sndhdr.cpython-36.pyc69280644editdlrm
socket.cpython-36.opt-1.pyc219880644editdlrm
socket.cpython-36.opt-2.pyc145540644editdlrm
socket.cpython-36.pyc220280644editdlrm
socketserver.cpython-36.opt-1.pyc242650644editdlrm
socketserver.cpython-36.opt-2.pyc133400644editdlrm
socketserver.cpython-36.pyc242650644editdlrm
sre_compile.cpython-36.opt-1.pyc101530644editdlrm
sre_compile.cpython-36.opt-2.pyc97390644editdlrm
sre_compile.cpython-36.pyc102930644editdlrm
sre_constants.cpython-36.opt-1.pyc59870644editdlrm
sre_constants.cpython-36.opt-2.pyc55620644editdlrm
sre_constants.cpython-36.pyc59870644editdlrm
sre_parse.cpython-36.opt-1.pyc203260644editdlrm
sre_parse.cpython-36.opt-2.pyc202780644editdlrm
sre_parse.cpython-36.pyc203730644editdlrm
ssl.cpython-36.opt-1.pyc365170644editdlrm
ssl.cpython-36.opt-2.pyc269930644editdlrm
ssl.cpython-36.pyc365170644editdlrm
stat.cpython-36.opt-1.pyc38660644editdlrm
stat.cpython-36.opt-2.pyc31880644editdlrm
stat.cpython-36.pyc38660644editdlrm
statistics.cpython-36.opt-1.pyc179480644editdlrm
statistics.cpython-36.opt-2.pyc72610644editdlrm
statistics.cpython-36.pyc181890644editdlrm
string.cpython-36.opt-1.pyc79790644editdlrm
string.cpython-36.opt-2.pyc68730644editdlrm
string.cpython-36.pyc79790644editdlrm
stringprep.cpython-36.opt-1.pyc99870644editdlrm
stringprep.cpython-36.opt-2.pyc97670644editdlrm
stringprep.cpython-36.pyc100450644editdlrm
struct.cpython-36.opt-1.pyc3270644editdlrm
struct.cpython-36.opt-2.pyc3270644editdlrm
struct.cpython-36.pyc3270644editdlrm
subprocess.cpython-36.opt-1.pyc353990644editdlrm
subprocess.cpython-36.opt-2.pyc246850644editdlrm
subprocess.cpython-36.pyc355000644editdlrm
sunau.cpython-36.opt-1.pyc169530644editdlrm
sunau.cpython-36.opt-2.pyc123630644editdlrm
sunau.cpython-36.pyc169530644editdlrm
symbol.cpython-36.opt-1.pyc25320644editdlrm
symbol.cpython-36.opt-2.pyc24560644editdlrm
symbol.cpython-36.pyc25320644editdlrm
symtable.cpython-36.opt-1.pyc103360644editdlrm
symtable.cpython-36.opt-2.pyc96390644editdlrm
symtable.cpython-36.pyc104430644editdlrm
sysconfig.cpython-36.opt-1.pyc159420644editdlrm
sysconfig.cpython-36.opt-2.pyc133720644editdlrm
sysconfig.cpython-36.pyc159420644editdlrm
tabnanny.cpython-36.opt-1.pyc69900644editdlrm
tabnanny.cpython-36.opt-2.pyc60570644editdlrm
tabnanny.cpython-36.pyc69900644editdlrm
tarfile.cpython-36.opt-1.pyc627030644editdlrm
tarfile.cpython-36.opt-2.pyc489040644editdlrm
tarfile.cpython-36.pyc627030644editdlrm
telnetlib.cpython-36.opt-1.pyc181120644editdlrm
telnetlib.cpython-36.opt-2.pyc106020644editdlrm
telnetlib.cpython-36.pyc181120644editdlrm
tempfile.cpython-36.opt-1.pyc222420644editdlrm
tempfile.cpython-36.opt-2.pyc157700644editdlrm
tempfile.cpython-36.pyc222420644editdlrm
textwrap.cpython-36.opt-1.pyc136250644editdlrm
textwrap.cpython-36.opt-2.pyc63280644editdlrm
textwrap.cpython-36.pyc136990644editdlrm
this.cpython-36.opt-1.pyc12800644editdlrm
this.cpython-36.opt-2.pyc12800644editdlrm
this.cpython-36.pyc12800644editdlrm
threading.cpython-36.opt-1.pyc365960644editdlrm
threading.cpython-36.opt-2.pyc205550644editdlrm
threading.cpython-36.pyc372490644editdlrm
timeit.cpython-36.opt-1.pyc116180644editdlrm
timeit.cpython-36.opt-2.pyc56370644editdlrm
timeit.cpython-36.pyc116180644editdlrm
token.cpython-36.opt-1.pyc33350644editdlrm
token.cpython-36.opt-2.pyc32850644editdlrm
token.cpython-36.pyc33350644editdlrm
tokenize.cpython-36.opt-1.pyc186160644editdlrm
tokenize.cpython-36.opt-2.pyc150160644editdlrm
tokenize.cpython-36.pyc186620644editdlrm
trace.cpython-36.opt-1.pyc195100644editdlrm
trace.cpython-36.opt-2.pyc165070644editdlrm
trace.cpython-36.pyc195100644editdlrm
traceback.cpython-36.opt-1.pyc196610644editdlrm
traceback.cpython-36.opt-2.pyc107600644editdlrm
traceback.cpython-36.pyc196610644editdlrm
tracemalloc.cpython-36.opt-1.pyc172440644editdlrm
tracemalloc.cpython-36.opt-2.pyc158280644editdlrm
tracemalloc.cpython-36.pyc172440644editdlrm
tty.cpython-36.opt-1.pyc10870644editdlrm
tty.cpython-36.opt-2.pyc9860644editdlrm
tty.cpython-36.pyc10870644editdlrm
types.cpython-36.opt-1.pyc82160644editdlrm
types.cpython-36.opt-2.pyc70490644editdlrm
types.cpython-36.pyc82160644editdlrm
typing.cpython-36.opt-1.pyc729130644editdlrm
typing.cpython-36.opt-2.pyc560620644editdlrm
typing.cpython-36.pyc733210644editdlrm
uu.cpython-36.opt-1.pyc35660644editdlrm
uu.cpython-36.opt-2.pyc33480644editdlrm
uu.cpython-36.pyc35660644editdlrm
uuid.cpython-36.opt-1.pyc207970644editdlrm
uuid.cpython-36.opt-2.pyc141290644editdlrm
uuid.cpython-36.pyc209330644editdlrm
warnings.cpython-36.opt-1.pyc126810644editdlrm
warnings.cpython-36.opt-2.pyc103010644editdlrm
warnings.cpython-36.pyc132730644editdlrm
wave.cpython-36.opt-1.pyc178480644editdlrm
wave.cpython-36.opt-2.pyc118570644editdlrm
wave.cpython-36.pyc179000644editdlrm
weakref.cpython-36.opt-1.pyc191280644editdlrm
weakref.cpython-36.opt-2.pyc158280644editdlrm
weakref.cpython-36.pyc191580644editdlrm
webbrowser.cpython-36.opt-1.pyc157790644editdlrm
webbrowser.cpython-36.opt-2.pyc139100644editdlrm
webbrowser.cpython-36.pyc158120644editdlrm
xdrlib.cpython-36.opt-1.pyc83170644editdlrm
xdrlib.cpython-36.opt-2.pyc78320644editdlrm
xdrlib.cpython-36.pyc83170644editdlrm
zipapp.cpython-36.opt-1.pyc55490644editdlrm
zipapp.cpython-36.opt-2.pyc43730644editdlrm
zipapp.cpython-36.pyc55490644editdlrm
zipfile.cpython-36.opt-1.pyc486170644editdlrm
zipfile.cpython-36.opt-2.pyc421140644editdlrm
zipfile.cpython-36.pyc486850644editdlrm
_bootlocale.cpython-36.opt-1.pyc9670644editdlrm
_bootlocale.cpython-36.opt-2.pyc7420644editdlrm
_bootlocale.cpython-36.pyc9950644editdlrm
_collections_abc.cpython-36.opt-1.pyc288120644editdlrm
_collections_abc.cpython-36.opt-2.pyc236600644editdlrm
_collections_abc.cpython-36.pyc288120644editdlrm
_compat_pickle.cpython-36.opt-1.pyc65230644editdlrm
_compat_pickle.cpython-36.opt-2.pyc65230644editdlrm
_compat_pickle.cpython-36.pyc65810644editdlrm
_compression.cpython-36.opt-1.pyc41190644editdlrm
_compression.cpython-36.opt-2.pyc39030644editdlrm
_compression.cpython-36.pyc41190644editdlrm
_dummy_thread.cpython-36.opt-1.pyc48660644editdlrm
_dummy_thread.cpython-36.opt-2.pyc26580644editdlrm
_dummy_thread.cpython-36.pyc48660644editdlrm
_markupbase.cpython-36.opt-1.pyc78370644editdlrm
_markupbase.cpython-36.opt-2.pyc74570644editdlrm
_markupbase.cpython-36.pyc80060644editdlrm
_osx_support.cpython-36.opt-1.pyc97210644editdlrm
_osx_support.cpython-36.opt-2.pyc72720644editdlrm
_osx_support.cpython-36.pyc97210644editdlrm
_pydecimal.cpython-36.opt-1.pyc1634170644editdlrm
_pydecimal.cpython-36.opt-2.pyc820100644editdlrm
_pydecimal.cpython-36.pyc1634170644editdlrm
_pyio.cpython-36.opt-1.pyc713830644editdlrm
_pyio.cpython-36.opt-2.pyc489880644editdlrm
_pyio.cpython-36.pyc714010644editdlrm
_sitebuiltins.cpython-36.opt-1.pyc34500644editdlrm
_sitebuiltins.cpython-36.opt-2.pyc29260644editdlrm
_sitebuiltins.cpython-36.pyc34500644editdlrm
_strptime.cpython-36.opt-1.pyc159780644editdlrm
_strptime.cpython-36.opt-2.pyc122480644editdlrm
_strptime.cpython-36.pyc159780644editdlrm
_sysconfigdata_dm_linux_x86_64-linux-gnu.cpython-36.opt-1.pyc198750644editdlrm
_sysconfigdata_dm_linux_x86_64-linux-gnu.cpython-36.opt-2.pyc198750644editdlrm
_sysconfigdata_dm_linux_x86_64-linux-gnu.cpython-36.pyc198750644editdlrm
_sysconfigdata_m_linux_x86_64-linux-gnu.cpython-36.opt-1.pyc195440644editdlrm
_sysconfigdata_m_linux_x86_64-linux-gnu.cpython-36.opt-2.pyc195440644editdlrm
_sysconfigdata_m_linux_x86_64-linux-gnu.cpython-36.pyc195440644editdlrm
_threading_local.cpython-36.opt-1.pyc64400644editdlrm
_threading_local.cpython-36.opt-2.pyc31250644editdlrm
_threading_local.cpython-36.pyc64400644editdlrm
_weakrefset.cpython-36.opt-1.pyc78430644editdlrm
_weakrefset.cpython-36.opt-2.pyc78430644editdlrm
_weakrefset.cpython-36.pyc78430644editdlrm
__future__.cpython-36.opt-1.pyc41820644editdlrm
__future__.cpython-36.opt-2.pyc22060644editdlrm
__future__.cpython-36.pyc41820644editdlrm
__phello__.foo.cpython-36.opt-1.pyc1340644editdlrm
__phello__.foo.cpython-36.opt-2.pyc1340644editdlrm
__phello__.foo.cpython-36.pyc1340644editdlrm
Edit: /opt/alt/python36/lib64/python3.6/__pycache__/typing.cpython-36.pyc (73321B)
3 kf9D@s ddlZddlmZmZddlZddlZddlZddlZddlZddl Z yddl jZ Wne k rrddlZ YnXej dddkrddlZyddl mZmZmZWn4e k reejZeejZeejZYnXddd d d d d ddddddddddddddddddd d!d"d#d$d%d&d'd(d)d*d+d,d-d.d/d0d1d2d3d4d5d6d7d8d9d:g4Zd;d<Zd=d>ZGd?d@d@eZGdAdBdBedCdDZGdEdFdFedCdGZGdHdIdIedCdGZGdJdKdKedCdGZdLdMZ dNdOZ!dPdQZ"dRdSZ#dTdUZ$GdVdWdWedCdGZ%e%dCdGZ&GdXdYdYedCdGZ'e'dCdGZ(GdZddedCdGZ)e)d[Z*e)d\Z+e)d]Z,e)d^dCd_Z-e)d`dCd_Z.e)dadCd_Z/e)dbdCdcZ0e)d2e1eZ2dddeZ3ddfdgZ4dhdiZ5djdkZ6gZ7dldmZ8GdndodoedCdGZ9e9dCdGZ:GdpdqdqedCdGZ;e;dCdGZdvdwZ?Gdxddeej@ZAdZBdydzZCGd{d d eAd|ZBGd}d~d~ZDGdddZEGdddeAZFGdd d eGeGeFdZHGdddeAZIGddde jJeIdZJGdddedCdGZKeKdCdGZLdd3ZMddZNe jOe jPe jQe jReeefZSddd4ZTdd6ZUdd7ZVddZWdd8ZXGdddeAZYGdddeYd|ZZe j[Z[e\e drjGdddeBe-e j]dZ]ej^de\e drGddde]e.eBe-e0e.fe j_dZ_ej^de\e drGdddeBe-e j`dZ`Gddde`e-e jadZaej^dej^dGdddeBe-e jbdZbGdddebe-e jcdZcGdd'd'eZZdGdd&d&eZZeGdd%d%eZZfGdd$d$eZZgGdd#d#eZe-ZhGdd(d(eZe-Zie\e d"rGdd"d"ebe-e jjdZjnGdd"d"eZe-Zje jkZkGdddeBe-e jldZle\e dr*Gdddekebe-ele-e jmdZmej^de\e drRGdddeme-e jndZon"Gdddekebe-ele-e jndZoGdddeoe*e jpdZpe\e drGdddeme+eBe+e/fe jqdZqn,Gdddekebe+ele+eBe+e/fe jqdZqGdddeqe+e,fe jrdZre\e d"rhe\e drDGdddeje-eme-e jsdZsn"Gdddekeje-ele-e jsdZsn"Gdddekebe-ele-e jsdZsGdddese*e jtdZtGdddeseue jvdZvGdd-d-ewete*ewdZxGdd*d*ejyete*ejydZzGdd.d.e{epe*e{dZnGdd/d/e|eoe-e|dZ}Gdddekebe-e j~dZ~Gddde~e+eoe+e jdZGddde~eHe+e/feoeHe+e/feBe+e/fe jdZGdd!d!e~e/e jdZe\edrGdddeBe-ejdZnGdddeBe-Ze\edà r(GddńdeBe-ejdZej^dŃnej dddk rDedǃGdd+d+eere+e,fedZGdd,d,ejere+e,fejdZGdd)d)ejee*eufejdZe\ed˃ rej^d˃Gdd˄dejere+e,fejdZe\e d1 re jZne jZGdd1d1ece-eBe-e0e.fedZe\e d΃ rVGdd΄deae-eBe-e0fe jdZej^d΃e)ddCedэZGdd d eBeedZddԄZej dddkZdZdZGdddeZGdd0d0ed|Zdd5ZeZdZGdddeBe2ZGdddee1ZGdddeeZGdddZede_eejej<ede2eejdddZede2eejddddZGdddZede_eejej<dS(N)abstractmethodabstractproperty)WrapperDescriptorTypeMethodWrapperTypeMethodDescriptorTypeAnyCallableClassVarGenericOptionalTupleTypeTypeVarUnion AbstractSet GenericMeta ByteString ContainerContextManagerHashable ItemsViewIterableIteratorKeysViewMapping MappingViewMutableMappingMutableSequence MutableSetSequenceSized ValuesView Reversible SupportsAbs SupportsBytesSupportsComplex SupportsFloat SupportsInt SupportsRoundCounterDequeDict DefaultDictListSet FrozenSet NamedTuple GeneratorAnyStrcastget_type_hintsNewType no_type_checkno_type_check_decoratoroverloadText TYPE_CHECKINGcCs"tjdddkr|jS|jSdS)Nrr)rr)sys version_info __qualname____name__)xrC+/opt/alt/python36/lib64/python3.6/typing.py _qualnamegsrEcCs&d}|jdr"||kr"|dd}|S)N _TypeAlias _ForwardRef _TypingBase_FinalTypingBase_)rFrGrHrI) startswith)ZnmZ whitelistrCrCrD _trim_nameos rMcsJeZdZdZdZddfdd ZddZdd Zd d Zd d Z Z S) TypingMetaaMetaclass for most types defined in typing module (not a part of public API). This overrides __new__() to require an extra keyword parameter '_root', which serves as a guard against naive subclassing of the typing classes. Any legitimate class defined using a metaclass derived from TypingMeta must pass _root=True. This also defines a dummy constructor (all the work for most typing constructs is done in __new__) and a nicer repr(). F)_rootcs2|s tddjtt|pdtj||||S)NzCannot subclass %sz, z()) TypeErrorjoinmap _type_reprsuper__new__)clsnamebases namespacerO) __class__rCrDrUszTypingMeta.__new__cOsdS)NrC)selfargskwdsrCrCrD__init__szTypingMeta.__init__cCs|S)a'Override this in subclasses to interpret forward references. For example, List['C'] is internally stored as List[_ForwardRef('C')], which should evaluate to List[C], where C is an object found in globalns or localns (searching localns first, of course). rC)r[globalnslocalnsrCrCrD _eval_typeszTypingMeta._eval_typecCsdS)NrC)r[tvarsrCrCrD_get_type_varsszTypingMeta._get_type_varscCstt|}d|j|fS)Nz%s.%s)rMrE __module__)r[qnamerCrCrD__repr__s zTypingMeta.__repr__) rArdr@__doc__ _is_protocolrUr^rarcrf __classcell__rCrC)rZrDrNvs  rNcsLeZdZdZdZddZfddZddZd d Zd d Z d dZ Z S)rHz0Internal indicator of special typing constructs. __weakref__cOsdS)NrC)r[r\r]rCrCrDr^sz_TypingBase.__init__cs@t|dkr4t|dtr4t|dtr4td|tj|S)zConstructor. This only exists to give a better error message in case someone tries to subclass a special typing object (not a good idea). rrrKzCannot subclass %r)len isinstancestrtuplerPrTrU)rVr\r])rZrCrDrUs   z_TypingBase.__new__cCs|S)NrC)r[r_r`rCrCrDrasz_TypingBase._eval_typecCsdS)NrC)r[rbrCrCrDrcsz_TypingBase._get_type_varscCs"t|}tt|}d|j|fS)Nz%s.%s)typerMrErd)r[rVrerCrCrDrfs z_TypingBase.__repr__cOstdt|dS)NzCannot instantiate %r)rPro)r[r\r]rCrCrD__call__sz_TypingBase.__call__)rj) rArdr@rg __slots__r^rUrarcrfrprirCrC)rZrDrHs rHT) metaclassrOcs2eZdZdZfZddfdd ZddZZS)rIzInternal mix-in class to prevent instantiation. Prevents instantiation unless _root=True is given in class call. It is used to create pseudo-singleton instances Any, Union, Optional, etc. F)rOcs0tj|f||}|dkr |Std|dS)NTzCannot instantiate %r)rTrUrP)rVrOr\r]r[)rZrCrDrUsz_FinalTypingBase.__new__cCstt|jS)N)rMrorA)r[rCrCrD __reduce__sz_FinalTypingBase.__reduce__)rArdr@rgrqrUrsrirCrC)rZrDrIsrI)rOcsTeZdZdZdZfddZdd Zd d Zd d ZddZ ddZ ddZ Z S)rGz-Internal wrapper to hold a forward reference.__forward_arg____forward_code____forward_evaluated____forward_value__c sttj|t|ts$td|fyt|dd}Wn"tk rVtd|fYnX||_||_d|_ d|_ dS)Nz,Forward reference must be a string -- got %rzevalz1Forward reference must be an expression -- got %rF) rTr^rlrmrPcompile SyntaxErrorrtrurvrw)r[argcode)rZrCrDr^s  z_ForwardRef.__init__cCsf|j s||k r`|dkr*|dkr*i}}n|dkr8|}n |dkrD|}tt|j||d|_d|_|jS)Nz*Forward references must evaluate to types.T)rv _type_checkrxrurw)r[r_r`rCrCrDras  z_ForwardRef._eval_typecCs&t|tstS|j|jko$|j|jkS)N)rlrGNotImplementedrtrw)r[otherrCrCrD__eq__s  z_ForwardRef.__eq__cCst|j|jfS)N)hashrtrw)r[rCrCrD__hash__sz_ForwardRef.__hash__cCs tddS)Nz4Forward references cannot be used with isinstance().)rP)r[objrCrCrD__instancecheck__sz_ForwardRef.__instancecheck__cCs tddS)Nz4Forward references cannot be used with issubclass().)rP)r[rVrCrCrD__subclasscheck__sz_ForwardRef.__subclasscheck__cCs d|jfS)Nz_ForwardRef(%r))rt)r[rCrCrDrf sz_ForwardRef.__repr__)rtrurvrw) rArdr@rgrqr^rarrrrrfrirCrC)rZrDrGs rGc@sLeZdZdZdZddZdd Zd d Zd d ZddZ ddZ ddZ dS)rFa:Internal helper class for defining generic variants of concrete types. Note that this is not a type; let's call it a pseudo-type. It cannot be used in instance and subclass checks in parameterized form, i.e. ``isinstance(42, Match[str])`` raises ``TypeError`` instead of returning ``False``. rWtype_var impl_type type_checkercCszt|tstt|t|ts,tt|t|t sDtt|t|ttfs^tt|||_||_||_ ||_ dS)atInitializer. Args: name: The name, e.g. 'Pattern'. type_var: The type parameter, e.g. AnyStr, or the specific type, e.g. str. impl_type: The implementation type. type_checker: Function that takes an impl_type instance. and returns a value that should be a type_var instance. N) rlrmAssertionErrorreprrorNrHrWrrr)r[rWrrrrCrCrDr^s z_TypeAlias.__init__cCsd|jt|jfS)Nz%s[%s])rWrSr)r[rCrCrDrf,sz_TypeAlias.__repr__cCst|jtstd||jjrJt|trJt||jjsJtd||jft|trj||jk rjtd||j|j||j |j S)Nz#%s cannot be further parameterized.z&%s is not a valid substitution for %s.z%s cannot be re-parameterized.) rlrrrP__constraints__ro issubclassrZrWrr)r[Z parameterrCrCrD __getitem__/s    z_TypeAlias.__getitem__cCs&t|tstS|j|jko$|j|jkS)N)rlrFr~rWr)r[rrCrCrDr;s z_TypeAlias.__eq__cCst|j|jfS)N)rrWr)r[rCrCrDr@sz_TypeAlias.__hash__cCs t|jtstdt||jS)Nz NoReturn: raise Exception('no way') This type is invalid in other positions, e.g., ``List[NoReturn]`` will fail in static type checkers. cCs tddS)Nz*NoReturn cannot be used with isinstance().)rP)r[rrCrCrDrsz_NoReturn.__instancecheck__cCs tddS)Nz*NoReturn cannot be used with issubclass().)rP)r[rVrCrCrDrsz_NoReturn.__subclasscheck__N)rArdr@rgrqrrrCrCrCrDrs rcsNeZdZdZdZdddd fd d Zd d ZddZddZddZ Z S)raType variable. Usage:: T = TypeVar('T') # Can be anything A = TypeVar('A', str, bytes) # Must be str or bytes Type variables exist primarily for the benefit of static type checkers. They serve as the parameters for generic types as well as for generic function definitions. See class Generic for more information on generic types. Generic functions work as follows: def repeat(x: T, n: int) -> List[T]: '''Return a list containing n references to x.''' return [x]*n def longest(x: A, y: A) -> A: '''Return the longest of two strings.''' return x if len(x) >= len(y) else y The latter example's signature is essentially the overloading of (str, str) -> str and (bytes, bytes) -> bytes. Also note that if the arguments are instances of some subclass of str, the return type is still plain str. At runtime, isinstance(x, T) and issubclass(C, T) will raise TypeError. Type variables defined with covariant=True or contravariant=True can be used do declare covariant or contravariant generic types. See PEP 484 for more details. By default generic types are invariant in all type variables. Type variables can be introspected. e.g.: T.__name__ == 'T' T.__constraints__ == () T.__covariant__ == False T.__contravariant__ = False A.__constraints__ == (str, bytes) rA __bound__r __covariant____contravariant__NF)bound covariant contravariantcstj|f||||d||_|r2|r2tdt||_t||_|rZ|dk rZtd|rrt|dkrrtddt fdd|D|_ |rt |d |_ nd|_ dS) N)rrrz"Bivariant types are not supported.z-Constraints cannot be combined with bound=...rKz"A single constraint is not allowedz:TypeVar(name, constraint, ...): constraints must be types.c3s|]}t|VqdS)N)r}).0r)rrCrD sz#TypeVar.__init__..zBound must be a type.) rTr^rA ValueErrorboolrrrPrkrnrr}r)r[rWrrrZ constraints)rZ)rrDr^s     zTypeVar.__init__cCs||kr|j|dS)N)append)r[rbrCrCrDrcszTypeVar._get_type_varscCs&|jr d}n|jrd}nd}||jS)N+-~)rrrA)r[prefixrCrCrDrf s zTypeVar.__repr__cCs tddS)Nz0Type variables cannot be used with isinstance().)rP)r[instancerCrCrDrszTypeVar.__instancecheck__cCs tddS)Nz0Type variables cannot be used with issubclass().)rP)r[rVrCrCrDrszTypeVar.__subclasscheck__)rArrrr) rArdr@rgrqr^rcrfrrrirCrC)rZrDrs( TKTVTT_co)rV_coVT_coT_contra)rcCsd|dkr g}t|dr0t|ttfr0|j||St|tr`x$t|D]\}}||krD||SqDW|S)zAn internal helper function: replace arg if it is a type variable found in tvars with corresponding substitution from args or with corresponding substitution sub-tree if arg is a generic type. N _subs_tree)hasattrrlrrHrr enumerate)r{rbr\iZtvarrCrCrD _replace_arg)s   rc Cs|jdkr|S|j}g}x|jdk r6|j||j}qWg}x |jD]}|jt|||qDWx8|D]0}g}x"|jD]}|jt||j|qtW|}qdW|S)aAn internal helper function: calculate substitution tree for generic cls after replacing its type parameters with substitutions in tvars -> args (if any). Repeat the same following __origin__'s. Return a list of arguments with all possible substitutions performed. Arguments that are generic classes themselves are represented as tuples (so that no new classes are created by this function). For example: _subs_tree(List[Tuple[int, T]][str]) == [(Tuple, int, str)] N)rr__args__r__parameters__) rVrbr\ZcurrentZ orig_chain tree_argsr{ZoclsZ new_tree_argsrCrCrDrDs       rcs*g}xn|D]f}t|tr0|jtkr0|j|jq t|trft|dkrf|dtkrf|j|ddq |j|q Wt |tt|krg}x(|D] }|kr|j|j |qW|} st t |x>|D]6tt sqt fddhDrڈj qWtfdd|DS)zAn internal helper for Union creation and substitution: flatten Union's among parameters, then remove duplicates and strict subclasses. rrKNc3s6|].}t|to|jdk st|to,t|VqdS)N)rlrrror)rZt2)t1rCrDrs z'_remove_dups_flatten..c3s|]}|kr|VqdS)NrC)rr) all_paramsrCrDrs)rlrrrextendrrnrkrsetremoverroany) parametersparamspZ new_paramsrrC)rrrD_remove_dups_flattenes0 "     rcCsX|jstdt|t|}t|j}||krTtd||kr@dndt|||fdS)Nz%s is not a generic classz0Too %s parameters for %s; actual %s, expected %sZmanyZfew)rrPrrk)rVrZalenZelenrCrCrD_check_generics rcs4tjtjjtjfdd}|S)zInternal wrapper caching __getitem__ of generic types with a fallback to original function for non-hashable arguments. c s*y ||Stk rYnX||S)N)rP)r\r])cachedfuncrCrDinners  z_tp_cache..inner) functools lru_cache _cleanupsr cache_clearwraps)rrrC)rrrD _tp_caches  rcseZdZdZdZd ddfd d Zd d Zd dZfddZfddZ e ddZ d!ddZ ddZ ddZddZddZZS)"raUnion type; Union[X, Y] means either X or Y. To define a union, use e.g. Union[int, str]. Details: - The arguments must be types and there must be at least one. - None as an argument is a special case and is replaced by type(None). - Unions of unions are flattened, e.g.:: Union[Union[int, str], float] == Union[int, str, float] - Unions of a single argument vanish, e.g.:: Union[int] == int # The constructor actually returns int - Redundant arguments are skipped, e.g.:: Union[int, str, int] == Union[int, str] - When comparing unions, the argument order is ignored, e.g.:: Union[int, str] == Union[str, int] - When two arguments have a subclass relationship, the least derived argument is kept, e.g.:: class Employee: pass class Manager(Employee): pass Union[int, Employee, Manager] == Union[int, Employee] Union[Manager, int, Employee] == Union[int, Employee] Union[Employee, Manager] == Employee - Similar for object:: Union[int, object] == object - You cannot subclass or instantiate a union. - You can use Optional[X] as a shorthand for Union[X, None]. rrr __tree_hash__NF)rOcstj|||f|d|i}|dkrHd|_d|_d|_ttd|_|St|t sZt d|t kr~t |}t |dkr~|dSt||_||_||_|j}t|t rtt||_n t||_|S)NrOrzExpected parameters=rKr)r)rTrUrrrr frozensetrrlrnrPrrrkrr)rVroriginrOr\r[Z subs_tree)rZrCrDrUs*     z_Union.__new__cs^|jdkr|Stfdd|jD}t|j}||jkrN||jkrN|S|j||ddS)Nc3s|]}t|VqdS)N)ra)rr)r_r`rCrDrsz$_Union._eval_type..T)rO)rrnrarrZ)r[r_r`ev_args ev_originrC)r_r`rDras z_Union._eval_typecCs|jr|jrt|j|dS)N)rrrc)r[rbrCrCrDrcs z_Union._get_type_varscs<|jdkrtjS|j}t|ts.t|S|dj|S)Nr)rrTrfrrlrnr _tree_repr)r[tree)rZrCrDrfs    z_Union.__repr__cs`g}xB|ddD]2}t|ts0|jt|q|j|dj|qWtjddj|S)NrKrz[%s]z, )rlrnrrSrrTrfrQ)r[rarg_listr{)rZrCrDr s  z_Union._tree_reprcsl|fkrtdt|ts |f}|jdkr0dndtfdd|D}|tk r\t|||j||ddS)Nz Cannot take a Union of no types.z)Union[arg, ...]: each arg must be a type.z*Parameters to generic types must be types.c3s|]}t|VqdS)N)r})rr)rrCrDr sz%_Union.__getitem__..T)rrO)rPrlrnrrrrZ)r[rrC)rrDrs   z_Union.__getitem__cCs>|tkr tSt|||}t|}t|dkr4|dStf|S)NrKr)rrrrk)r[rbr\rrCrCrDr%s  z_Union._subs_treecCs6t|tr|j|jkS|tk r*|j|kS||kSdS)N)rlrrrr)r[rrCrCrDr.s    z _Union.__eq__cCs|jS)N)r)r[rCrCrDr6sz_Union.__hash__cCs tddS)Nz(Unions cannot be used with isinstance().)rP)r[rrCrCrDr9sz_Union.__instancecheck__cCs tddS)Nz(Unions cannot be used with issubclass().)rP)r[rVrCrCrDr<sz_Union.__subclasscheck__)rrrr)NN)NN)rArdr@rgrqrUrarcrfrrrrrrrrrirCrC)rZrDrs*    rc@s eZdZdZfZeddZdS)rzEOptional type. Optional[X] is equivalent to Union[X, None]. cCst|d}t|tdfS)Nz#Optional[t] requires a single type.)r}rro)r[r{rCrCrDrKs z_Optional.__getitem__N)rArdr@rgrqrrrCrCrCrDrCsrcCsJt}x@t|jddD]*\}}t|tr|jtkr|j|d}qW|S)zHelper for Generic.__new__. Returns the class after the last occurrence of Generic or Generic[...] in cls.__mro__. NrK)objectr__mro__rlrrr )rVZ next_in_mrorcrCrCrD _next_in_mroTs rcs,tjtjrfdd}n fdd}|S)zConstruct a __subclasshook__ callable that incorporates the associated __extra__ class in subclass checks performed against cls. csZjj|}|tk r|Sj|jkr(dSx,jjD]}t|trDq4t||r4dSq4WtS)NT) __extra____subclasshook__r~r__subclasses__rlrr)subclassresscls)rVrCrD __extrahook__ks    z)_make_subclasshook..__extrahook__csjrt|jrdStS)NT)rrr~)r)rVrCrDrys)rlrabcABCMeta)rVrrC)rVrD_make_subclasshookbs rcCs2t|}d|kr.x|dD]}|j|dqW|S)zInternal helper: copy class __dict__ and clean slots class variables. (They will be re-created if necessary by normal class machinery.) rqN)dictpop)ZdctZ dict_copyZslotrCrCrD_no_slots_copys rcseZdZdZd!fdd ZeddZejddZedd Zejd d Zd d Z d dZ fddZ fddZ d"ddZ ddZddZeddZfddZddZfdd ZZS)#racMetaclass for generic types. This is a metaclass for typing.Generic and generic ABCs defined in typing module. User defined subclasses of GenericMeta can override __new__ and invoke super().__new__. Note that GenericMeta.__new__ has strict rules on what is allowed in its bases argument: * plain Generic is disallowed in bases; * Generic[...] should appear in bases at most once; * if Generic[...] is present, then it should list all type variables that appear in other bases. In addition, type of all generic bases is erased, e.g., C[int] is stripped to plain C. Nc s|dk r0|dk sttdd|Ds.t|n|dks@t||dksPt||dks`t|t|}d} xF|D]>} | tkrtdt| trr| jtkrr| dk rtd| j} qrW| dkr|} nRt |} t | | kstddj fdd|Ddj d d| Df| }|} |dk rFt |t j krF||krF|f|}td d|D}td d|Dr~td d|D}|j|||sdn|jd tj||||dd} tt| jd|s| n|j|| _|rtdd|Dnd| _t| | _|dkr| | _d|kr|s2t| jdddkr.z!Cannot inherit from plain Genericz0Cannot inherit from Generic[...] multiple types.z6Some type variables (%s) are not listed in Generic[%s]z, c3s|]}|krt|VqdS)N)rm)rr)gvarsetrCrDrscss|]}t|VqdS)N)rm)rgrCrCrDrscss"|]}t|tr|jn|VqdS)N)rlrr)rbrCrCrDrscss |]}t|to|tk VqdS)N)rlrr )rrrCrCrDrscss|]}|tk r|VqdS)N)r )rrrCrCrDrs)rrrT)rOrcss*|]"}|tkrdn|tkrfn|VqdS).N)_TypingEllipsis _TypingEmpty)rarCrCrDrsrrArr@)$rallrr rPrlrrrrrQrorrrnrupdaterrTrU __setattr__rr__next_in_mro____orig_bases__rrr _abc_registry _abc_cacherr@rrrr)rVrWrXrYrbr\rextra orig_basesZgvarsbaseZtvarsetZ initial_basesr[)rZ)rrDrUsr      $       zGenericMeta.__new__cCst|jtjr|jjS|jjS)N)rlrrr_abc_negative_cacher_abc_generic_negative_cache)r[rCrCrDrszGenericMeta._abc_negative_cachecCs,|jdkr(t|jtjr"||j_n||_dS)N)rrlrrrrr)r[valuerCrCrDrs  cCst|jtjr|jjS|jjS)N)rlrrr_abc_negative_cache_versionr#_abc_generic_negative_cache_version)r[rCrCrDr sz'GenericMeta._abc_negative_cache_versioncCs,|jdkr(t|jtjr"||j_n||_dS)N)rrlrrrrr)r[rrCrCrDrs  cCs|jr|jrt|j|dS)N)rrrc)r[rbrCrCrDrcs zGenericMeta._get_type_varsc s|jr|jjnd}|jr8tfdd|jDnd}||jkrT||jkrT|S|j|j|jt|j|rtt |nd|||j |j dS)Nc3s|]}t|VqdS)N)ra)rr)r_r`rCrDrsz)GenericMeta._eval_type..)rbr\rrr) rrarrnrZrA __bases__r__dict__rrr)r[r_r`rrrC)r_r`rDras$zGenericMeta._eval_typecs"|jdkrtjS|j|jS)N)rrTrfrr)r[)rZrCrDrf+s  zGenericMeta.__repr__cstg}xV|ddD]F}|fkr*|jdqt|tsD|jt|q|j|dj|qWtjddj|S)NrKz()rz[%s]z, )rrlrnrSrrTrfrQ)r[rrr{)rZrCrDr0s  zGenericMeta._tree_reprcCs*|jdkr|St|||}|jft|S)N)rrrrn)r[rbr\rrCrCrDr;s  zGenericMeta._subs_treecCs6t|tstS|jdks"|jdkr*||kS|j|jkS)N)rlrr~rr)r[rrCrCrDrAs  zGenericMeta.__eq__cCs|jS)N)r)r[rCrCrDrHszGenericMeta.__hash__c s6t|ts|f}| r0|jtk r0tdt|dtfdd|D}|tkrtdd|Dsltdtt |t|krtd|}|}nb|tt fkrt |}|}nH|t kr|}|}n6|j tt fkrtdt|nt||t |}|}|j dkr|fnf}|j|j||jt|j||||j|jd S) Nz)Parameter list to %s[...] cannot be emptyz*Parameters to generic types must be types.c3s|]}t|VqdS)N)r})rr)rrCrDrSsz*GenericMeta.__getitem__..css|]}t|tVqdS)N)rlr)rrrCrCrDrVsz5Parameters to Generic[...] must all be type variablesz-Parameters to Generic[...] must all be uniquez'Cannot subscript already-subscripted %s)rbr\rrr)rlrnrrrPrEr rrkrr rrrrrrZrArrrrr)r[rrbr\ZprependrC)rrDrKsJ   zGenericMeta.__getitem__csJ|jdk r*tjdjddkr&tddS|tkr>td|tj|S) NrKrArrzCParameterized generics cannot be used with class or instance checksFz5Class %r cannot be used with class or instance checks)rr)rr> _getframe f_globalsrPr rTr)r[rV)rZrCrDrys zGenericMeta.__subclasscheck__cCs t|j|S)N)rrZ)r[rrCrCrDrszGenericMeta.__instancecheck__csT|jdr|jds(|jds(|jdkr VT: ... # Etc. This class can then be used as follows:: def lookup_name(mapping: Mapping[KT, VT], key: KT, default: VT) -> VT: try: return mapping[key] except KeyError: return default cOs&|jtkrtdt|j|f||S)NzHType Generic cannot be instantiated; it can be used only as a base class)rr rPr r)rVr\r]rCrCrDrUs zGeneric.__new__N)rArdr@rgrqrUrCrCrCrDr s)rrc@seZdZdZdS)rzInternal placeholder for () or []. Used by TupleMeta and CallableMeta to allow empty list/tuple in specific places, without allowing them to sneak in where prohibited. N)rArdr@rgrCrCrCrDrsrc@seZdZdZdS)rz(Internal placeholder for ... (ellipsis).N)rArdr@rgrCrCrCrDrsrcs4eZdZdZefddZddZddZZS) TupleMetazMetaclass for Tuple (internal).cs|jdk s|jtk r tj|S|fkr6tjtfSt|tsF|f}t|dkr|ddkrdt |d}tj|t fSdtfdd|D}tj|S) NrrK.z Tuple[t, ...]: t must be a type.rz*Tuple[t0, t1, ...]: each t must be a type.c3s|]}t|VqdS)N)r})rr)rrCrDrsz(TupleMeta.__getitem__..) rrrrTrrrlrnrkr}r)r[rr)rZ)rrDrs  zTupleMeta.__getitem__cCs |jdkrt|tStddS)Nz5Parameterized Tuple cannot be used with isinstance().)rrlrnrP)r[rrCrCrDrs  zTupleMeta.__instancecheck__cCs |jdkrt|tStddS)Nz5Parameterized Tuple cannot be used with issubclass().)rrrnrP)r[rVrCrCrDrs  zTupleMeta.__subclasscheck__) rArdr@rgrrrrrirCrC)rZrDr sr c@seZdZdZfZddZdS)ra@Tuple type; Tuple[X, Y] is the cross-product type of X and Y. Example: Tuple[T1, T2] is a tuple of two elements corresponding to type variables T1 and T2. Tuple[int, float, str] is a tuple of an int, a float and a string. To specify a variable-length tuple of homogeneous type, use Tuple[T, ...]. cOs$|jtkrtdtt|f||S)Nz6Type Tuple cannot be instantiated; use tuple() instead)rrrPr rn)rVr\r]rCrCrDrU s z Tuple.__new__N)rArdr@rgrqrUrCrCrCrDrs)rrrcsHeZdZdZfddZfddZfddZefdd ZZ S) CallableMetaz"Metaclass for Callable (internal).cs"|jdkrtjS|j|jS)N)rrTrfrr)r[)rZrCrDrfs  zCallableMeta.__repr__cs|jtk rtj|Sg}xB|ddD]2}t|tsF|jt|q(|j|dj|q(W|ddkrt|dd|dSt|dddj |dd|dfS) NrKrz...z [..., %s]z [[%s], %s]z, rr) rr rTrrlrnrrSrrQ)r[rrr{)rZrCrDrs     zCallableMeta._tree_reprcs|jdk s|jtk r tj|St|t s8t|dkr@td|\}}|t krZt |f}n$t|t srtd|ft||f}|j |S)zxA thin wrapper around __getitem_inner__ to provide the latter with hashable arguments to improve speed. Nrz6Callable must be used as Callable[[arg, ...], result].z8Callable[args, result]: args must be a list. Got %.100r.) rrr rTrrlrnrkrPEllipsislist__getitem_inner__)r[rr\result)rZrCrDr*s     zCallableMeta.__getitem__cs^|\}}dt|}|tkr.tjt|fSdtfdd|D}||f}tj|S)Nz.Callable[args, result]: result must be a type.z6Callable[[arg, ...], result]: each arg must be a type.c3s|]}t|VqdS)N)r})rr{)rrCrDrFsz1CallableMeta.__getitem_inner__..)r}rrTrrrn)r[rr\r)rZ)rrDr>s  zCallableMeta.__getitem_inner__) rArdr@rgrfrrrrrirCrC)rZrDrs    rc@seZdZdZfZddZdS)r aCallable type; Callable[[int], str] is a function of (int) -> str. The subscription syntax must always be used with exactly two values: the argument list and the return type. The argument list must be a list of types or ellipsis; the return type must be a single type. There is no syntax to indicate optional or keyword arguments, such function types are rarely used as callback types. cOs&|jtkrtdt|j|f||S)NzIType Callable cannot be instantiated; use a non-abstract subclass instead)rr rPr r)rVr\r]rCrCrDrUXs zCallable.__new__N)rArdr@rgrqrUrCrCrCrDr Ks csNeZdZdZdZdddZddZdd Zfd d Zd d Z ddZ Z S)ra3Special type construct to mark class variables. An annotation wrapped in ClassVar indicates that a given attribute is intended to be used as a class variable and should not be set on instances of that class. Usage:: class Starship: stats: ClassVar[Dict[str, int]] = {} # class variable damage: int = 10 # instance variable ClassVar accepts only types and cannot be further subscribed. Note that ClassVar is not a class itself, and should not be used with isinstance() or issubclass(). __type__NcKs ||_dS)N)r)r[tpr]rCrCrDr^rsz_ClassVar.__init__cCsPt|}|jdkr4|t|dj|jddddStdj|jdddS)Nz{} accepts only single type.rKT)rOz {} cannot be further subscripted)rorr}formatrArP)r[itemrVrCrCrDrus z_ClassVar.__getitem__cCs,t|j||}||jkr|St||ddS)NT)rO)rarro)r[r_r`Znew_tprCrCrDra~s z_ClassVar._eval_typecs,tj}|jdk r(|djt|j7}|S)Nz[{}])rTrfrrrS)r[r)rZrCrDrfs  z_ClassVar.__repr__cCstt|j|jfS)N)rrorAr)r[rCrCrDrsz_ClassVar.__hash__cCs,t|tstS|jdk r$|j|jkS||kS)N)rlrr~r)r[rrCrCrDrs    z_ClassVar.__eq__)r)N) rArdr@rgrqr^rrarfrrrirCrC)rZrDr_s   rcCs|S)zCast a value to a type. This returns the value unchanged. To the type checker this signals that the return value has the designated type, but at runtime we intentionally don't check anything (we want this to be as fast as possible). rC)typvalrCrCrDr6sc Csy |j}Wntk riSX|j}|j}|d|}|jp@f}|j}|rTt|ni}|t|}x2t||d|D]\}} ||kst | ||<qxW|S)z:Internal helper to extract the default arguments, by name.N) __code__r  co_argcount co_varnames __defaults____kwdefaults__rrkzipr) rr|Z pos_countZ arg_namesdefaultsZ kwdefaultsrZ pos_offsetrWrrCrCrD _get_defaultss      r!c Cst|ddriSt|tri}xt|jD]z}|dkrFtj|jj}n|}|jj di}xJ|j D]>\}}|dkrztd}t|t rt |}t |||}|||<qbWq*W|S|dkrt|tjr|j}n t|di}|dkr|}n |dkr|}t|dd}|dkr"t|triStdj|t|} t|}xp|j D]d\}}|dkrVtd}t|t rjt |}t |||}|| kr| |dkrt|}|||<qmodulesrdrgetitemsrmrGrar ModuleType_allowed_typesrPrr!rr) rr_r`ZhintsrZ base_globalsZannrWrr rCrCrDr7sV            c Cst|tr||jj}x0|jjD]"\}}||j|fkr |j|q Wx4|jD](}t|tj rfd|_ t|trPt |qPWy d|_ Wnt k rYnX|S)aIDecorator to indicate that annotations are not type hints. The argument must be a class or function; if it is a class, it applies recursively to all methods and classes defined in that class (but not to methods defined in its superclasses or subclasses). This mutates the function(s) or class(es) in place. T) rlrorcopyr(rrvaluesrrr"r9rP)r{Z arg_attrsrrrrCrCrDr9s      cstjfdd}|S)zDecorator to give another decorator the @no_type_check effect. This wraps the decorator with something that wraps the decorated function in @no_type_check. cs||}t|}|S)N)r9)r\r]r) decoratorrCrDwrapped_decorator/s z2no_type_check_decorator..wrapped_decorator)rr)r-r.rC)r-rDr:(scOs tddS)z*Helper for @overload to raise when called.zYou should not call an overloaded function. A series of @overload-decorated functions outside a stub module should always be followed by an implementation that is not @overload-ed.N)NotImplementedError)r\r]rCrCrD_overload_dummy8sr0cCstS)a Decorator for overloaded functions/methods. In a stub file, place two or more stub definitions for the same function in a row, each decorated with @overload. For example: @overload def utf8(value: None) -> None: ... @overload def utf8(value: bytes) -> bytes: ... @overload def utf8(value: str) -> bytes: ... In a non-stub file (i.e. a regular .py file), do the same but follow it with an implementation. The implementation should *not* be decorated with @overload. For example: @overload def utf8(value: None) -> None: ... @overload def utf8(value: bytes) -> bytes: ... @overload def utf8(value: str) -> bytes: ... def utf8(value): # implementation goes here )r0)rrCrCrDr;Ascs0eZdZdZfddZddZddZZS) _ProtocolMetaz~Internal metaclass for _Protocol. This exists so _Protocol classes can be generic without deriving from Generic. cs"t|jkrtj|StddS)Nz+Protocols cannot be used with isinstance().)rrrTrrP)r[r)rZrCrDres  z_ProtocolMeta.__instancecheck__csL|js tS|tkrdS|j}x(|D] tfdd|jDs$dSq$WdS)NTc3s|]}|jkVqdS)N)r)rd)rrCrDrwsz2_ProtocolMeta.__subclasscheck__..F)rhr~r_get_protocol_attrsrr)r[rVattrsrC)rrDrjs z_ProtocolMeta.__subclasscheck__cCs,g}x.|jD]$}t|ddr |jdkr |j|q Wt}x|D]}x|jjD]}x|jD]&}||k r`||jkr`t|dd r`Pq`W|jd rT|dkrT|dkrT|dkrT|dkrT|dkrT|d krT|d krT|d krT|d krT|d krT|dkrT|dkrT|dkrT|dkrT|dkrT|dkrT|j|qTWqBW|S)NrhFrr__abstractmethods__r#rjrrrrqr3rrrrrrrd) rrrArrrkeysrLadd)r[Zprotocol_basesrr4rrrCrCrDr3{s<   z!_ProtocolMeta._get_protocol_attrs)rArdr@rgrrr3rirCrC)rZrDr1^s r1c@seZdZdZfZdZdS)rzInternal base class for protocol classes. This implements a simple-minded structural issubclass check (similar but more general than the one-offs in collections.abc such as Hashable). TN)rArdr@rgrqrhrCrCrCrDrsr Awaitablec@seZdZfZdS)r8N)rArdr@rqrCrCrCrDr8s)r Coroutinec@seZdZfZdS)r9N)rArdr@rqrCrCrCrDr9s AsyncIterablec@seZdZfZdS)r:N)rArdr@rqrCrCrCrDr:sc@seZdZfZdS) AsyncIteratorN)rArdr@rqrCrCrCrDr;sr;c@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@s"eZdZfZeedddZdS)r*)returncCsdS)NrC)r[rCrCrD__int__szSupportsInt.__int__N)rArdr@rqrintr=rCrCrCrDr*sc@s"eZdZfZeedddZdS)r))r<cCsdS)NrC)r[rCrCrD __float__szSupportsFloat.__float__N)rArdr@rqrfloatr?rCrCrCrDr)sc@s"eZdZfZeedddZdS)r()r<cCsdS)NrC)r[rCrCrD __complex__szSupportsComplex.__complex__N)rArdr@rqrcomplexrArCrCrCrDr(sc@s"eZdZfZeedddZdS)r')r<cCsdS)NrC)r[rCrCrD __bytes__szSupportsBytes.__bytes__N)rArdr@rqrbytesrCrCrCrCrDr'sc@s"eZdZfZeedddZdS)r&)r<cCsdS)NrC)r[rCrCrD__abs__szSupportsAbs.__abs__N)rArdr@rqrrrErCrCrCrDr&sc@s&eZdZfZedeedddZdS)r+r)ndigitsr<cCsdS)NrC)r[rFrCrCrD __round__szSupportsRound.__round__N)r)rArdr@rqrr>rrGrCrCrCrDr+sc@seZdZfZdS)r%N)rArdr@rqrCrCrCrDr% sc@s"eZdZfZeddddZdS)r%zIterator[T_co])r<cCsdS)NrC)r[rCrCrD __reversed__szReversible.__reversed__N)rArdr@rqrrHrCrCrCrDr% sc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrs Collectionc@seZdZfZdS)rIN)rArdr@rqrCrCrCrDrIsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDr'sc@seZdZfZdS)rN)rArdr@rqrCrCrCrDr+sc@seZdZfZdS)r!N)rArdr@rqrCrCrCrDr!0sc@seZdZfZdS)rN)rArdr@rqrCrCrCrDr6sc@seZdZfZdS)rN)rArdr@rqrCrCrCrDr:sc@seZdZfZdS)rN)rArdr@rqrCrCrCrDr?sc@seZdZfZdS)r"N)rArdr@rqrCrCrCrDr"Esc@seZdZfZdS)r"N)rArdr@rqrCrCrCrDr"Isc@seZdZfZdS)r"N)rArdr@rqrCrCrCrDr"Msc@seZdZfZdS)r N)rArdr@rqrCrCrCrDr Rsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrVsc@seZdZfZddZdS)r0cOs$|jtkrtdtt|f||S)Nz4Type List cannot be instantiated; use list() instead)rr0rPr r)rVr\r]rCrCrDrU^s z List.__new__N)rArdr@rqrUrCrCrCrDr0Zsc@seZdZfZddZdS)r-cOs*|jtkrtj||Sttj|f||S)N)rr- collectionsdequer )rVr\r]rCrCrDrUis  z Deque.__new__N)rArdr@rqrUrCrCrCrDr-esc@seZdZfZddZdS)r1cOs$|jtkrtdtt|f||S)Nz2Type Set cannot be instantiated; use set() instead)rr1rPr r)rVr\r]rCrCrDrUss z Set.__new__N)rArdr@rqrUrCrCrCrDr1osc@seZdZfZddZdS)r2cOs$|jtkrtdtt|f||S)Nz>Type FrozenSet cannot be instantiated; use frozenset() instead)rr2rPr r)rVr\r]rCrCrDrU}s zFrozenSet.__new__N)rArdr@rqrUrCrCrCrDr2zsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@seZdZfZdS)r$N)rArdr@rqrCrCrCrDr$sAbstractContextManagerc@seZdZfZdS)rN)rArdr@rqrCrCrCrDrsc@s2eZdZfZddZejddZeddZ dS)rcCs|S)NrC)r[rCrCrD __enter__szContextManager.__enter__cCsdS)NrC)r[exc_type exc_value tracebackrCrCrD__exit__szContextManager.__exit__cCs8|tkr4tdd|jDr4tdd|jDr4dStS)Ncss|]}d|jkVqdS)rMN)r)rBrCrCrDrsz2ContextManager.__subclasshook__..css|]}d|jkVqdS)rQN)r)rrRrCrCrDrsT)rrrr~)rVCrCrCrDrs zContextManager.__subclasshook__N) rArdr@rqrMrrrQ classmethodrrCrCrCrDrsAbstractAsyncContextManagerc@seZdZfZdS)AsyncContextManagerN)rArdr@rqrCrCrCrDrVsrVa class AsyncContextManager(Generic[T_co]): __slots__ = () async def __aenter__(self): return self @abc.abstractmethod async def __aexit__(self, exc_type, exc_value, traceback): return None @classmethod def __subclasshook__(cls, C): if cls is AsyncContextManager: if sys.version_info[:2] >= (3, 6): return _collections_abc._check_methods(C, "__aenter__", "__aexit__") if (any("__aenter__" in B.__dict__ for B in C.__mro__) and any("__aexit__" in B.__dict__ for B in C.__mro__)): return True return NotImplemented __all__.append('AsyncContextManager') c@seZdZfZddZdS)r.cOs$|jtkrtdtt|f||S)Nz4Type Dict cannot be instantiated; use dict() instead)rr.rPr r)rVr\r]rCrCrDrUs z Dict.__new__N)rArdr@rqrUrCrCrCrDr.sc@seZdZfZddZdS)r/cOs*|jtkrtj||Sttj|f||S)N)rr/rJ defaultdictr )rVr\r]rCrCrDrUs  zDefaultDict.__new__N)rArdr@rqrUrCrCrCrDr/sc@seZdZfZddZdS)r,cOs*|jtkrtj||Sttj|f||S)N)rr,rJr )rVr\r]rCrCrDrUs  zCounter.__new__N)rArdr@rqrUrCrCrCrDr,sChainMapc@seZdZfZddZdS)rYcOs*|jtkrtj||Sttj|f||S)N)rrYrJr )rVr\r]rCrCrDrUs  zChainMap.__new__N)rArdr@rqrUrCrCrCrDrYsc@seZdZfZddZdS)r4cOs$|jtkrtdtt|f||S)Nz@Type Generator cannot be instantiated; create a subclass instead)rr4rPr _G_base)rVr\r]rCrCrDrUs zGenerator.__new__N)rArdr@rqrUrCrCrCrDr4 sAsyncGeneratorc@seZdZfZdS)r[N)rArdr@rqrCrCrCrDr[sCT_co)rrc@seZdZdZfZdS)raA special construct usable to annotate class objects. For example, suppose we have the following classes:: class User: ... # Abstract base for User classes class BasicUser(User): ... class ProUser(User): ... class TeamUser(User): ... And a function that takes a class argument that's a subclass of User and returns an instance of the corresponding class:: U = TypeVar('U', bound=User) def new_user(user_class: Type[U]) -> U: user = user_class() # (Here we could write the user object to a database) return user joe = new_user(BasicUser) At this point the type checker knows that joe has type BasicUser. N)rArdr@rgrqrCrCrCrDr$sc svdfdd|D}tj|dd|D}tj||_|_ytjdjjdd|_ Wnt t fk rpYnX|S)NzDNamedTuple('Name', [(f0, t0), (f1, t1), ...]); each t must be a typecsg|]\}}|t|fqSrC)r})rnr)rrCrD Asz!_make_nmtuple..cSsg|] \}}|qSrCrC)rr]rrCrCrDr^BsrrA__main__) rJ namedtuple OrderedDictr# _field_typesr>rrr'rdr r)rWrnm_tplrC)rrD _make_nmtuple?srdrUr^rq__getnewargs___fields_field_defaultsrb_make_replace_asdict_sourcerdrAr@r#cseZdZfddZZS)NamedTupleMetac s|jddrtj||||Sts*td|jdi}t||j}g}i}xP|D]H}||krz||} |j| | ||<qR|rRtdj|dj |j dqRWt j ||j_ t||j_||_xD|D]<} | tkrtd| q| tko| |jkrt|| || qW|S) NrOFz= 3.6:: class Employee(NamedTuple): name: str id: int This is equivalent to:: Employee = collections.namedtuple('Employee', ['name', 'id']) The resulting class has extra __annotations__ and _field_types attributes, giving an ordered dict mapping field names to types. __annotations__ should be preferred, while _field_types is kept to maintain pre PEP 526 compatibility. (The field names are in the _fields attribute, which is part of the namedtuple API.) Alternative equivalent keyword syntax is also accepted:: Employee = NamedTuple('Employee', name=str, id=int) In Python versions <= 3.5 use:: Employee = NamedTuple('Employee', [('name', str), ('id', int)]) TNcKs:|rt rtd|dkr$|j}n |r0tdt||S)Nz>Keyword syntax for NamedTuple is only supported in Python 3.6+zIEither list of fields or keywords can be provided to NamedTuple, not both)rnrPr(rd)r[rrZfieldskwargsrCrCrDrUs  zNamedTuple.__new__)N)rArdr@rgrOrUrCrCrCrDr3yscCsdd}||_||_|S)a%NewType creates simple unique types with almost zero runtime overhead. NewType(name, tp) is considered a subtype of tp by static type checkers. At runtime, NewType(name, tp) returns a dummy function that simply returns its argument. Usage:: UserId = NewType('UserId', int) def name_by_id(user_id: UserId) -> str: ... UserId('user') # Fails type check name_by_id(42) # Fails type check name_by_id(UserId(42)) # OK num = UserId(5) + 1 # type: int cSs|S)NrC)rBrCrCrDnew_typeszNewType..new_type)rAZ __supertype__)rWrrvrCrCrDr8sFc@seZdZdZfZeedddZeedddZe dddd Z e e dd d Z e e dd d Ze ddddZe e dddZe d7e edddZe e dddZe d9e edddZe d;e eedddZe dIOaGeneric base class for TextIO and BinaryIO. This is an abstract, generic version of the return of open(). NOTE: This does not distinguish between the different possible classes (text vs. binary, read vs. write vs. read/write, append-only, unbuffered). The TextIO and BinaryIO subclasses below capture the distinctions between text vs. binary, which is pervasive in the interface; however we currently do not offer a way to track the other distinctions in the type system. )r<cCsdS)NrC)r[rCrCrDmodeszIO.modecCsdS)NrC)r[rCrCrDrWszIO.nameNcCsdS)NrC)r[rCrCrDcloseszIO.closecCsdS)NrC)r[rCrCrDclosedsz IO.closedcCsdS)NrC)r[rCrCrDfilenosz IO.filenocCsdS)NrC)r[rCrCrDflushszIO.flushcCsdS)NrC)r[rCrCrDisattysz IO.isattyrK)r]r<cCsdS)NrC)r[r]rCrCrDreadszIO.readcCsdS)NrC)r[rCrCrDreadablesz IO.readable)limitr<cCsdS)NrC)r[rrCrCrDreadlinesz IO.readline)hintr<cCsdS)NrC)r[rrCrCrD readlinessz IO.readlinesr)offsetwhencer<cCsdS)NrC)r[rrrCrCrDseekszIO.seekcCsdS)NrC)r[rCrCrDseekable sz IO.seekablecCsdS)NrC)r[rCrCrDtell szIO.tell)sizer<cCsdS)NrC)r[rrCrCrDtruncate sz IO.truncatecCsdS)NrC)r[rCrCrDwritable sz IO.writable)sr<cCsdS)NrC)r[rrCrCrDwrite szIO.write)linesr<cCsdS)NrC)r[rrCrCrD writelines sz IO.writelinesz IO[AnyStr]cCsdS)NrC)r[rCrCrDrM sz IO.__enter__cCsdS)NrC)r[rorrPrCrCrDrQ sz IO.__exit__r)rr)rr)r)r)N) rArdr@rgrqrrmrxrWrryrrzr>r{r|r}r5r~rrr0rrrrrrrrrMrQrCrCrCrDrwsT rwc@sBeZdZdZfZeeeefe dddZ eddddZ dS) BinaryIOz5Typed version of the return of open() in binary mode.)rr<cCsdS)NrC)r[rrCrCrDr) szBinaryIO.write)r<cCsdS)NrC)r[rCrCrDrM- szBinaryIO.__enter__N) rArdr@rgrqrrrD bytearrayr>rrMrCrCrCrDr$ s rc@seZdZdZfZeedddZeedddZ ee edddZ ee dd d Z eedd d Zeddd dZdS)TextIOz3Typed version of the return of open() in text mode.)r<cCsdS)NrC)r[rCrCrDbuffer7 sz TextIO.buffercCsdS)NrC)r[rCrCrDencoding; szTextIO.encodingcCsdS)NrC)r[rCrCrDerrors? sz TextIO.errorscCsdS)NrC)r[rCrCrDline_bufferingC szTextIO.line_bufferingcCsdS)NrC)r[rCrCrDnewlinesG szTextIO.newlinescCsdS)NrC)r[rCrCrDrMK szTextIO.__enter__N)rArdr@rgrqrrrrmrrrrrr rrrMrCrCrCrDr2 src@s&eZdZdZdddgZeZeZeZdS)ioz)Wrapper namespace for IO generic classes.rwrrN)rArdr@rg__all__rwrrrCrCrCrDrP s  rz.ioPatternrcCs|jS)N)pattern)rrCrCrD^ srMatchcCs|jjS)N)rer)mrCrCrDr` sc@s eZdZdZddgZeZeZdS)rz&Wrapper namespace for re type aliases.rrN)rArdr@rgrrrrCrCrCrDrc srz.re)rr)NN)NN)rrW)rr) rUr^rqrerfrgrbrhrirjrk)rdrAr@r#)rrrrJ contextlibrrZ stdlib_rer>rcollections.abcZcollections_abc ImportErrorr?_collections_abcrrr rorr^__str__rmrQrrErMrNrHrIrGrFrcrrar}rSrr rZNoReturnrrrrrrrrrDr5rrrrrrrrrrrrrrrr r rrr rnrrr rr r6r!rBuiltinFunctionType MethodTyper)r*r7r9r:r0r;r1rrrr8rr9r:r;rrr*r)r(r'r&r+r%r#rrIr1rr!rrr"r r>rrr0rKr-rrr2rrrr$rLrrUrVexecrr.rXr/r,rYr4rZ GeneratorTyper[r\rrdrnrorprlr3r8r<r=rwrrrrAr&ryrmatchrrCrCrCrDs   *%5C  W      !)    "96    R D                  "                   "      "(`