/opt/alt/python311/lib64/python3.11/__pycache__
NameSizeModeActions
abc.cpython-311.opt-1.pyc90540644editdlrm
abc.cpython-311.opt-2.pyc58540644editdlrm
abc.cpython-311.pyc90540644editdlrm
aifc.cpython-311.opt-1.pyc455220644editdlrm
aifc.cpython-311.opt-2.pyc403150644editdlrm
aifc.cpython-311.pyc455220644editdlrm
antigravity.cpython-311.opt-1.pyc12700644editdlrm
antigravity.cpython-311.opt-2.pyc11330644editdlrm
antigravity.cpython-311.pyc12700644editdlrm
argparse.cpython-311.opt-1.pyc1137050644editdlrm
argparse.cpython-311.opt-2.pyc1040020644editdlrm
argparse.cpython-311.pyc1139960644editdlrm
ast.cpython-311.opt-1.pyc1094160644editdlrm
ast.cpython-311.opt-2.pyc1010450644editdlrm
ast.cpython-311.pyc1096770644editdlrm
asynchat.cpython-311.opt-1.pyc119000644editdlrm
asynchat.cpython-311.opt-2.pyc105440644editdlrm
asynchat.cpython-311.pyc119000644editdlrm
asyncore.cpython-311.opt-1.pyc282020644editdlrm
asyncore.cpython-311.opt-2.pyc269970644editdlrm
asyncore.cpython-311.pyc282020644editdlrm
base64.cpython-311.opt-1.pyc280340644editdlrm
base64.cpython-311.opt-2.pyc234340644editdlrm
base64.cpython-311.pyc284600644editdlrm
bdb.cpython-311.opt-1.pyc386870644editdlrm
bdb.cpython-311.opt-2.pyc293420644editdlrm
bdb.cpython-311.pyc386870644editdlrm
bisect.cpython-311.opt-1.pyc37140644editdlrm
bisect.cpython-311.opt-2.pyc24200644editdlrm
bisect.cpython-311.pyc37140644editdlrm
bz2.cpython-311.opt-1.pyc161760644editdlrm
bz2.cpython-311.opt-2.pyc112940644editdlrm
bz2.cpython-311.pyc161760644editdlrm
calendar.cpython-311.opt-1.pyc447540644editdlrm
calendar.cpython-311.opt-2.pyc405230644editdlrm
calendar.cpython-311.pyc447540644editdlrm
cgi.cpython-311.opt-1.pyc438750644editdlrm
cgi.cpython-311.opt-2.pyc353450644editdlrm
cgi.cpython-311.pyc438750644editdlrm
cgitb.cpython-311.opt-1.pyc188950644editdlrm
cgitb.cpython-311.opt-2.pyc173280644editdlrm
cgitb.cpython-311.pyc188950644editdlrm
chunk.cpython-311.opt-1.pyc74400644editdlrm
chunk.cpython-311.opt-2.pyc53360644editdlrm
chunk.cpython-311.pyc74400644editdlrm
cmd.cpython-311.opt-1.pyc206110644editdlrm
cmd.cpython-311.opt-2.pyc152760644editdlrm
cmd.cpython-311.pyc206110644editdlrm
code.cpython-311.opt-1.pyc139150644editdlrm
code.cpython-311.opt-2.pyc87250644editdlrm
code.cpython-311.pyc139150644editdlrm
codecs.cpython-311.opt-1.pyc452580644editdlrm
codecs.cpython-311.opt-2.pyc298990644editdlrm
codecs.cpython-311.pyc452580644editdlrm
codeop.cpython-311.opt-1.pyc77440644editdlrm
codeop.cpython-311.opt-2.pyc47450644editdlrm
codeop.cpython-311.pyc77440644editdlrm
colorsys.cpython-311.opt-1.pyc49650644editdlrm
colorsys.cpython-311.opt-2.pyc43580644editdlrm
colorsys.cpython-311.pyc49650644editdlrm
compileall.cpython-311.opt-1.pyc215990644editdlrm
compileall.cpython-311.opt-2.pyc183650644editdlrm
compileall.cpython-311.pyc215990644editdlrm
configparser.cpython-311.opt-1.pyc718210644editdlrm
configparser.cpython-311.opt-2.pyc568550644editdlrm
configparser.cpython-311.pyc718210644editdlrm
contextlib.cpython-311.opt-1.pyc330660644editdlrm
contextlib.cpython-311.opt-2.pyc269420644editdlrm
contextlib.cpython-311.pyc330830644editdlrm
contextvars.cpython-311.opt-1.pyc3130644editdlrm
contextvars.cpython-311.opt-2.pyc3130644editdlrm
contextvars.cpython-311.pyc3130644editdlrm
copy.cpython-311.opt-1.pyc112010644editdlrm
copy.cpython-311.opt-2.pyc89180644editdlrm
copy.cpython-311.pyc112010644editdlrm
copyreg.cpython-311.opt-1.pyc81600644editdlrm
copyreg.cpython-311.opt-2.pyc73810644editdlrm
copyreg.cpython-311.pyc81940644editdlrm
cProfile.cpython-311.opt-1.pyc90880644editdlrm
cProfile.cpython-311.opt-2.pyc86250644editdlrm
cProfile.cpython-311.pyc90880644editdlrm
crypt.cpython-311.opt-1.pyc58520644editdlrm
crypt.cpython-311.opt-2.pyc52050644editdlrm
crypt.cpython-311.pyc58520644editdlrm
csv.cpython-311.opt-1.pyc200700644editdlrm
csv.cpython-311.opt-2.pyc180520644editdlrm
csv.cpython-311.pyc200700644editdlrm
dataclasses.cpython-311.opt-1.pyc471880644editdlrm
dataclasses.cpython-311.opt-2.pyc435660644editdlrm
dataclasses.cpython-311.pyc472390644editdlrm
datetime.cpython-311.opt-1.pyc981620644editdlrm
datetime.cpython-311.opt-2.pyc903150644editdlrm
datetime.cpython-311.pyc1013500644editdlrm
decimal.cpython-311.opt-1.pyc5570644editdlrm
decimal.cpython-311.opt-2.pyc5570644editdlrm
decimal.cpython-311.pyc5570644editdlrm
difflib.cpython-311.opt-1.pyc816120644editdlrm
difflib.cpython-311.opt-2.pyc483430644editdlrm
difflib.cpython-311.pyc816620644editdlrm
dis.cpython-311.opt-1.pyc366550644editdlrm
dis.cpython-311.opt-2.pyc322980644editdlrm
dis.cpython-311.pyc366950644editdlrm
doctest.cpython-311.opt-1.pyc1126310644editdlrm
doctest.cpython-311.opt-2.pyc775720644editdlrm
doctest.cpython-311.pyc1130200644editdlrm
enum.cpython-311.opt-1.pyc880100644editdlrm
enum.cpython-311.opt-2.pyc785760644editdlrm
enum.cpython-311.pyc880100644editdlrm
filecmp.cpython-311.opt-1.pyc157240644editdlrm
filecmp.cpython-311.opt-2.pyc131060644editdlrm
filecmp.cpython-311.pyc157240644editdlrm
fileinput.cpython-311.opt-1.pyc211820644editdlrm
fileinput.cpython-311.opt-2.pyc157290644editdlrm
fileinput.cpython-311.pyc211820644editdlrm
fnmatch.cpython-311.opt-1.pyc73390644editdlrm
fnmatch.cpython-311.opt-2.pyc61560644editdlrm
fnmatch.cpython-311.pyc74850644editdlrm
fractions.cpython-311.opt-1.pyc292570644editdlrm
fractions.cpython-311.opt-2.pyc221940644editdlrm
fractions.cpython-311.pyc292570644editdlrm
ftplib.cpython-311.opt-1.pyc476610644editdlrm
ftplib.cpython-311.opt-2.pyc375010644editdlrm
ftplib.cpython-311.pyc476610644editdlrm
functools.cpython-311.opt-1.pyc466490644editdlrm
functools.cpython-311.opt-2.pyc400610644editdlrm
functools.cpython-311.pyc466490644editdlrm
genericpath.cpython-311.opt-1.pyc61750644editdlrm
genericpath.cpython-311.opt-2.pyc51440644editdlrm
genericpath.cpython-311.pyc61750644editdlrm
getopt.cpython-311.opt-1.pyc96790644editdlrm
getopt.cpython-311.opt-2.pyc71380644editdlrm
getopt.cpython-311.pyc97460644editdlrm
getpass.cpython-311.opt-1.pyc75270644editdlrm
getpass.cpython-311.opt-2.pyc63590644editdlrm
getpass.cpython-311.pyc75270644editdlrm
gettext.cpython-311.opt-1.pyc242660644editdlrm
gettext.cpython-311.opt-2.pyc235920644editdlrm
gettext.cpython-311.pyc242660644editdlrm
glob.cpython-311.opt-1.pyc111450644editdlrm
glob.cpython-311.opt-2.pyc102040644editdlrm
glob.cpython-311.pyc112230644editdlrm
graphlib.cpython-311.opt-1.pyc109990644editdlrm
graphlib.cpython-311.opt-2.pyc76050644editdlrm
graphlib.cpython-311.pyc110810644editdlrm
gzip.cpython-311.opt-1.pyc337330644editdlrm
gzip.cpython-311.opt-2.pyc294310644editdlrm
gzip.cpython-311.pyc337330644editdlrm
hashlib.cpython-311.opt-1.pyc123520644editdlrm
hashlib.cpython-311.opt-2.pyc113630644editdlrm
hashlib.cpython-311.pyc123520644editdlrm
heapq.cpython-311.opt-1.pyc205900644editdlrm
heapq.cpython-311.opt-2.pyc174990644editdlrm
heapq.cpython-311.pyc205900644editdlrm
hmac.cpython-311.opt-1.pyc114850644editdlrm
hmac.cpython-311.opt-2.pyc90170644editdlrm
hmac.cpython-311.pyc114850644editdlrm
imaplib.cpython-311.opt-1.pyc668450644editdlrm
imaplib.cpython-311.opt-2.pyc545430644editdlrm
imaplib.cpython-311.pyc690640644editdlrm
imghdr.cpython-311.opt-1.pyc78550644editdlrm
imghdr.cpython-311.opt-2.pyc76950644editdlrm
imghdr.cpython-311.pyc78550644editdlrm
imp.cpython-311.opt-1.pyc164740644editdlrm
imp.cpython-311.opt-2.pyc141870644editdlrm
imp.cpython-311.pyc164740644editdlrm
inspect.cpython-311.opt-1.pyc1412920644editdlrm
inspect.cpython-311.opt-2.pyc1159140644editdlrm
inspect.cpython-311.pyc1416620644editdlrm
io.cpython-311.opt-1.pyc50520644editdlrm
io.cpython-311.opt-2.pyc35620644editdlrm
io.cpython-311.pyc50520644editdlrm
ipaddress.cpython-311.opt-1.pyc969240644editdlrm
ipaddress.cpython-311.opt-2.pyc719470644editdlrm
ipaddress.cpython-311.pyc969240644editdlrm
keyword.cpython-311.opt-1.pyc10840644editdlrm
keyword.cpython-311.opt-2.pyc6750644editdlrm
keyword.cpython-311.pyc10840644editdlrm
linecache.cpython-311.opt-1.pyc74600644editdlrm
linecache.cpython-311.opt-2.pyc62710644editdlrm
linecache.cpython-311.pyc74600644editdlrm
locale.cpython-311.opt-1.pyc644150644editdlrm
locale.cpython-311.opt-2.pyc599690644editdlrm
locale.cpython-311.pyc644150644editdlrm
lzma.cpython-311.opt-1.pyc167330644editdlrm
lzma.cpython-311.opt-2.pyc106380644editdlrm
lzma.cpython-311.pyc167330644editdlrm
mailbox.cpython-311.opt-1.pyc1245290644editdlrm
mailbox.cpython-311.opt-2.pyc1190480644editdlrm
mailbox.cpython-311.pyc1246310644editdlrm
mailcap.cpython-311.opt-1.pyc127990644editdlrm
mailcap.cpython-311.opt-2.pyc112650644editdlrm
mailcap.cpython-311.pyc127990644editdlrm
mimetypes.cpython-311.opt-1.pyc261410644editdlrm
mimetypes.cpython-311.opt-2.pyc202050644editdlrm
mimetypes.cpython-311.pyc261410644editdlrm
modulefinder.cpython-311.opt-1.pyc309310644editdlrm
modulefinder.cpython-311.opt-2.pyc300490644editdlrm
modulefinder.cpython-311.pyc310340644editdlrm
netrc.cpython-311.opt-1.pyc99040644editdlrm
netrc.cpython-311.opt-2.pyc96780644editdlrm
netrc.cpython-311.pyc99040644editdlrm
nntplib.cpython-311.opt-1.pyc501760644editdlrm
nntplib.cpython-311.opt-2.pyc388850644editdlrm
nntplib.cpython-311.pyc501760644editdlrm
ntpath.cpython-311.opt-1.pyc306040644editdlrm
ntpath.cpython-311.opt-2.pyc286550644editdlrm
ntpath.cpython-311.pyc306040644editdlrm
nturl2path.cpython-311.opt-1.pyc35040644editdlrm
nturl2path.cpython-311.opt-2.pyc30980644editdlrm
nturl2path.cpython-311.pyc35040644editdlrm
numbers.cpython-311.opt-1.pyc152660644editdlrm
numbers.cpython-311.opt-2.pyc116720644editdlrm
numbers.cpython-311.pyc152660644editdlrm
opcode.cpython-311.opt-1.pyc138680644editdlrm
opcode.cpython-311.opt-2.pyc137270644editdlrm
opcode.cpython-311.pyc138680644editdlrm
operator.cpython-311.opt-1.pyc187750644editdlrm
operator.cpython-311.opt-2.pyc165580644editdlrm
operator.cpython-311.pyc187750644editdlrm
optparse.cpython-311.opt-1.pyc736260644editdlrm
optparse.cpython-311.opt-2.pyc614080644editdlrm
optparse.cpython-311.pyc737320644editdlrm
os.cpython-311.opt-1.pyc490220644editdlrm
os.cpython-311.opt-2.pyc369940644editdlrm
os.cpython-311.pyc490400644editdlrm
pathlib.cpython-311.opt-1.pyc677360644editdlrm
pathlib.cpython-311.opt-2.pyc593030644editdlrm
pathlib.cpython-311.pyc677360644editdlrm
pdb.cpython-311.opt-1.pyc867040644editdlrm
pdb.cpython-311.opt-2.pyc729640644editdlrm
pdb.cpython-311.pyc868240644editdlrm
pickle.cpython-311.opt-1.pyc866510644editdlrm
pickle.cpython-311.opt-2.pyc808360644editdlrm
pickle.cpython-311.pyc869100644editdlrm
pickletools.cpython-311.opt-1.pyc845710644editdlrm
pickletools.cpython-311.opt-2.pyc756570644editdlrm
pickletools.cpython-311.pyc867470644editdlrm
pipes.cpython-311.opt-1.pyc119820644editdlrm
pipes.cpython-311.opt-2.pyc91590644editdlrm
pipes.cpython-311.pyc119820644editdlrm
pkgutil.cpython-311.opt-1.pyc315940644editdlrm
pkgutil.cpython-311.opt-2.pyc249380644editdlrm
pkgutil.cpython-311.pyc315940644editdlrm
platform.cpython-311.opt-1.pyc437370644editdlrm
platform.cpython-311.opt-2.pyc357780644editdlrm
platform.cpython-311.pyc437370644editdlrm
plistlib.cpython-311.opt-1.pyc458050644editdlrm
plistlib.cpython-311.opt-2.pyc433770644editdlrm
plistlib.cpython-311.pyc459550644editdlrm
poplib.cpython-311.opt-1.pyc209840644editdlrm
poplib.cpython-311.opt-2.pyc161680644editdlrm
poplib.cpython-311.pyc209840644editdlrm
posixpath.cpython-311.opt-1.pyc199990644editdlrm
posixpath.cpython-311.opt-2.pyc183700644editdlrm
posixpath.cpython-311.pyc199990644editdlrm
pprint.cpython-311.opt-1.pyc335240644editdlrm
pprint.cpython-311.opt-2.pyc313730644editdlrm
pprint.cpython-311.pyc335790644editdlrm
profile.cpython-311.opt-1.pyc235000644editdlrm
profile.cpython-311.opt-2.pyc205350644editdlrm
profile.cpython-311.pyc239700644editdlrm
pstats.cpython-311.opt-1.pyc418830644editdlrm
pstats.cpython-311.opt-2.pyc390050644editdlrm
pstats.cpython-311.pyc418830644editdlrm
pty.cpython-311.opt-1.pyc84560644editdlrm
pty.cpython-311.opt-2.pyc77000644editdlrm
pty.cpython-311.pyc84560644editdlrm
pyclbr.cpython-311.opt-1.pyc158940644editdlrm
pyclbr.cpython-311.opt-2.pyc128660644editdlrm
pyclbr.cpython-311.pyc158940644editdlrm
pydoc.cpython-311.opt-1.pyc1582610644editdlrm
pydoc.cpython-311.opt-2.pyc1486370644editdlrm
pydoc.cpython-311.pyc1583210644editdlrm
py_compile.cpython-311.opt-1.pyc107900644editdlrm
py_compile.cpython-311.opt-2.pyc74780644editdlrm
py_compile.cpython-311.pyc107900644editdlrm
queue.cpython-311.opt-1.pyc164690644editdlrm
queue.cpython-311.opt-2.pyc122070644editdlrm
queue.cpython-311.pyc164690644editdlrm
quopri.cpython-311.opt-1.pyc104810644editdlrm
quopri.cpython-311.opt-2.pyc94790644editdlrm
quopri.cpython-311.pyc108730644editdlrm
random.cpython-311.opt-1.pyc345400644editdlrm
random.cpython-311.opt-2.pyc274330644editdlrm
random.cpython-311.pyc345400644editdlrm
reprlib.cpython-311.opt-1.pyc96940644editdlrm
reprlib.cpython-311.opt-2.pyc95440644editdlrm
reprlib.cpython-311.pyc96940644editdlrm
rlcompleter.cpython-311.opt-1.pyc90260644editdlrm
rlcompleter.cpython-311.opt-2.pyc63900644editdlrm
rlcompleter.cpython-311.pyc90260644editdlrm
runpy.cpython-311.opt-1.pyc161320644editdlrm
runpy.cpython-311.opt-2.pyc137170644editdlrm
runpy.cpython-311.pyc161320644editdlrm
sched.cpython-311.opt-1.pyc84180644editdlrm
sched.cpython-311.opt-2.pyc54320644editdlrm
sched.cpython-311.pyc84180644editdlrm
secrets.cpython-311.opt-1.pyc28780644editdlrm
secrets.cpython-311.opt-2.pyc18560644editdlrm
secrets.cpython-311.pyc28780644editdlrm
selectors.cpython-311.opt-1.pyc285550644editdlrm
selectors.cpython-311.opt-2.pyc245250644editdlrm
selectors.cpython-311.pyc285550644editdlrm
shelve.cpython-311.opt-1.pyc138890644editdlrm
shelve.cpython-311.opt-2.pyc97420644editdlrm
shelve.cpython-311.pyc138890644editdlrm
shlex.cpython-311.opt-1.pyc147190644editdlrm
shlex.cpython-311.opt-2.pyc142080644editdlrm
shlex.cpython-311.pyc147190644editdlrm
shutil.cpython-311.opt-1.pyc732600644editdlrm
shutil.cpython-311.opt-2.pyc611130644editdlrm
shutil.cpython-311.pyc732600644editdlrm
signal.cpython-311.opt-1.pyc51220644editdlrm
signal.cpython-311.opt-2.pyc49130644editdlrm
signal.cpython-311.pyc51220644editdlrm
site.cpython-311.opt-1.pyc304890644editdlrm
site.cpython-311.opt-2.pyc250480644editdlrm
site.cpython-311.pyc304890644editdlrm
smtpd.cpython-311.opt-1.pyc436810644editdlrm
smtpd.cpython-311.opt-2.pyc410780644editdlrm
smtpd.cpython-311.pyc436810644editdlrm
smtplib.cpython-311.opt-1.pyc539710644editdlrm
smtplib.cpython-311.opt-2.pyc378020644editdlrm
smtplib.cpython-311.pyc541360644editdlrm
sndhdr.cpython-311.opt-1.pyc124420644editdlrm
sndhdr.cpython-311.opt-2.pyc111130644editdlrm
sndhdr.cpython-311.pyc124420644editdlrm
socket.cpython-311.opt-1.pyc456550644editdlrm
socket.cpython-311.opt-2.pyc371220644editdlrm
socket.cpython-311.pyc456990644editdlrm
socketserver.cpython-311.opt-1.pyc370720644editdlrm
socketserver.cpython-311.opt-2.pyc265040644editdlrm
socketserver.cpython-311.pyc370720644editdlrm
sre_compile.cpython-311.opt-1.pyc8290644editdlrm
sre_compile.cpython-311.opt-2.pyc8290644editdlrm
sre_compile.cpython-311.pyc8290644editdlrm
sre_constants.cpython-311.opt-1.pyc8320644editdlrm
sre_constants.cpython-311.opt-2.pyc8320644editdlrm
sre_constants.cpython-311.pyc8320644editdlrm
sre_parse.cpython-311.opt-1.pyc8250644editdlrm
sre_parse.cpython-311.opt-2.pyc8250644editdlrm
sre_parse.cpython-311.pyc8250644editdlrm
ssl.cpython-311.opt-1.pyc736170644editdlrm
ssl.cpython-311.opt-2.pyc627880644editdlrm
ssl.cpython-311.pyc736170644editdlrm
stat.cpython-311.opt-1.pyc55540644editdlrm
stat.cpython-311.opt-2.pyc49480644editdlrm
stat.cpython-311.pyc55540644editdlrm
statistics.cpython-311.opt-1.pyc581590644editdlrm
statistics.cpython-311.opt-2.pyc386260644editdlrm
statistics.cpython-311.pyc584190644editdlrm
string.cpython-311.opt-1.pyc126540644editdlrm
string.cpython-311.opt-2.pyc115550644editdlrm
string.cpython-311.pyc126540644editdlrm
stringprep.cpython-311.opt-1.pyc264710644editdlrm
stringprep.cpython-311.opt-2.pyc262480644editdlrm
stringprep.cpython-311.pyc265430644editdlrm
struct.cpython-311.opt-1.pyc3960644editdlrm
struct.cpython-311.opt-2.pyc3960644editdlrm
struct.cpython-311.pyc3960644editdlrm
subprocess.cpython-311.opt-1.pyc846830644editdlrm
subprocess.cpython-311.opt-2.pyc726980644editdlrm
subprocess.cpython-311.pyc848250644editdlrm
sunau.cpython-311.opt-1.pyc270200644editdlrm
sunau.cpython-311.opt-2.pyc224280644editdlrm
sunau.cpython-311.pyc270200644editdlrm
symtable.cpython-311.opt-1.pyc193230644editdlrm
symtable.cpython-311.opt-2.pyc168420644editdlrm
symtable.cpython-311.pyc195230644editdlrm
sysconfig.cpython-311.opt-1.pyc317000644editdlrm
sysconfig.cpython-311.opt-2.pyc289900644editdlrm
sysconfig.cpython-311.pyc317000644editdlrm
tabnanny.cpython-311.opt-1.pyc129640644editdlrm
tabnanny.cpython-311.opt-2.pyc120360644editdlrm
tabnanny.cpython-311.pyc129640644editdlrm
tarfile.cpython-311.opt-1.pyc1312090644editdlrm
tarfile.cpython-311.opt-2.pyc1170070644editdlrm
tarfile.cpython-311.pyc1312270644editdlrm
telnetlib.cpython-311.opt-1.pyc310950644editdlrm
telnetlib.cpython-311.opt-2.pyc237600644editdlrm
telnetlib.cpython-311.pyc310950644editdlrm
tempfile.cpython-311.opt-1.pyc421740644editdlrm
tempfile.cpython-311.opt-2.pyc355510644editdlrm
tempfile.cpython-311.pyc421740644editdlrm
textwrap.cpython-311.opt-1.pyc195890644editdlrm
textwrap.cpython-311.opt-2.pyc124570644editdlrm
textwrap.cpython-311.pyc196110644editdlrm
this.cpython-311.opt-1.pyc16120644editdlrm
this.cpython-311.opt-2.pyc16120644editdlrm
this.cpython-311.pyc16120644editdlrm
threading.cpython-311.opt-1.pyc692040644editdlrm
threading.cpython-311.opt-2.pyc512410644editdlrm
threading.cpython-311.pyc703270644editdlrm
timeit.cpython-311.opt-1.pyc164680644editdlrm
timeit.cpython-311.opt-2.pyc106500644editdlrm
timeit.cpython-311.pyc164680644editdlrm
token.cpython-311.opt-1.pyc37390644editdlrm
token.cpython-311.opt-2.pyc37070644editdlrm
token.cpython-311.pyc37390644editdlrm
tokenize.cpython-311.opt-1.pyc303040644editdlrm
tokenize.cpython-311.opt-2.pyc264950644editdlrm
tokenize.cpython-311.pyc303740644editdlrm
trace.cpython-311.opt-1.pyc359780644editdlrm
trace.cpython-311.opt-2.pyc330840644editdlrm
trace.cpython-311.pyc359780644editdlrm
traceback.cpython-311.opt-1.pyc486910644editdlrm
traceback.cpython-311.opt-2.pyc387230644editdlrm
traceback.cpython-311.pyc487370644editdlrm
tracemalloc.cpython-311.opt-1.pyc291000644editdlrm
tracemalloc.cpython-311.opt-2.pyc277320644editdlrm
tracemalloc.cpython-311.pyc291000644editdlrm
tty.cpython-311.opt-1.pyc20410644editdlrm
tty.cpython-311.opt-2.pyc19430644editdlrm
tty.cpython-311.pyc20410644editdlrm
types.cpython-311.opt-1.pyc148350644editdlrm
types.cpython-311.opt-2.pyc134240644editdlrm
types.cpython-311.pyc148350644editdlrm
typing.cpython-311.opt-1.pyc1608380644editdlrm
typing.cpython-311.opt-2.pyc1237120644editdlrm
typing.cpython-311.pyc1616710644editdlrm
uu.cpython-311.opt-1.pyc88110644editdlrm
uu.cpython-311.opt-2.pyc85790644editdlrm
uu.cpython-311.pyc88110644editdlrm
uuid.cpython-311.opt-1.pyc328060644editdlrm
uuid.cpython-311.opt-2.pyc251790644editdlrm
uuid.cpython-311.pyc330830644editdlrm
warnings.cpython-311.opt-1.pyc240640644editdlrm
warnings.cpython-311.opt-2.pyc213670644editdlrm
warnings.cpython-311.pyc250770644editdlrm
wave.cpython-311.opt-1.pyc322810644editdlrm
wave.cpython-311.opt-2.pyc257690644editdlrm
wave.cpython-311.pyc323520644editdlrm
weakref.cpython-311.opt-1.pyc349320644editdlrm
weakref.cpython-311.opt-2.pyc316910644editdlrm
weakref.cpython-311.pyc349730644editdlrm
webbrowser.cpython-311.opt-1.pyc328100644editdlrm
webbrowser.cpython-311.opt-2.pyc304600644editdlrm
webbrowser.cpython-311.pyc328360644editdlrm
xdrlib.cpython-311.opt-1.pyc131580644editdlrm
xdrlib.cpython-311.opt-2.pyc126760644editdlrm
xdrlib.cpython-311.pyc131580644editdlrm
zipapp.cpython-311.opt-1.pyc115550644editdlrm
zipapp.cpython-311.opt-2.pyc104030644editdlrm
zipapp.cpython-311.pyc115550644editdlrm
zipfile.cpython-311.opt-1.pyc1190680644editdlrm
zipfile.cpython-311.opt-2.pyc1092990644editdlrm
zipfile.cpython-311.pyc1191190644editdlrm
zipimport.cpython-311.opt-1.pyc296850644editdlrm
zipimport.cpython-311.opt-2.pyc259980644editdlrm
zipimport.cpython-311.pyc298030644editdlrm
_aix_support.cpython-311.opt-1.pyc43800644editdlrm
_aix_support.cpython-311.opt-2.pyc30470644editdlrm
_aix_support.cpython-311.pyc43800644editdlrm
_bootsubprocess.cpython-311.opt-1.pyc44730644editdlrm
_bootsubprocess.cpython-311.opt-2.pyc42430644editdlrm
_bootsubprocess.cpython-311.pyc44730644editdlrm
_collections_abc.cpython-311.opt-1.pyc512290644editdlrm
_collections_abc.cpython-311.opt-2.pyc452090644editdlrm
_collections_abc.cpython-311.pyc512290644editdlrm
_compat_pickle.cpython-311.opt-1.pyc73440644editdlrm
_compat_pickle.cpython-311.opt-2.pyc73440644editdlrm
_compat_pickle.cpython-311.pyc75290644editdlrm
_compression.cpython-311.opt-1.pyc80630644editdlrm
_compression.cpython-311.opt-2.pyc78570644editdlrm
_compression.cpython-311.pyc80630644editdlrm
_markupbase.cpython-311.opt-1.pyc138300644editdlrm
_markupbase.cpython-311.opt-2.pyc134550644editdlrm
_markupbase.cpython-311.pyc140950644editdlrm
_osx_support.cpython-311.opt-1.pyc199390644editdlrm
_osx_support.cpython-311.opt-2.pyc173490644editdlrm
_osx_support.cpython-311.pyc199390644editdlrm
_pydecimal.cpython-311.opt-1.pyc2442740644editdlrm
_pydecimal.cpython-311.opt-2.pyc1641520644editdlrm
_pydecimal.cpython-311.pyc2442740644editdlrm
_pyio.cpython-311.opt-1.pyc1200870644editdlrm
_pyio.cpython-311.opt-2.pyc977120644editdlrm
_pyio.cpython-311.pyc1201520644editdlrm
_py_abc.cpython-311.opt-1.pyc78170644editdlrm
_py_abc.cpython-311.opt-2.pyc66400644editdlrm
_py_abc.cpython-311.pyc78910644editdlrm
_sitebuiltins.cpython-311.opt-1.pyc54370644editdlrm
_sitebuiltins.cpython-311.opt-2.pyc49100644editdlrm
_sitebuiltins.cpython-311.pyc54370644editdlrm
_strptime.cpython-311.opt-1.pyc279210644editdlrm
_strptime.cpython-311.opt-2.pyc242570644editdlrm
_strptime.cpython-311.pyc279210644editdlrm
_sysconfigdata_d_linux_x86_64-linux-gnu.cpython-311.opt-1.pyc631680644editdlrm
_sysconfigdata_d_linux_x86_64-linux-gnu.cpython-311.opt-2.pyc631680644editdlrm
_sysconfigdata_d_linux_x86_64-linux-gnu.cpython-311.pyc631680644editdlrm
_sysconfigdata__linux_x86_64-linux-gnu.cpython-311.opt-1.pyc636590644editdlrm
_sysconfigdata__linux_x86_64-linux-gnu.cpython-311.opt-2.pyc636590644editdlrm
_sysconfigdata__linux_x86_64-linux-gnu.cpython-311.pyc636590644editdlrm
_threading_local.cpython-311.opt-1.pyc92180644editdlrm
_threading_local.cpython-311.opt-2.pyc59090644editdlrm
_threading_local.cpython-311.pyc92180644editdlrm
_weakrefset.cpython-311.opt-1.pyc131530644editdlrm
_weakrefset.cpython-311.opt-2.pyc131530644editdlrm
_weakrefset.cpython-311.pyc131530644editdlrm
__future__.cpython-311.opt-1.pyc49270644editdlrm
__future__.cpython-311.opt-2.pyc28790644editdlrm
__future__.cpython-311.pyc49270644editdlrm
__hello__.cpython-311.opt-1.pyc10910644editdlrm
__hello__.cpython-311.opt-2.pyc10370644editdlrm
__hello__.cpython-311.pyc10910644editdlrm
Edit: /opt/alt/python311/lib64/python3.11/__pycache__/doctest.cpython-311.opt-1.pyc (112631B)
/g9 dZdZgdZddlZddlZddlZddlZddlZddlZddl Z ddl Z ddl Z ddl Z ddl mZmZddlmZeddZiZd Zed Zed Zed Zed ZedZedZeezezezezezZedZedZedZedZedZ eezezeze zZ!dZ"dZ#dZ$dZdZ%dZ&dZ'd[dZ(dZ)Gdd eZ*d!Z+d"Z,d#Z-Gd$d%ej.Z/d&Z0Gd'd(Z1Gd)d*Z2Gd+d,Z3Gd-d.Z4Gd/d0Z5Gd1d2Z6Gd3d4e7Z8Gd5d6e7Z9Gd7d8e5Z:da; d\d;ZZ>da?d?Z@Gd@dAe jAZBGdBdCeBZCGdDdEe jDZEd^dFZFGdGdHeBZGd9dde3dfdIZHdJZIdKZJdLZKd_dMZLd_dNZMd`dOZNGdPdQZOeOdRdSdTdUdVdWZPdXZQeRdYkre jSeQdSdS)aaModule doctest -- a framework for running examples in docstrings. In simplest use, end each module M to be tested with: def _test(): import doctest doctest.testmod() if __name__ == "__main__": _test() Then running the module as a script will cause the examples in the docstrings to get executed and verified: python M.py This won't display anything unless an example fails, in which case the failing example(s) and the cause(s) of the failure(s) are printed to stdout (why not stderr? because stderr is a lame hack <0.2 wink>), and the final line of output is "Test failed.". Run it with the -v switch instead: python M.py -v and a detailed report of all examples tried is printed to stdout, along with assorted summaries at the end. You can force verbose mode by passing "verbose=True" to testmod, or prohibit it by passing "verbose=False". In either of those cases, sys.argv is not examined by testmod. There are a variety of other ways to run doctests, including integration with the unittest framework, and support for running non-Python text files containing doctests. There are also many ways to override parts of doctest's default behaviors. See the Library Reference Manual for details. zreStructuredText en)!register_optionflagDONT_ACCEPT_TRUE_FOR_1DONT_ACCEPT_BLANKLINENORMALIZE_WHITESPACEELLIPSISSKIPIGNORE_EXCEPTION_DETAILCOMPARISON_FLAGS REPORT_UDIFF REPORT_CDIFF REPORT_NDIFFREPORT_ONLY_FIRST_FAILUREREPORTING_FLAGS FAIL_FASTExampleDocTest DocTestParser DocTestFinder DocTestRunner OutputCheckerDocTestFailureUnexpectedException DebugRunnertestmodtestfilerun_docstring_examples DocTestSuite DocFileSuiteset_unittest_reportflagsscript_from_examples testsource debug_srcdebugN)StringIOIncrementalNewlineDecoder) namedtuple TestResultszfailed attemptedcbt|dttzS)N)OPTIONFLAGS_BY_NAME setdefaultlennames ./opt/alt/python311/lib64/python3.11/doctest.pyrrs&  ) )$S9L5M5M0M N NNrrrrrrr r r r rz z...cd}tjD]9}||d}|tt|ur ||jz}:|S)z Return the compiler-flags associated with the future features that have been imported into the given namespace (globs). r#N) __future__all_feature_namesgetgetattr compiler_flag)globsflagsfnamefeatures r/_extract_future_flagsr;sV E-++))E4(( gj%00 0 0 W* *E Lr0c.tj|r|St|tr+t |t t dgS|/tjtj |j dStd)a Return the module specified by `module`. In particular: - If `module` is a module, then return module. - If `module` is a string, then import and return the module with that name. - If `module` is None, then return the calling module. The calling module is assumed to be the module of the stack frame at the given depth in the call stack. *N__name__z"Expected a module, string, or None) inspectismodule isinstancestr __import__globalslocalssysmodules _getframe f_globals TypeError)moduledepths r/_normalize_modulerNs> FC >&'))VXXu=== {3=//9*EFF<===r0cJtdd|dSNT)r%decode)datas r/_newline_convertrSs" $T4 0 0 7 7d C CCr0c|rt|d}t||}t|ddx} |jj}n#t $rYnwxYwt |dr;||}||}t||fSt||5}| |fcdddS#1swxYwYdS)N __loader__get_data)encoding) rN_module_relative_pathr5__spec__loaderAttributeErrorhasattrrWrQrSopenread)filenamepackagemodule_relativerXr[ file_contentsfs r/_load_testfileres@ =#GQ//((;;g|T:: :F C  )0!     6: & & ="OOH55M)00::M$M22H< < h * * *"avvxx!""""""""""""""""""s# A AA0CCCc4tjd|dz|S)z~ Add the given number of space characters to the beginning of every non-blank line in `s`, and return the result. z (?m)^(?!$) )resub)sindents r/_indentrms 6,s A . ..r0ct}|\}}}tj|||||S)zz Return a string containing a traceback message for the given exc_info tuple (as returned by sys.exc_info()). )file)r$ tracebackprint_exceptiongetvalue)exc_infoexcoutexc_typeexc_valexc_tbs r/_exception_tracebackrxsC ZZF (Hgv hfEEEE ??  r0ceZdZdZddZdS) _SpoofOutcftj|}|r|ds|dz }|SN )r$rrendswith)selfresults r/rrz_SpoofOut.getvalues="4((  &//$//  dNF r0NcX||tj|dSN)seekr$truncate)rsizes r/rz_SpoofOut.truncate s( $$r0r)r? __module__ __qualname__rrrr0r/rzrzs7      r0rzct|vr||kS|t}dt|}}|d}|r*||rt|}|d=ndS|d}|r-||r|t|z}|d=ndS||krdS|D]4}||||}|dkrdS|t|z }5dS)z_ Essentially the only subtle case: >>> _ellipsis_match('aa...aa', 'aaa') False r#FT)ELLIPSIS_MARKERsplitr, startswithr~find)wantgotwsstartposendposws r/_ellipsis_matchrs d""s{ O $ $B#c((fH 1A >>!   1vvH15 2A <<??  c!ff F25&u 88Ax00 a<<55CFF 4r0c<|}|rd|zSdS)z)Return a commented form of the given linez# #)rstrip)lines r/ _comment_liner@s& ;;==D Dysr0cdt|}}|d}|dkr|}|dd|}|dkr|}|dd|}|dkr|dz}|||S)Nr#r}:.r))r,rrfind)msgstartendis r/_strip_exception_detailsrHsCHH3E AAvv aAAvv #q#AAvv! ucz?r0c,eZdZdZdZddZdZdZdS)_OutputRedirectingPdbz A specialized version of the python debugger that redirects stdout to a given stream when interacting with the user. Stdout is *not* redirected when traced code is executed. ct||_d|_tj||dd|_dS)NFT)stdoutnosigintr))_OutputRedirectingPdb__out$_OutputRedirectingPdb__debugger_usedpdbPdb__init__ use_rawinput)routs r/rz_OutputRedirectingPdb.__init__hs< $ cD999r0Ncd|_|tjj}tj||dSrP)rrGrIf_backrr set_trace)rframes r/rz_OutputRedirectingPdb.set_traceps;# =MOO*E $&&&&&r0cV|jr!tj|dSdSr)rrr set_continuers r/rz"_OutputRedirectingPdb.set_continuevs5   ' G  & & & & & ' 'r0ctj}|jt_ tjj|g|R|t_S#|t_wxYwr)rGrrrrtrace_dispatch)rargs save_stdouts r/rz$_OutputRedirectingPdb.trace_dispatch|sKj Z  %7)$6666$CJJCJ $ $ $ $s AAr)r?rr__doc__rrrrrr0r/rrbs_ '''' ''' %%%%%r0rctj|std|z|drt dt jj|d}t|dr+t j|j d}n|j dkrvttjdkrLtjddkr6t jtjdd}nt j}ntt|drM|jD]E}t j||}t j|r|cSFt d |j zt j||S) NzExpected a module: %r/z1Module-relative files may not have absolute paths__file__r#__main____path__zBCan't resolve paths relative to the module %r (it has no __file__))r@rArKr ValueErrorospathjoinrr]rr?r,rGargvcurdirrexists)rL test_pathbasedir directoryfullpaths r/rYrYs  F # #:/&8999C  NLMMM ys335Ivz"",'--003 J & & sx==??sx{b00gmmCHQK003GGiGG 6: & & $#_ $ $ 7<< 9==7>>(++$#OOO$3!?+,, , 7<< + ++r0c*eZdZdZ ddZdZdZdS)ran A single doctest example, consisting of source code and expected output. `Example` defines the following attributes: - source: A single Python statement, always ending with a newline. The constructor adds a newline if needed. - want: The expected output from running the source code (either from stdout, or a traceback in case of exception). `want` ends with a newline unless it's empty, in which case it's an empty string. The constructor adds a newline if needed. - exc_msg: The exception message generated by the example, if the example is expected to generate an exception; or `None` if it is not expected to generate an exception. This exception message is compared against the return value of `traceback.format_exception_only()`. `exc_msg` ends with a newline unless it's `None`. The constructor adds a newline if needed. - lineno: The line number within the DocTest string containing this Example where the Example begins. This line number is zero-based, with respect to the beginning of the DocTest. - indent: The example's indentation in the DocTest string. I.e., the number of space characters that precede the example's first prompt. - options: A dictionary mapping from option flags to True or False, which is used to override default options for this example. Any option flags not contained in this dictionary are left at their default value (as specified by the DocTestRunner's optionflags). By default, no options are set. Nr#c|ds|dz }|r|ds|dz }||ds|dz }||_||_||_||_|i}||_||_dSr|)r~sourcerlinenorloptionsexc_msg)rrrrrrlrs r/rzExample.__init__st$$  dNF   d++  DLD  w'7'7'='=  tOG    ?bG  r0c t|t|urtS|j|jkoO|j|jko?|j|jko/|j|jko|j|jko|j|jkSr)typeNotImplementedrrrrlrrrothers r/__eq__zExample.__eq__s ::T%[[ ( (! !{el*-yEJ&-{el*-{el*-|u}, - |u},  -r0c\t|j|j|j|j|jfSr)hashrrrrlrrs r/__hash__zExample.__hash__s.T[$)T[$+\#$$ $r0)Nr#r#N)r?rrrrrrrr0r/rrs[!!DEF$ - - -$$$$$r0rc0eZdZdZdZdZdZdZdZdS)rae A collection of doctest examples that should be run in a single namespace. Each `DocTest` defines the following attributes: - examples: the list of examples. - globs: The namespace (aka globals) that the examples should be run in. - name: A name identifying the DocTest (typically, the name of the object whose docstring this DocTest was extracted from). - filename: The name of the file that this DocTest was extracted from, or `None` if the filename is unknown. - lineno: The line number within filename where this DocTest begins, or `None` if the line number is unavailable. This line number is zero-based, with respect to the beginning of the file. - docstring: The string that the examples were extracted from, or `None` if the string is unavailable. c~||_||_||_||_||_||_dS)z Create a new DocTest containing the given examples. The DocTest's globals are initialized with a copy of `globs`. N)examples docstringcopyr7r.r`r)rrr7r.r`rrs r/rzDocTest.__init__s:! "ZZ\\     r0c t|jdkrd}n2t|jdkrd}ndt|jz}d|jjd|jd|jd |jd |d S) Nr#z no examplesr)z 1 examplez %d examples)r,r __class__r?r.r`r)rrs r/__repr__zDocTest.__repr__s t}   " "$HH   1 $ $"HH$s4='9'99H(((DMMM4;;;B Cr0c t|t|urtS|j|jkoO|j|jko?|j|jko/|j|jko|j|jko|j|jkSr)rrrrr7r.r`rrs r/rzDocTest.__eq__*s ::T%[[ ( (! !}.+~0+zU[(+yEJ&+}. + {el*  +r0cPt|j|j|j|jfSr)rrr.r`rrs r/rzDocTest.__hash__5s!T^TY t{KLLLr0ct|tstS|j|jnd}|j|jnd}|j|j|t |f|j|j|t |fkS)Nr)rBrrrr.r`id)rrself_lno other_lnos r/__lt__zDocTest.__lt__9sv%)) "! !"&+"94;;r$)L$U^Y5 BC Dr0N) r?rrrrrrrrrr0r/rrst.    C C C + + +MMMDDDDDr0rcPeZdZdZejdejejzZejdejejzej zZ ejdj Z ddZ dZddZd Zejd ejZd Zejd ejZd ZdZdZdS)rzD A class used to parse strings containing doctest examples. a # Source consists of a PS1 line followed by zero or more PS2 lines. (?P (?:^(?P [ ]*) >>> .*) # PS1 line (?:\n [ ]* \.\.\. .*)*) # PS2 lines \n? # Want consists of any non-blank lines that do not start with PS1. (?P (?:(?![ ]*$) # Not a blank line (?![ ]*>>>) # Not a line starting with PS1 .+$\n? # But any other line )*) a # Grab the traceback header. Different versions of Python have # said different things on the first traceback line. ^(?P Traceback\ \( (?: most\ recent\ call\ last | innermost\ last ) \) : ) \s* $ # toss trailing whitespace on the header. (?P .*?) # don't blink: absorb stuff until... ^ (?P \w+ .*) # a line *starts* with alphanum. z ^[ ]*(#.*)?$c |}|| dkr4d fd|dD}g}d\}}|j|D],}||||||d||z }| |||\}}} } | |sK|t|| | | t| dz|||d||z }|}.|||d|S)a= Divide the given string into examples and intervening text, and return them as a list of alternating Examples and strings. Line numbers for the Examples are 0-based. The optional argument `name` is a name identifying this string, and is only used for error messages. r#r}c$g|] }|d Srr).0l min_indents r/ z'DocTestParser.parse..s!KKK1*++KKKr0r#r#rl)rrlrN) expandtabs _min_indentrr _EXAMPLE_REfinditerappendrcount_parse_example_IS_BLANK_OR_COMMENTrr,groupr) rstringr.outputcharnormrrrrrs @r/parsezDocTestParser.parsevs""$$%%f-- >>YYKKKK T8J8JKKKLLF!**622  A MM& !12 3 3 3 fll4;; ;F((D&99 -VWdG,,V44 7 wvtW+1+5c!''(:K:K6L6L+L,3 5 5 5777 fll4AEEGG<< .s6+++aa))++++r0)r)rrr.s r/rzDocTestParser.get_exampless0++4::fd33+++ +r0c F t|d |dd}|| ||||ddd zdz||d fd|D}|d }|d}t|dkrt jd |d r|d =||d z||t|zd fd |D}|j|}|r|d }nd}| |||} || ||fS)a Given a regular expression match from `_EXAMPLE_RE` (`m`), return a pair `(source, want)`, where `source` is the matched example's source code (with prompts and indentation stripped); and `want` is the example's expected output (with indentation stripped). `name` is the string's name, and `lineno` is the line number where the example starts; both are used for error messages. rlrr}r)Nrhrc*g|]}|dzdS)rfNr)rslrls r/rz0DocTestParser._parse_example..s%AAAbBvaxyyMAAAr0rz *$rc$g|] }|d Srr)rwlrls r/rz0DocTestParser._parse_example..s!;;;""VWW+;;;r0r) r,rr_check_prompt_blank _check_prefixrrimatch _EXCEPTION_RE _find_options) rrr.r source_linesrr want_linesrrrls @r/rzDocTestParser._parse_examplesQWWX&&''wwx((..t44    vtVDDD <+SZ#-=tVLLLAAAALAAABB wwvZZ%% z??Q  28FJrN#C#C 2 :s6z4!C $5$55 7 7 7yy;;;; ;;;<<   $ $T * *  ggennGGG$$VT6::wg--r0z#\s*doctest:\s*([^\n\'"]*)$c i}|j|D]}|ddd}|D]\}|ddvs|ddt vrt d|dzd|d |t |dd}|dd k||<]|r-||rt d|d|d ||S) a Return a dictionary containing option overrides extracted from option directives in the given source string. `name` is the string's name, and `lineno` is the line number where the example starts; both are used for error messages. r),rhr#z+-Nline z of the doctest for z has an invalid option: +z4 has an option directive on a line with no example: )_OPTION_DIRECTIVE_RErrreplacerr*rr) rrr.rrroption_stringsoptionflags r/rzDocTestParser._find_optionss1*33F;; 3 3AWWQZZ//S99??AAN( 3 31IT))122J&999$*&,Qhhhff&>???+6!"":6!'c!1  3  5t0088 5*$ffdddFF455 5r0z ^([ ]*)(?=\S)cd|j|D}t|dkrt|SdS)z;Return the minimum indentation of any non-blank line in `s`c,g|]}t|Sr)r,)rrls r/rz-DocTestParser._min_indent.. sHHH63v;;HHHr0r#) _INDENT_REfindallr,min)rrkindentss r/rzDocTestParser._min_indent sGHHT_-D-DQ-G-GHHH w<)> j"((1***ddd"&vfQh"7"7"7"?@@@ @ @r0c t|D]:\}}|r3||std||zdzd|d|;dS)z Check that every line in the given list starts with the given prefix; if any line does not, then raise a ValueError. rr)r&z& has inconsistent leading whitespace: N)r'rr)rr(prefixr.rrrs r/rzDocTestParser._check_prefix!sw !'' ; ;GAt ;DOOF33 ; j"((1***dddDD":;;; ; ;r0N)r)r?rrrricompile MULTILINEVERBOSErDOTALLrrrrrrrrrr!rrrrr0r/rrFsI"*  \BJ & ( (K,BJ Z", & 2 4 4M&2:o66<%%%%N 7 7 7 + + + +*.*.*.f&2:&D&(l448,bl;;J @ @ @ ; ; ; ; ;r0rcXeZdZdZdeddfdZd dZdZdZd Z d Z d Z dS) ra< A class used to extract the DocTests that are relevant to a given object, from its docstring and the docstrings of its contained objects. Doctests can currently be extracted from the following object types: modules, functions, classes, methods, staticmethods, classmethods, and properties. FTc>||_||_||_||_dS)at Create a new doctest finder. The optional argument `parser` specifies a class or function that should be used to create new DocTest objects (or objects that implement the same interface as DocTest). The signature for this factory function should match the signature of the DocTest constructor. If the optional argument `recurse` is false, then `find` will only examine the given object, and not any contained objects. If the optional argument `exclude_empty` is false, then `find` will include tests for objects with empty docstrings. N)_parser_verbose_recurse_exclude_empty)rverboseparserrecurse exclude_emptys r/rzDocTestFinder.__init__:s'"   +r0Nc |2t|dd}|tdt||durd}n|tj|} tj|}|s-tj|}|d|ddzdksd}|d}nH|tj||j }ntj|}|sd}n#t$rd}YnwxYw||i}n.|j }n| }|| |d|vrd|d<g}| ||||||i||S) aj Return a list of the DocTests that are defined by the given object's docstring, or by any of its contained objects' docstrings. The optional parameter `module` is the module that contains the given object. If the module is not specified or is None, then the test finder will attempt to automatically determine the correct module. The object's module is used: - As a default namespace, if `globs` is not specified. - To prevent the DocTestFinder from extracting DocTests from objects that are imported from other modules. - To find the name of the file containing the object. - To help find the line number of the object within its file. Contained objects whose module does not match `module` are ignored. If `module` is False, no attempt to find the module will be made. This is obscure, of use mostly in tests: if `module` is False, or is None but cannot be found automatically, then all objects are considered to belong to the (non-existent) module, so all contained objects will (recursively) be searched for doctests. The globals for each DocTest is formed by combining `globs` and `extraglobs` (bindings in `extraglobs` override bindings in `globs`). A new copy of the globals dictionary is created for each DocTest. If `globs` is not specified, then it defaults to the module's `__dict__`, if specified, or {} otherwise. If `extraglobs` is not specified, then it defaults to {}. Nr?zHDocTestFinder.find: name must be given when obj.__name__ doesn't exist: Fr#z<]>r)r5rrr@ getmodule getsourcefilegetfile linecachegetlines__dict__rKrupdate_findsort) robjr.rLr7 extraglobsrortestss r/rzDocTestFinder.findPsH <3 D11D| j"&s)))"./// U??FF ^&s++F  ((--D ?s++AwtBCCy(E11$4|# %$-#5dFO#L#LLL$-#5d#;#;L#(#'L+   LLL 0 =~,,..JJLLE  ! LL $ $ $ U " " *E*  5#tV\5"EEE   sC C C cJ|dStj||tj|uStj|r|j|juStj|stj|rBt|dr |jj }nt|dr|j }ndS|j |kStj |r|j |j kSt|dr|j |j kSt|trdStd)zY Return true if the given object is defined in the given module. NT __objclass__rz"object must be a class or function)r@r; isfunctionr@ __globals__ismethoddescriptorismethodwrapperr]rHrr?isclassrBpropertyr)rrLobjectobj_mods r/ _from_modulezDocTestFinder._from_modules; >4  v & & 2W.v666 6   ' ' C?f&88 8(00 C%f-- Cv~..  -8..  +t?g- - _V $ $ C?f&77 7 V\ * * C?f&77 7  ) ) C4ABB Br0cz|} tj|}n#t$rYnwxYwtj|S)zL Safely unwrap objects and determine if they are functions. )r@unwrapr isroutine)rrD maybe_routines r/ _is_routinezDocTestFinder._is_routinesP  #N=99MM    D  ///s  &&c |jrtd|zt||vrdSd|t|<||||||}|||t j|r|jr|j D]f\} } |d| } | | st j | r1| || r| || | ||||gt j|r|jrt|di D]\} } t| t st#dt%| t j| s\t j | sHt j| s4t| t st#dt%| |d| } | || | ||||t j |r|jr|j D]\} } t| t(t*fr| j} t j| s)t j | st| t.r8| || r"|d| } | || | ||||dSdSdS) zm Find tests for the given object and any contained objects, and add them to `tests`. zFinding tests in %sNr)r__test__z3DocTestFinder.find: __test__ keys must be strings: z^DocTestFinder.find: __test__ values must be strings, functions, methods, classes, or modules: z .__test__.)r2printr _get_testrr@rAr3r@itemsrVrMrQrBr5rBrCrrrT staticmethod classmethod__func__rN) rrFrDr.rLrr7seentestvalnamevals r/rBzDocTestFinder._finds^ = 0 '$. / / / c77d?? FRWW ~~c4 EE   LL     C  ,T] , # 2 2 4 4 , , %)TT773%%c**,goc.B.B,%%fc22,JJuc7FL$d,,,  C  (T] ( 'Z < < B B D D ( ( !'3//7$*&*7mmm&6777 )#..3'/#2F2F3(--31;C1E1E3$*'+3iii&2333/3ddGG< 5#w  $(((( ?3   ,DM , # 2 2 4 4 , , cL+#>??',C&s++,ws/C/C, h//,''44,*.ww7GJJuc7FL$d,,, , , , , , ,r0ct|tr|}nP |jd}n+|j}t|tst|}n#ttf$rd}YnwxYw|||}|jr|sdS|d}n0t|ddp|j}|dddkr |dd}|j |||||S)zs Return a DocTest for the given object, if it defines a docstring; otherwise, return None. Nrr.pycr) rBrCrrKr\ _find_linenor4r5r?r1r) rrDr.rLr7rrrr`s r/rZzDocTestFinder._get_tests c3   II ;& "II # I%i553$' NN ~.     ""3 55   y 4 >HHvz488KFOH}&&#CRC=|'' 5$(0&:: :s5AA&%A&c d}t|dd}tj|r|d}tj|rl|j|dSt jdt jt|ddz}t|D]\}}||r|}ntj |r|j }t|tr|j }tj|r*t|ddrtj|j}tj|r|j}tj|r|j}tj|r |jdz }|Z||dzSt jd}t/|t1|D]!}|||r|cS"dS) z Return a line number of the given object's docstring. Returns `None` if the given object does not have a docstring. Nrr#z^\s*class\s*%s\br?-r)z(^|.*:)\s*\w*("|\'))r5r@rArMrir+escaper'rismethodr^rBrNfgetrIrS__code__ istracebacktb_frameisframef_codeiscodeco_firstlinenoranger,)rrDrrrpatrrs r/rfzDocTestFinder._find_linenoAs CD11   C  Y%:F ?3   I$9#t*0YwsJ'D'DEEFGGC$\22  499T??FE  C 4 # c8 $ $ (C  c " " /wsIt'D'D /.%%.C  s # #73#   ,'!+F  #ax*344CL(9(9:: " "99\&122"!MMM"tr0NNNN) r?rrrrrrrQrVrBrZrfrr0r/rr1s %]]__T,,,,,ddddLCCC: 0 0 0;,;,;,z$:$:$:L44444r0rceZdZdZdZddZdZdZdZd Z d Z d Z d Z e jd ZddZddZddZdZdS)ra3 A class used to run DocTest test cases, and accumulate statistics. The `run` method is used to process a single DocTest case. It returns a tuple `(f, t)`, where `t` is the number of test cases tried, and `f` is the number of test cases that failed. >>> tests = DocTestFinder().find(_TestClass) >>> runner = DocTestRunner(verbose=False) >>> tests.sort(key = lambda test: test.name) >>> for test in tests: ... print(test.name, '->', runner.run(test)) _TestClass -> TestResults(failed=0, attempted=2) _TestClass.__init__ -> TestResults(failed=0, attempted=2) _TestClass.get -> TestResults(failed=0, attempted=2) _TestClass.square -> TestResults(failed=0, attempted=1) The `summarize` method prints a summary of all the test cases that have been run by the runner, and returns an aggregated `(f, t)` tuple: >>> runner.summarize(verbose=1) 4 items passed all tests: 2 tests in _TestClass 2 tests in _TestClass.__init__ 2 tests in _TestClass.get 1 tests in _TestClass.square 7 tests in 4 items. 7 passed and 0 failed. Test passed. TestResults(failed=0, attempted=7) The aggregated number of tried examples and failed examples is also available via the `tries` and `failures` attributes: >>> runner.tries 7 >>> runner.failures 0 The comparison between expected outputs and actual outputs is done by an `OutputChecker`. This comparison may be customized with a number of option flags; see the documentation for `testmod` for more information. If the option flags are insufficient, then the comparison may also be customized by passing a subclass of `OutputChecker` to the constructor. The test runner's display output can be controlled in two ways. First, an output function (`out) can be passed to `TestRunner.run`; this function will be called with strings that should be displayed. It defaults to `sys.stdout.write`. If capturing the output is not sufficient, then the display output can be also customized by subclassing DocTestRunner, and overriding the methods `report_start`, `report_success`, `report_unexpected_exception`, and `report_failure`. zF**********************************************************************Nr#c|p t|_|dtjv}||_||_||_d|_d|_i|_ t|_ dS)ac Create a new test runner. Optional keyword arg `checker` is the `OutputChecker` that should be used to compare the expected outputs and actual outputs of doctest examples. Optional keyword arg 'verbose' prints lots of stuff if true, only failures if false; by default, it's true iff '-v' is in sys.argv. Optional argument `optionflags` can be used to control how the test runner compares expected output to actual output, and how it displays failures. See the documentation for `testmod` for more information. N-vr#) r_checkerrGrr2 optionflagsoriginal_optionflagstriesfailures_name2ftrz_fakeout)rcheckerr5rzs r/rzDocTestRunner.__init__sd" 2=?? ?ch&G &$/!   "  r0c|jrf|jr:|dt|jzdzt|jzdS|dt|jzdzdSdS)z Report that the test runner is about to process the given example. (Only displays a message if verbose=True) zTrying: z Expecting: zExpecting nothing N)r2rrmr)rrr`examples r/ report_startzDocTestRunner.report_starts = +| +K''."9"99"#%,W\%:%:;<<<<<K''."9"99)*+++++  + +r0c.|jr |ddSdS)zt Report that the given example ran successfully. (Only displays a message if verbose=True) zok N)r2rrr`rrs r/report_successzDocTestRunner.report_successs) =  CKKKKK  r0c|||||j|||jzdS)z7 Report that the given example failed. N)_failure_headerryoutput_differencerzrs r/report_failurezDocTestRunner.report_failuresY D w / / M + +GS$:J K K L M M M M Mr0c||||dztt|zdS)zO Report that the given example raised an unexpected exception. zException raised: N)rrmrxrrr`rrss r/report_unexpected_exceptionz)DocTestRunner.report_unexpected_exceptions[ D w / / ! "$+,@,J,J$K$K L M M M M Mr0c|jg}|jrL|j|j|j|jzdz}nd}|d|jd|d|jn(|d|jdzd|j|d|j}|t |d|S) Nr)?zFile "", line , in zLine zFailed example:r})DIVIDERr`rrr.rrmr)rr`rrrrs r/rzDocTestRunner._failure_headers|n = I{&7>+Ew~59 JJJ vvvtyy: ; ; ; ; JJJ7>!+;+;+;TYYG H H H $%%% 76??###yy~~r0c  dx}}|j}td\}}} |jj} t |jD]\} } |jt zo|dk} ||_| jrC| jD])\}}|r|xj|zc_|xj|zc_*|jtzr||dz }| s| ||| d|j | fz} tt| j|d|d|j|jd}n=#t$$rt'j}|jYnxYw|j}|jd|}|| | j||jr|}n t3j|dd}t7|dt8r`|djd |djd |djd ft?fd t |D}||d}d |}| s|tC|z }| j"| }n\| | j"||jr|}nB|jtFzr3| tI| j"tI||jr|}||ur| s|%||| |nG||ur | s|&||| ||dz }n#|| ur| s|'||| ||dz }|r|jtPzrn||_|)|||tU||S) a Run the examples in `test`. Write the outcome of each example with one of the `DocTestRunner.report_*` methods, using the writer function `out`. `compileflags` is the set of compiler flags that should be used to execute examples. Return a tuple `(f, t)`, where `t` is the number of examples tried, and `f` is the number of examples that failed. The examples are run in the namespace `test.globs`. r#rUr)zsingleTNr<rrc3LK|]\}}||VdSr)r)rindexrexception_line_prefixess r/ z&DocTestRunner.__run..ksN))'E4??+BCC)))))))r0r)+rzrsry check_outputr'rr rr[rrr.execr+rr7debuggerrKeyboardInterruptrGrsrrrrrrpformat_exception_only issubclass SyntaxErrorrrnextrrxrrrrrrr_DocTestRunner__record_outcomer')rr` compileflagsrr}r|r{SUCCESSFAILUREBOOMcheck examplenumrquiet optionflagrbr` exceptionroutcome formatted_ex exc_msg_indexrrs @r/__runzDocTestRunner.__runs5 $/!&q$ *$-T]#;#;o o  J%(AA"\  4D  8)0)>)>)@)@88%Z8((J6(((((ZK7((($&  QJE 6!!#tW555 *TY ,CCH -WW^Xx)41126*>>> **,,, $    -LNN  **,,,,,-((**C M " "1 % % %G 5sD,<==&%G )> "1" N ilK88@ %Q<4777$Q<2QQYq\5NQQQ/+%)))))+4\+B+B)))%%M $0 #?L'',//;/ :::C?*"GGU7?GT5EFF*%GG%(??*u5goFF5g>>!-//*#*'!!A''T7C@@@G##A''T7C@@@A D@44S$5>@@@A  D,y8 0 dHe4448U+++s 'AD..8E(c|j|jd\}}||z||zf|j|j<|xj|z c_|xj|z c_dS)z{ Record the fact that the given DocTest (`test`) generated `f` failures out of `t` tried examples. rN)r~r4r.r}r|)rr`rdtf2t2s r/__record_outcomezDocTestRunner.__record_outcomes^ ""49e44B$%bD!B$< di    a r0z..+)\[(?P\d+)\]>$cF|j|}|rp|d|jjkrM|jjt |d}|jdS| ||S)Nr.rTkeepends) %_DocTestRunner__LINECACHE_FILENAME_RErrr`r.rintr splitlinessave_linecache_getlines)rr`module_globalsrrs r/__patched_linecache_getlinesz*DocTestRunner.__patched_linecache_getliness  ( . .x 8 8  JDIN22i(QWW\-B-B)C)CDG>,,d,;; ;//.II Ir0Tc  ||_|t|j}tj |/ j  dkr j}n fd}|jt_tj }tj }t |_ |j |j j t_ tj|_|jt_tj}tjt_ |||| t_|t_ tj||jt_|t_|r%|jddl}d|_SS# t_|t_ tj||jt_|t_|r$|jddl}d|_wxYw)aJ Run the examples in `test`, and display the results using the writer function `out`. The examples are run in the namespace `test.globs`. If `clear_globs` is true (the default), then this namespace will be cleared after the test runs, to help with garbage collection. If you would like to examine the namespace after the test completes, then use `clear_globs=False`. `compileflags` gives the set of flags that should be used by the Python compiler when running the examples. If not specified, then it will default to the set of future-import flags that apply to `globs`. The output of each example is checked using `DocTestRunner.check_output`, and the results are formatted by the `DocTestRunner.report_*` methods. Nutf-8czt|d}|dS)Nbackslashreplace)rCencodewrite)rkrXrs r/rzDocTestRunner.run..outs;AHHX/ABBHMMA%%a(((((r0r#)r`r;r7rGrrXlowerrrgettracerrrrresetr>r?r*_DocTestRunner__patched_linecache_getlines displayhook__displayhook___DocTestRunner__runsettraceclearbuiltins_) rr`rr clear_globs save_tracesave_set_tracesave_displayhookrrXrs @@r/runzDocTestRunner.runs(  0<>#3#3w#>#>!'))))))] \^^ -k::   / (1'9$!> ?- "::dL#66$CJ*CM L $ $ $!%!=I .CO "   """!  " %CJ*CM L $ $ $!%!=I .CO "   """! !!!!s FA1H c||j}g}g}g}dx}}|jD]c}|\}\} } || z }|| z }| dkr||0| dkr||| fN||d|r|rFt t |d||D]} t d| |rMt t |d||D]\} } t d| | fz|ret |jt t |d||D]\} \} } t d| | | fz|r9t |d t |jd t ||z d |d |rt d |dn|rt dt||S)a Print a summary of all the test cases that have been run by this DocTestRunner, and return a tuple `(f, t)`, where `f` is the total number of failed examples, and `t` is the total number of tried examples. The optional `verbose` argument controls how detailed the summary is. If the verbosity is not specified, then the DocTestRunner's verbosity is used. Nr#zitems had no tests:z zitems passed all tests:z %3d tests in %szitems had failures:z %3d of %3d in %sztests inzitems.z passed andzfailed.z***Test Failed***z failures.z Test passed.) r2r~r[rrYr,rCrr') rr5notestspassedfailedtotalttotalfr r.rdrthingrs r/ summarizezDocTestRunner.summarizes] ?mG$$&& ! !ALD&1a aKF aKFAvvt$$$$a ay**** a     ? (c'll$9::: $((E%'''' ?c&kk#<=== $*??LE5,u~=>>>>  ; $,    #f++4 5 5 5 KKMMM!' ; ; v1)Q5M9::::  D &*c$-&8&8( C C C &6/< C C C  " %v{ ; ; ; ;  " . ! ! !66***r0c|j}|jD](\}\}}||vr||\}}||z}||z}||f||<)dSr)r~r[)rrdr.rdrrrs r/mergezDocTestRunner.merge7sq M!N0022  LD&1aqyy 4BFFdAdGG  r0)NNr#rNNT)r?rrrrrrrrrrrrrir+rrrrrrr0r/rr{s!66rG$$$$H + + +MMMMMM(L,L,L,\)bj*FGGJJJJD"D"D"D"R4+4+4+4+r     r0rc*eZdZdZdZdZdZdZdS)ra_ A class used to check the whether the actual output from a doctest example matches the expected output. `OutputChecker` defines two methods: `check_output`, which compares a given pair of outputs, and returns true if they match; and `output_difference`, which returns a string describing the differences between two outputs. cJt|dddS)z= Convert string to hex-escaped ASCII string. ASCIIr)rCr)rrks r/_toAsciizOutputChecker._toAsciiLs#188G%788'BBBr0cN||}||}||krdS|tzs||fdkrdS||fdkrdS|tzsNtjdtjt zd|}tjdd|}||krdS|tzrVd| }d| }||krdS|tzrt||rdSdS) a Return True iff the actual output from an example (`got`) matches the expected output (`want`). These strings are always considered to match if they are identical; but depending on what option flags the test runner is using, several non-exact match types are also possible. See the documentation for `TestRunner` for more information about option flags. T)zTrue z1 )zFalse z0 z (?m)^%s\s*?$rz(?m)^[^\S\n]+$rhF) rrrrirjriBLANKLINE_MARKERrrrrrrrrrzs r/rzOutputChecker.check_outputRsI mmC  }}T"" $;;444 Dz...tDz///t33 6/BI6F,G,GGd$$D&*B44Cd{{t - - ((399;;''C88DJJLL))Dd{{t  ! tS)) tur0c|ttztzzsdS|tzrdS|ddko|ddkS)NFTr}r<)r r r rrs r/_do_a_fancy_diffzOutputChecker._do_a_fancy_diffsil*+*+, 5  % 4zz$!#; $!(;;r0cZ|j}|tzstjdt|}||||r|d}|d}|tzr1tj ||d}t|dd}d}n|tzr1tj ||d}t|dd}d}nN|tzrDtjtj } t| ||}d }d |zt#d |zS|r$|r"d t#|dt#|S|rdt#|zS|rdt#|zSdS)z Return a string describing the differences between the expected output for a given example (`example`) and the actual output (`got`). `optionflags` is the set of option flags used to compare `want` and `got`. z(?m)^[ ]*(?= )Trr<)nNz#unified diff with -expected +actualz-context diff with expected followed by actual)charjunkzndiff with -expected +actualzDifferences (%s): rz Expected: zGot: zExpected: %sGot nothing zExpected nothing Got: %szExpected nothing Got nothing )rrrirjrrrr difflib unified_difflistr context_diffr DifferIS_CHARACTER_JUNKcomparermr) rrrrzrr got_linesdiffkindengines r/rzOutputChecker.output_differences|33 C&*, >44r0N)r?rrrrrrrrr0r/rrDs^CCC <<<~<<<.,5,5,5,5,5r0rceZdZdZdZdZdS)rzA DocTest example has failed in debugging mode. The exception instance has variables: - test: the DocTest object being run - example: the Example object that failed - got: the actual output c0||_||_||_dSr)r`rr)rr`rrs r/rzDocTestFailure.__init__s  r0c*t|jSrrCr`rs r/__str__zDocTestFailure.__str__49~~r0Nr?rrrrrrr0r/rrs<   r0rceZdZdZdZdZdS)rzA DocTest example has encountered an unexpected exception The exception instance has variables: - test: the DocTest object being run - example: the Example object that failed - exc_info: the exception info c0||_||_||_dSr)r`rrs)rr`rrss r/rzUnexpectedException.__init__s    r0c*t|jSrrrs r/rzUnexpectedException.__str__rr0Nrrr0r/rrs<  !!! r0rc&eZdZdZddZdZdZdS)ra Run doc tests but raise an exception as soon as there is a failure. If an unexpected exception occurs, an UnexpectedException is raised. It contains the test, the example, and the original exception: >>> runner = DebugRunner(verbose=False) >>> test = DocTestParser().get_doctest('>>> raise KeyError\n42', ... {}, 'foo', 'foo.py', 0) >>> try: ... runner.run(test) ... except UnexpectedException as f: ... failure = f >>> failure.test is test True >>> failure.example.want '42\n' >>> exc_info = failure.exc_info >>> raise exc_info[1] # Already has the traceback Traceback (most recent call last): ... KeyError We wrap the original exception to give the calling application access to the test and example information. If the output doesn't match, then a DocTestFailure is raised: >>> test = DocTestParser().get_doctest(''' ... >>> x = 1 ... >>> x ... 2 ... ''', {}, 'foo', 'foo.py', 0) >>> try: ... runner.run(test) ... except DocTestFailure as f: ... failure = f DocTestFailure objects provide access to the test: >>> failure.test is test True As well as to the example: >>> failure.example.want '2\n' and the actual output: >>> failure.got '1\n' If a failure or error occurs, the globals are left intact: >>> del test.globs['__builtins__'] >>> test.globs {'x': 1} >>> test = DocTestParser().get_doctest(''' ... >>> x = 2 ... >>> raise KeyError ... ''', {}, 'foo', 'foo.py', 0) >>> runner.run(test) Traceback (most recent call last): ... doctest.UnexpectedException: >>> del test.globs['__builtins__'] >>> test.globs {'x': 2} But the globals are cleared if there is no error: >>> test = DocTestParser().get_doctest(''' ... >>> x = 2 ... ''', {}, 'foo', 'foo.py', 0) >>> runner.run(test) TestResults(failed=0, attempted=1) >>> test.globs {} NTcxt||||d}|r|j|S)NF)rrr7r)rr`rrrrs r/rzDebugRunner.runWs>   dD,U C C   J     r0c$t|||r)rrs r/rz'DebugRunner.report_unexpected_exception]s!$:::r0c$t|||r)rrs r/rzDebugRunner.report_failure`sT7C000r0r)r?rrrrrrrr0r/rrsSX X t ;;;11111r0rTFc |tjd}tj|st d|||j}t|} |rt||} nt||} | ||||D]} | | |r| t| a nt| t| j| jS)a* m=None, name=None, globs=None, verbose=None, report=True, optionflags=0, extraglobs=None, raise_on_error=False, exclude_empty=False Test examples in docstrings in functions and classes reachable from module m (or the current module if m is not supplied), starting with m.__doc__. Also test examples reachable from dict m.__test__ if it exists and is not None. m.__test__ maps names to functions, classes and strings; function and class docstrings are tested even if the name is private; strings are tested directly, as if they were docstrings. Return (#failures, #tests). See help(doctest) for an overview. Optional keyword arg "name" gives the name of the module; by default use m.__name__. Optional keyword arg "globs" gives a dict to be used as the globals when executing examples; by default, use m.__dict__. A copy of this dict is actually used for each docstring, so that each docstring's examples start with a clean slate. Optional keyword arg "extraglobs" gives a dictionary that should be merged into the globals that are used to execute examples. By default, no extra globals are used. This is new in 2.4. Optional keyword arg "verbose" prints lots of stuff if true, prints only failures if false; by default, it's true iff "-v" is in sys.argv. Optional keyword arg "report" prints a summary at the end when true, else prints nothing at the end. In verbose mode, the summary is detailed, else very brief (in fact, empty if all tests passed). Optional keyword arg "optionflags" or's together module constants, and defaults to 0. This is new in 2.3. Possible values (see the docs for details): DONT_ACCEPT_TRUE_FOR_1 DONT_ACCEPT_BLANKLINE NORMALIZE_WHITESPACE ELLIPSIS SKIP IGNORE_EXCEPTION_DETAIL REPORT_UDIFF REPORT_CDIFF REPORT_NDIFF REPORT_ONLY_FIRST_FAILURE Optional keyword arg "raise_on_error" raises an exception on the first unexpected exception or failure. This allows failures to be post-mortem debugged. Advanced tomfoolery: testmod runs methods of a local instance of class doctest.Tester, then merges the results into (or creates) global Tester instance doctest.master. Methods of doctest.master can be called directly too, if you want to do something unusual. Passing report=0 to testmod is especially useful then, to delay displaying a summary. Invoke doctest.master.summarize(verbose) when you're done fiddling. Nrztestmod: module required; )r8r5rzr7rE)rGrHr4r@rArKr?rrrrrrmasterrr'r}r|) rr.r7r5reportrzrEraise_on_errorr8finderrunnerr`s r/rrlsJ y KOOJ ' '  A  ?i!!=>>> |z 7 7 7FIW+FFFwKHHH At5Z HH 4  ~ V v 5 55r0c X|r|stdt|||| pd\} }|tj|}|i}n|}|||d|vrd|d<| rt||} nt||} | | |||d}| ||r| t| a nt | t| j| jS)a Test examples in the given file. Return (#failures, #tests). Optional keyword arg "module_relative" specifies how filenames should be interpreted: - If "module_relative" is True (the default), then "filename" specifies a module-relative path. By default, this path is relative to the calling module's directory; but if the "package" argument is specified, then it is relative to that package. To ensure os-independence, "filename" should use "/" characters to separate path segments, and should not be an absolute path (i.e., it may not begin with "/"). - If "module_relative" is False, then "filename" specifies an os-specific path. The path may be absolute or relative (to the current working directory). Optional keyword arg "name" gives the name of the test; by default use the file's basename. Optional keyword argument "package" is a Python package or the name of a Python package whose directory should be used as the base directory for a module relative filename. If no package is specified, then the calling module's directory is used as the base directory for module relative filenames. It is an error to specify "package" if "module_relative" is False. Optional keyword arg "globs" gives a dict to be used as the globals when executing examples; by default, use {}. A copy of this dict is actually used for each docstring, so that each docstring's examples start with a clean slate. Optional keyword arg "extraglobs" gives a dictionary that should be merged into the globals that are used to execute examples. By default, no extra globals are used. Optional keyword arg "verbose" prints lots of stuff if true, prints only failures if false; by default, it's true iff "-v" is in sys.argv. Optional keyword arg "report" prints a summary at the end when true, else prints nothing at the end. In verbose mode, the summary is detailed, else very brief (in fact, empty if all tests passed). Optional keyword arg "optionflags" or's together module constants, and defaults to 0. Possible values (see the docs for details): DONT_ACCEPT_TRUE_FOR_1 DONT_ACCEPT_BLANKLINE NORMALIZE_WHITESPACE ELLIPSIS SKIP IGNORE_EXCEPTION_DETAIL REPORT_UDIFF REPORT_CDIFF REPORT_NDIFF REPORT_ONLY_FIRST_FAILURE Optional keyword arg "raise_on_error" raises an exception on the first unexpected exception or failure. This allows failures to be post-mortem debugged. Optional keyword arg "parser" specifies a DocTestParser (or subclass) that should be used to extract tests from the files. Optional keyword arg "encoding" specifies an encoding that should be used to convert the file to unicode. Advanced tomfoolery: testmod runs methods of a local instance of class doctest.Tester, then merges the results into (or creates) global Tester instance doctest.master. Methods of doctest.master can be called directly too, if you want to do something unusual. Passing report=0 to testmod is especially useful then, to delay displaying a summary. Invoke doctest.master.summarize(verbose) when you're done fiddling. 8Package may only be specified for module-relative paths.rNr?rrr#)rrerrbasenamerrArrrrrrrr'r}r|)r`rbr.rar7r5r rzrEr r6rXtextr r`s r/rrs\d,,+,, ,$Hg$,$799ND( |w)) }  Z   &jIW+FFFwKHHH   dE41 = =D JJt  ~ V v 5 55r0NoNamect|d}t||}||||D]}|||dS)ar Test examples in the given object's docstring (`f`), using `globs` as globals. Optional argument `name` is used in failure messages. If the optional argument `verbose` is true, then generate output even if there are no failures. `compileflags` gives the set of flags that should be used by the Python compiler when running the examples. If not specified, then it will default to the set of future-import flags that apply to `globs`. Optional keyword arg `optionflags` specifies options for the testing and output. See the documentation for `testmod` for more information. F)r5r7r)r7)rN)rrrr) rdr7r5r.rrzr r r`s r/rrOsl$7E : : :F 7 D D DF At5 1144 4l 333344r0cT|tz|krtd|t}|a|S)a?Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> import doctest >>> old = doctest._unittest_reportflags >>> doctest.set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> doctest._unittest_reportflags == (REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) True Only reporting flags can be set: >>> doctest.set_unittest_reportflags(ELLIPSIS) Traceback (most recent call last): ... ValueError: ('Only reporting flags allowed', 8) >>> doctest.set_unittest_reportflags(old) == (REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) True zOnly reporting flags allowed)rr_unittest_reportflags)r8olds r/rrls5: E))7??? C! Jr0cdeZdZ ddZdZdZdZdZdZd Z d Z d Z d Z e jZd ZdS) DocTestCaser#Nctj|||_||_||_||_||_dSr)unittestTestCaser_dt_optionflags _dt_checker_dt_test _dt_setUp _dt_tearDown)rr`rzsetUptearDownrs r/rzDocTestCase.__init__sG ""4(((*" $r0c|j}|j|_|j||dSdSr)rr7r _dt_globsrrr`s r/r zDocTestCase.setUpsD}** > % NN4  & %r0c|j}|j|||j|j|jdSr)rrr7rrAr#r$s r/r!zDocTestCase.tearDownsZ}   (   d # # #  $.)))))r0c|j}tj}t}|j}|t zs |t z}t||jd} d|_ | ||j d\}}|t_n#|t_wxYw|r:| | |dS)NFrzrr5zF----------------------------------------------------------------------)rr)rrGrr$rrrrrrrrfailureExceptionformat_failurerr)rr`rnewrzr r}r|s r/runTestzDocTestCase.runTests}jjj* o- 1 0 0K;'+'7HHH #FN$jj#))88OHeCJJCJ      M''(;(;CLLNN(K(KLL L M Ms 'B Bc |j}|jd}n d|jz}d|jddd}d|jd|jd|d|d | S) Nzunknown line numberz%srrFailed doctest test for File "rrz )rrrr.rr`)rerrr`rlnames r/r)zDocTestCase.format_failures|} ; *FFDK'F--bcc233999dmmmVVVUUUCCA r0c|t|j|jd}||jd|dS)aRun the test case without results and without catching exceptions The unit test framework includes a debug method on test cases and test suites to support post-mortem debugging. The test code is run in such a way that errors are not caught. This way a caller can catch the errors and initiate post-mortem debugging. The DocTestCase provides a debug method that raises UnexpectedException errors if there is an unexpected exception: >>> test = DocTestParser().get_doctest('>>> raise KeyError\n42', ... {}, 'foo', 'foo.py', 0) >>> case = DocTestCase(test) >>> try: ... case.debug() ... except UnexpectedException as f: ... failure = f The UnexpectedException contains the test, the example, and the original exception: >>> failure.test is test True >>> failure.example.want '42\n' >>> exc_info = failure.exc_info >>> raise exc_info[1] # Already has the traceback Traceback (most recent call last): ... KeyError If the output doesn't match, then a DocTestFailure is raised: >>> test = DocTestParser().get_doctest(''' ... >>> x = 1 ... >>> x ... 2 ... ''', {}, 'foo', 'foo.py', 0) >>> case = DocTestCase(test) >>> try: ... case.debug() ... except DocTestFailure as f: ... failure = f DocTestFailure objects provide access to the test: >>> failure.test is test True As well as to the example: >>> failure.example.want '2\n' and the actual output: >>> failure.got '1\n' Fr')rN)r rrrrrr!)rr s r/r"zDocTestCase.debugs_D )=%)%5uFFF 4=e 444 r0c|jjSrrr.rs r/rzDocTestCase.id s }!!r0ct|t|urtS|j|jko?|j|jko/|j|jko|j|jko|j|jkSr)rrrrrrrrs r/rzDocTestCase.__eq__ s~ ::T%[[ ( (! !}.5#u'<<5~05 E$6655#44  5r0cPt|j|j|j|jfSr)rrrrrrs r/rzDocTestCase.__hash__& s-T)4>4;L%'(( (r0c|jjd}|ddd|dddS)Nrrr))rr.rr)rr.s r/rzDocTestCase.__repr__* sG}!'',, HHHchhtCRCy&9&9&9&9::r0c d|jjzS)Nz Doctest: r3rs r/shortDescriptionzDocTestCase.shortDescription0 sT]///r0)r#NNN)r?rrrr r!r+r)r"rrrrrOrr9rr0r/rrsAE%%%%!!!***MMM0   FFFP"""555(((;;;nG00000r0rc*eZdZdZdZdZdZeZdS)SkipDocTestCasecJ||_t|ddSr)rLrr)rrLs r/rzSkipDocTestCase.__init__4 s% T4(((((r0c0|ddS)Nz-DocTestSuite will not work with -O2 and above)skipTestrs r/r zSkipDocTestCase.setUp8 s EFFFFFr0cdSrrrs r/ test_skipzSkipDocTestCase.test_skip;  r0c d|jjzS)NzSkipping tests from %s)rLr?rs r/r9z SkipDocTestCase.shortDescription> s'$+*>>>r0N)r?rrrr r@r9rrr0r/r;r;3 sT)))GGG   ???GGGr0r;ceZdZdZdS) _DocTestSuitecdSrr)rrs r/_removeTestAtIndexz _DocTestSuite._removeTestAtIndexF rAr0N)r?rrrFrr0r/rDrDD s#     r0rDc |t}t|}||||}|sGtjjdkr2t }|t||S| t }|D]h}t|j dkr|j s&|j }|dddkr |dd}||_ |t|fi|i|S)a Convert doctest tests for a module to a unittest test suite. This converts each documentation string in a module that contains doctest tests to a unittest test case. If any of the tests in a doc string fail, then the test case fails. An exception is raised showing the name of the file containing the test and a (sometimes approximate) line number. The `module` argument provides the module to be tested. The argument can be either a module or a module name. If no argument is given, the calling module is used. A number of options may be provided as keyword arguments: setUp A set-up function. This is called before running the tests in each file. The setUp function will be passed a DocTest object. The setUp function can access the test globals as the globs attribute of the test passed. tearDown A tear-down function. This is called after running the tests in each file. The tearDown function will be passed a DocTest object. The tearDown function can access the test globals as the globs attribute of the test passed. globs A dictionary containing initial global variables for the tests. optionflags A set of doctest option flags expressed as an integer. Nrr<r#rdrer)rrNrrGr8optimizerDaddTestr;rCr,rr`rr) rLr7rE test_finderrrFsuiter`r`s r/rrJ sJ#oo v & &F   V5Z  H HE SY'!++ of--...  JJLLL OOE44 t}   " " } %H}&&#CRC=$DM k$22'223333 Lr0c eZdZdZdZdZdS) DocFileCasecfd|jjdS)Nrr)rrr.rrs r/rzDocFileCase.id s'xx *0055666r0c|jjSr)rr`rs r/rzDocFileCase.__repr__ s }%%r0c@d|jjd|jjd|S)Nr-r.z ", line 0 )rr.r`)rr/s r/r)zDocFileCase.format_failure s.=%%%t}'='='=ssD r0N)r?rrrrr)rr0r/rMrM sA777&&&r0rMc $|i}n|}|r|stdt||||pd\}}d|vr||d<tj|}|||||d} t| fi|S)Nrrrr#)rrrerrrrrM) rrbrar7r6rXrdocr.r`s r/ DocFileTestrS s } ,,+,, ,tWo'2744IC j 7  D ! !D   c5$a 8 8D t ' 'w ' ''r0ct}|ddr%t|d|d<|D]"}|t |fi|#|S)aA unittest suite for one or more doctest files. The path to each doctest file is given as a string; the interpretation of that string depends on the keyword argument "module_relative". A number of options may be provided as keyword arguments: module_relative If "module_relative" is True, then the given file paths are interpreted as os-independent module-relative paths. By default, these paths are relative to the calling module's directory; but if the "package" argument is specified, then they are relative to that package. To ensure os-independence, "filename" should use "/" characters to separate path segments, and may not be an absolute path (i.e., it may not begin with "/"). If "module_relative" is False, then the given file paths are interpreted as os-specific paths. These paths may be absolute or relative (to the current working directory). package A Python package or the name of a Python package whose directory should be used as the base directory for module relative paths. If "package" is not specified, then the calling module's directory is used as the base directory for module relative filenames. It is an error to specify "package" if "module_relative" is False. setUp A set-up function. This is called before running the tests in each file. The setUp function will be passed a DocTest object. The setUp function can access the test globals as the globs attribute of the test passed. tearDown A tear-down function. This is called after running the tests in each file. The tearDown function will be passed a DocTest object. The tearDown function can access the test globals as the globs attribute of the test passed. globs A dictionary containing initial global variables for the tests. optionflags A set of doctest option flags expressed as an integer. parser A DocTestParser (or subclass) that should be used to extract tests from the files. encoding An encoding that will be used to convert the files to unicode. rbTra)rDr4rNrIrS)pathskwrKrs r/rr s}p OOE  vv&&=)"&&*;*;<<9 // k$--"--.... Lr0cg}t|D]}t|trk||jdd|j}|r?|d|d|dddDz }|d|dddDz }|r.|ddkr"||r |ddk"|r/|ddkr#|d|r |ddk#d |dzS) awExtract script from text with examples. Converts text with examples to a Python script. Example input is converted to regular code. Example output and all other words are converted to comments: >>> text = ''' ... Here are examples of simple math. ... ... Python has super accurate integer addition ... ... >>> 2 + 2 ... 5 ... ... And very friendly error messages: ... ... >>> 1/0 ... To Infinity ... And ... Beyond ... ... You can use logic if you want: ... ... >>> if 0: ... ... blah ... ... blah ... ... ... ... Ho hum ... ''' >>> print(script_from_examples(text)) # Here are examples of simple math. # # Python has super accurate integer addition # 2 + 2 # Expected: ## 5 # # And very friendly error messages: # 1/0 # Expected: ## To Infinity ## And ## Beyond # # You can use logic if you want: # if 0: blah blah # # Ho hum Nrz # Expected:cg|]}d|zS)z## rrrs r/rz(script_from_examples..= sBBBq57BBBr0r}c,g|]}t|Sr)rrYs r/rz(script_from_examples..@ s0888%Q''888r0rr#) rrrBrrrrrpopr)rkrpiecers r/rr s}tF&&q)) 8 8 eW % % 8 MM%,ss+ , , ,:D C m,,,BBDJJt,<,.U s / / /!$Ar0znot found in testsr#)rNrrrrr)rLr.rFr`testsrcs ` r/r r L sxv & &F OO  ( (E / / / /u / / /D 53444 7D"4>22G Nr0cFt|}t|||dS)z4Debug a single doctest docstring, in argument `src`'N)r debug_script)srcpmr7r_s r/r!r!\ s'"3''G"e$$$$$r0cddl}|r|}ni}|r t|||dS#tt jd|jd}||dt jdYdSxYw|jd d|z||dS)z7Debug a test script. `src` is the script, as a string.r#Nr)T)rr<zexec(%r)) rrrrYrGrsrr interactionr)rbrcr7rps r/raraa sJJJ   C 3 eU # # # # # 3 #,..# $ $ $&&&A GGIII MM$ q 1 2 2 2 2 2 2"":#3UEBBBBBs 4A:B1cpt|}t||}t|||jdS)zDebug a single doctest docstring. Provide the module (or dotted name of the module) containing the test to be debugged and the name (within the module) of the object with the docstring with tests to be debugged. N)rNr rar@)rLr.rcr_s r/r"r"u s:v & &F&&G"fo.....r0c$eZdZdZdZdZdZdS) _TestClassz A pointless class, for sanity-checking of docstring testing. Methods: square() get() >>> _TestClass(13).get() + _TestClass(-12).get() 1 >>> hex(_TestClass(13).square().get()) '0xa9' c||_dS)zval -> _TestClass object with associated value val. >>> t = _TestClass(123) >>> print(t.get()) 123 Nrb)rrbs r/rz_TestClass.__init__ sr0c$|jdz|_|S)zosquare() -> square TestClass's associated value >>> _TestClass(13).square().get() 169 r<rkrs r/squarez_TestClass.square s8q= r0c|jS)z~get() -> return TestClass's associated value. >>> x = _TestClass(-42) >>> print(x.get()) -42 rkrs r/r4z_TestClass.get s xr0N)r?rrrrrmr4rr0r/riri sK  r0riz Example of a string object, searched as-is. >>> x = 1; y = 2 >>> x + y, x * y (3, 2) a In 2.2, boolean expressions displayed 0 or 1. By default, we still accept them. This can be disabled by passing DONT_ACCEPT_TRUE_FOR_1 to the new optionflags argument. >>> 4 == 4 1 >>> 4 == 4 True >>> 4 > 4 0 >>> 4 > 4 False z Blank lines can be marked with : >>> print('foo\n\nbar\n') foo bar z If the ellipsis flag is used, then '...' can be used to elide substrings in the desired output: >>> print(list(range(1000))) #doctest: +ELLIPSIS [0, 1, 2, ..., 999] a If the whitespace normalization flag is used, then differences in whitespace are ignored. >>> print(list(range(30))) #doctest: +NORMALIZE_WHITESPACE [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29] )rirzbool-int equivalencez blank linesellipsiszwhitespace normalizationc4ddl}|d}|ddddd |d d d tgd |dddd|ddd|}|j}|j}d}|jD]}|t|z}|j r |tz}|D]}| dr|tj |\}}tj d|t#|dd} tj d=t%| ||\} } nt'|d||\} } | rdSdS)Nr#zdoctest runner) descriptionrxz --verbose store_trueFz'print very verbose output for all tests)actiondefaulthelpz-oz--optionrzqspecify a doctest option flag to apply to the test run; may be specified more than once to apply multiple options)rschoicesrtruz-fz --fail-fastzystop running tests after first failure (this is a shorthand for -o FAIL_FAST, and is in addition to any other -o options))rsrurorz file containing the tests to run)nargsruz.pyr)rbr5rzr))argparseArgumentParser add_argumentr*keys parse_argsror5r fail_fastrr~rrrrGinsertrDrr) ryr6r testfilesr5rrr`dirnamerr}rs r/_testr s OOO  $ $1A $ B BF k,FHHH j 3 8 8 : :BEGGG  mLFHHH c?AAA     D IlGG+//&v.. ~9   U # # K!# h 7 7 GX HOOAw ' ' '8CRC=))A !!W'JJJKHaa"8U-4'KKKKHa  11  1r0r)r<)rf) NNNNTr#NFF)FrNr#ru)FN)F)Tr __docformat____all__r2rr@r>rrrirGrprior$r% collectionsr&r'r*rrrrrrrr r r r r rrrrr;rNrSrermrxrzrrrrrrYrrrrrr Exceptionrrrrrrrrrrrr; TestSuiterDrrMrSrrr r!rar"rirXrr?exitrr0r/rsX%%N& + + + Z 22222222""""""j(:;; .OOO-,-EFF++,CDD**+ABB  z * *6""--.GHH*)*()  , ,#">22 "">22 "">22 //0KLL   , ,   -- !&   >>>>&DDD"""$////             ///b4"%"%"%"%"%CG"%"%"%J , , ,\B$B$B$B$B$B$B$B$HGDGDGDGDGDGDGDGDZd;d;d;d;d;d;d;d;VDDDDDDDDT GGGGGGGGRP5P5P5P5P5P5P5P5dY&)&e1e1e1e1e1-e1e1e1\ 373705f6f6f6f6P(,$dU==??y6y6y6y6v:B:;44446!!!Ha0a0a0a0a0(#a0a0a0Fk"     H&   >>>>@     +   '+D==??((((4CCCRP$P$P$d %%%% CCCC( / / / /********X%%( )Q0 0 f* * * Z z CHUUWWr0