/snap/core24/1643/usr/lib/python3.12/__pycache__
NameSizeModeActions
abc.cpython-312.pyc80550644editdlrm
aifc.cpython-312.pyc428630644editdlrm
antigravity.cpython-312.pyc10030644editdlrm
argparse.cpython-312.pyc1016820644editdlrm
ast.cpython-312.pyc1002790644editdlrm
base64.cpython-312.pyc244080644editdlrm
bdb.cpython-312.pyc373590644editdlrm
bisect.cpython-312.pyc36410644editdlrm
bz2.cpython-312.pyc151330644editdlrm
calendar.cpython-312.pyc396210644editdlrm
cgi.cpython-312.pyc402280644editdlrm
cgitb.cpython-312.pyc173320644editdlrm
chunk.cpython-312.pyc73100644editdlrm
cmd.cpython-312.pyc186190644editdlrm
code.cpython-312.pyc130510644editdlrm
codecs.cpython-312.pyc422740644editdlrm
codeop.cpython-312.pyc69160644editdlrm
colorsys.cpython-312.pyc46420644editdlrm
compileall.cpython-312.pyc204970644editdlrm
configparser.cpython-312.pyc635820644editdlrm
contextlib.cpython-312.pyc303760644editdlrm
contextvars.cpython-312.pyc2610644editdlrm
copy.cpython-312.pyc98000644editdlrm
copyreg.cpython-312.pyc74140644editdlrm
cProfile.cpython-312.pyc85930644editdlrm
crypt.cpython-312.pyc53610644editdlrm
csv.cpython-312.pyc177880644editdlrm
dataclasses.cpython-312.pyc446780644editdlrm
datetime.cpython-312.pyc4090644editdlrm
decimal.cpython-312.pyc4060644editdlrm
difflib.cpython-312.pyc754990644editdlrm
dis.cpython-312.pyc345600644editdlrm
doctest.cpython-312.pyc1056860644editdlrm
enum.cpython-312.pyc807080644editdlrm
filecmp.cpython-312.pyc146610644editdlrm
fileinput.cpython-312.pyc202800644editdlrm
fnmatch.cpython-312.pyc64950644editdlrm
fractions.cpython-312.pyc366670644editdlrm
ftplib.cpython-312.pyc426360644editdlrm
functools.cpython-312.pyc405060644editdlrm
genericpath.cpython-312.pyc68220644editdlrm
getopt.cpython-312.pyc83630644editdlrm
getpass.cpython-312.pyc68500644editdlrm
gettext.cpython-312.pyc221510644editdlrm
glob.cpython-312.pyc98410644editdlrm
graphlib.cpython-312.pyc103270644editdlrm
gzip.cpython-312.pyc320150644editdlrm
hashlib.cpython-312.pyc80870644editdlrm
heapq.cpython-312.pyc179560644editdlrm
hmac.cpython-312.pyc106980644editdlrm
imaplib.cpython-312.pyc628890644editdlrm
imghdr.cpython-312.pyc69440644editdlrm
inspect.cpython-312.pyc1334460644editdlrm
io.cpython-312.pyc41390644editdlrm
ipaddress.cpython-312.pyc907620644editdlrm
keyword.cpython-312.pyc10410644editdlrm
linecache.cpython-312.pyc64010644editdlrm
locale.cpython-312.pyc595360644editdlrm
lzma.cpython-312.pyc158550644editdlrm
mailbox.cpython-312.pyc1116180644editdlrm
mailcap.cpython-312.pyc111550644editdlrm
mimetypes.cpython-312.pyc241850644editdlrm
modulefinder.cpython-312.pyc279440644editdlrm
netrc.cpython-312.pyc89030644editdlrm
nntplib.cpython-312.pyc449390644editdlrm
ntpath.cpython-312.pyc260330644editdlrm
nturl2path.cpython-312.pyc30340644editdlrm
numbers.cpython-312.pyc139670644editdlrm
opcode.cpython-312.pyc147160644editdlrm
operator.cpython-312.pyc173640644editdlrm
optparse.cpython-312.pyc675460644editdlrm
os.cpython-312.pyc434740644editdlrm
pathlib.cpython-312.pyc620980644editdlrm
pdb.cpython-312.pyc849190644editdlrm
pickle.cpython-312.pyc761760644editdlrm
pickletools.cpython-312.pyc811280644editdlrm
pipes.cpython-312.pyc109140644editdlrm
pkgutil.cpython-312.pyc199590644editdlrm
platform.cpython-312.pyc416000644editdlrm
plistlib.cpython-312.pyc412860644editdlrm
poplib.cpython-312.pyc184460644editdlrm
posixpath.cpython-312.pyc182360644editdlrm
pprint.cpython-312.pyc294740644editdlrm
profile.cpython-312.pyc225400644editdlrm
pstats.cpython-312.pyc379220644editdlrm
pty.cpython-312.pyc73630644editdlrm
pyclbr.cpython-312.pyc148870644editdlrm
pydoc.cpython-312.pyc1429550644editdlrm
py_compile.cpython-312.pyc100780644editdlrm
queue.cpython-312.pyc147320644editdlrm
quopri.cpython-312.pyc93230644editdlrm
random.cpython-312.pyc331530644editdlrm
reprlib.cpython-312.pyc99090644editdlrm
rlcompleter.cpython-312.pyc82820644editdlrm
runpy.cpython-312.pyc143850644editdlrm
sched.cpython-312.pyc77350644editdlrm
secrets.cpython-312.pyc25560644editdlrm
selectors.cpython-312.pyc261280644editdlrm
shelve.cpython-312.pyc129130644editdlrm
shlex.cpython-312.pyc141620644editdlrm
shutil.cpython-312.pyc681130644editdlrm
signal.cpython-312.pyc44480644editdlrm
site.cpython-312.pyc290630644editdlrm
sitecustomize.cpython-312.pyc3000644editdlrm
smtplib.cpython-312.pyc482210644editdlrm
sndhdr.cpython-312.pyc107120644editdlrm
socket.cpython-312.pyc418170644editdlrm
socketserver.cpython-312.pyc342580644editdlrm
sre_compile.cpython-312.pyc6250644editdlrm
sre_constants.cpython-312.pyc6280644editdlrm
sre_parse.cpython-312.pyc6210644editdlrm
ssl.cpython-312.pyc630110644editdlrm
stat.cpython-312.pyc52310644editdlrm
statistics.cpython-312.pyc554230644editdlrm
string.cpython-312.pyc114820644editdlrm
stringprep.cpython-312.pyc251600644editdlrm
struct.cpython-312.pyc3250644editdlrm
subprocess.cpython-312.pyc791870644editdlrm
sunau.cpython-312.pyc254230644editdlrm
symtable.cpython-312.pyc187810644editdlrm
sysconfig.cpython-312.pyc300010644editdlrm
tabnanny.cpython-312.pyc121560644editdlrm
tarfile.cpython-312.pyc1233880644editdlrm
telnetlib.cpython-312.pyc284230644editdlrm
tempfile.cpython-312.pyc473390644editdlrm
textwrap.cpython-312.pyc182930644editdlrm
this.cpython-312.pyc14080644editdlrm
threading.cpython-312.pyc653460644editdlrm
timeit.cpython-312.pyc148640644editdlrm
token.cpython-312.pyc35570644editdlrm
tokenize.cpython-312.pyc247750644editdlrm
trace.cpython-312.pyc330240644editdlrm
traceback.cpython-312.pyc515230644editdlrm
tracemalloc.cpython-312.pyc269070644editdlrm
tty.cpython-312.pyc26680644editdlrm
turtle.cpython-312.pyc1846320644editdlrm
types.cpython-312.pyc149390644editdlrm
typing.cpython-312.pyc1418600644editdlrm
uu.cpython-312.pyc78160644editdlrm
uuid.cpython-312.pyc330070644editdlrm
warnings.cpython-312.pyc237920644editdlrm
wave.cpython-312.pyc320840644editdlrm
weakref.cpython-312.pyc313480644editdlrm
webbrowser.cpython-312.pyc263530644editdlrm
xdrlib.cpython-312.pyc118410644editdlrm
zipapp.cpython-312.pyc99770644editdlrm
zipimport.cpython-312.pyc244750644editdlrm
_aix_support.cpython-312.pyc47590644editdlrm
_collections_abc.cpython-312.pyc459120644editdlrm
_compat_pickle.cpython-312.pyc72210644editdlrm
_compression.cpython-312.pyc74970644editdlrm
_distutils_system_mod.cpython-312.pyc78180644editdlrm
_markupbase.cpython-312.pyc122790644editdlrm
_osx_support.cpython-312.pyc177310644editdlrm
_pydatetime.cpython-312.pyc941930644editdlrm
_pydecimal.cpython-312.pyc2278070644editdlrm
_pyio.cpython-312.pyc1102690644editdlrm
_pylong.cpython-312.pyc99830644editdlrm
_py_abc.cpython-312.pyc70540644editdlrm
_sitebuiltins.cpython-312.pyc47600644editdlrm
_strptime.cpython-312.pyc241160644editdlrm
_sysconfigdata__linux_x86_64-linux-gnu.cpython-312.pyc586510644editdlrm
_sysconfigdata__x86_64-linux-gnu.cpython-312.pyc586450644editdlrm
_threading_local.cpython-312.pyc82950644editdlrm
_weakrefset.cpython-312.pyc117510644editdlrm
__future__.cpython-312.pyc47040644editdlrm
__hello__.cpython-312.pyc8700644editdlrm
Edit: /snap/core24/1643/usr/lib/python3.12/__pycache__/tempfile.cpython-312.pyc (47339B)
Цi֑dZgdZddlZddlZddlZddlZ ddl Z e jZ ddlZddlm Z!ddlZddl"Z#ddl$Z%ddl&Z&e&jNZ(e jRe jTze jVzZ,e-e dre,e j\zZ,e,Z/e-e d re/e j`zZ/e-e d r e jbZ1nd Z1d Z2e(Z3d Z4dZ5dZ6GddZ7dZ8dZ9da:dZ;dZdZ?dZ@daAdZBdZCdZDd2dZEd3dZFde2dfd ZGGd!d"ZHGd#d$ZI d4dd%d&d'ZJe jd(k7sejd)k(reJZMne-e d*aN d5dd+d,ZMGd-d.ejZPGd/d0ZQy#e$rddlZddlZdZdZe j*e j"e j,e j.he j0kxr2e j2e j4vxre j"e j6vZd1dZ YwxYw)6aTemporary files. This module provides generic, low- and high-level interfaces for creating temporary files and directories. All of the interfaces provided by this module can be used without fear of race conditions except for 'mktemp'. 'mktemp' is subject to race conditions and should not be used; it is provided for backward compatibility only. The default path names are returned as str. If you supply bytes as input, all return values will be in bytes. Ex: >>> tempfile.mkstemp() (4, '/tmp/tmptpu9nin8') >>> tempfile.mkdtemp(suffix=b'') b'/tmp/tmppbi8f0hy' This module also provides some data items to the user: TMP_MAX - maximum number of names that will be tried before giving up. tempdir - If this is set to a string before the first use of any routine from this module, it will be considered as another candidate location to store temporary files. ) NamedTemporaryFile TemporaryFileSpooledTemporaryFileTemporaryDirectorymkstempmkdtempmktempTMP_MAX gettempprefixtempdir gettempdirgettempprefixb gettempdirbNc tjj|r td g} tj |}|D]z}tjj||} tj|j}tj|r t||e tj|| tj|y#t$r7|tjj|t j YywxYw#t$r.|tj |t j YwxYw#t$rd}YwxYw#t$r.|tj|t j YXwxYw#t$r-|tj|t j YywxYw)N%Cannot call rmtree on a symbolic linkr)_ospathislinkOSError_sysexc_infolistdirjoinlstatst_mode_statS_ISDIR_rmtree_unsafeunlinkrmdir)ronerrornamesnamefullnamemodes /usr/lib/python3.12/tempfile.pyrr2sn 88??4 AB B ! E4 D! ?88==t, 99X&..D ==  8W - ? 8$ ?2 $/ t}}7 4 T4==?34  D  ? Hdmmo> ? 2 412sX*CD+E-E)F#=DD3EE E&%E&)3F F #3GGc<g} tj|}|D]}tj j||} tj||d}|j}tj|r tj|tj|} tj jtj| r&t!| || tj"||n tdtj&|  tj(||y#t$r<}||_|tj|t j Yd}~`d}~wwxYw#t$rd}Y+wxYw#t$r-|tj"|t j YwxYw#t$r8|tj j$|t j YwxYw#tj&| wxYw#t$r.|tj|t j YEwxYw#t$r.|tj(|t j YwxYw)NF)dir_fdfollow_symlinksr)r(r)rrrfilenamerrrrstatrrropenO_RDONLYsamestatfstat_rmtree_safe_fdr rcloser) topfdrr!r"errr#r$orig_str%dirfds r&r0r0Ss E4 E"#?88==t, hhtE5IG??D ==  %s||EB%xx((#))E2BC'xAJIId59P#*+1#22 IIe$ ? 4.C#? 4  T4==?334 D  'J#CIIxIJ 'P#CHHOOXt}}OPIIe$) =(DMMO< =0 ? Hdmmo> ?sD9$F:&H*!AH"F9H; G I$9 E>1E99E> FF3G HG  H =H  H H  HH'*3I! I!$3JJc|rd}n|d}trt|trtj|} tj |} tj|tj} tjj|tj|r$t||| tj|n t!dtj$|yt'||S#t $r-|tj |tjYywxYw#t $r-|tj |tjYywxYw#t $r-|tj|tjYwxYw#t $r8|tjj"|tjY wxYw#tj$|wxYw)aRecursively delete a directory tree. If ignore_errors is set, errors are ignored; otherwise, if onerror is set, it is called to handle the error with arguments (func, path, exc_info) where func is platform and implementation dependent; path is the argument to that function that caused it to fail; and exc_info is a tuple returned by sys.exc_info(). If ignore_errors is false and onerror is None, an exception is raised. cyNargss r&r!z_rmtree..onerrors Ncr8r9r:s r&r!z_rmtree..onerrors r<r)_use_fd_functions isinstancebytesrfsdecoder Exceptionrrr,r-rr.r/r0r rrr1r)r ignore_errorsr!r4fds r&_rmtreerEsx    dE "<<%D iioG $ -B xx  #))B-8D'2>IIdOD!"IJJ IIbMdG,,1  CIItT]]_ 5     CIItT]]_ 5  >CIItT]]_=> DCHHOOT4==?CD IIbMsrC8$D13AG'4E* G' F#83D.-D.13E'&E'*3F G'F  G'#=G$ G'#G$$G''G>)Random O_NOFOLLOWO_BINARYr i'tmpcN tj|y#t$rYywxYw)NTF)rrr)fns r&_existsrLs+ "    $$cRd}|D]w}|t|tjrtj|}t|tr|t ur t dt}_|tur t dt }y|&tttt rt StS|S)zBLook at the type of all args and divine their implied return type.Nz1Can't mix bytes and non-bytes in path components.)r?rPathLikefspathr@str TypeErrorr )r; return_typeargs r&_infer_return_typerUsK ;  c3<< (**S/C c5 !c!!344Ke#!344K!" ?j#6JL r<ct|||}||}|(|turt}ntjt}||tur t }n t }||||fS)z9Common parameter processing for most APIs in this module.)rUrQtemplaterfsencoder r)prefixsuffixdir output_types r&_sanitize_paramsr]sf$VVS9K ~ ~ # F\\(+F { # ,C-C 63 ++r<c0eZdZdZdZedZdZdZy)_RandomNameSequencea,An instance of _RandomNameSequence generates an endless sequence of unpredictable strings which can safely be incorporated into file names. Each string is eight characters long. Multiple threads can safely use the same instance at the same time. _RandomNameSequence is an iterator.%abcdefghijklmnopqrstuvwxyz0123456789_ctj}|t|ddk7rt|_||_|jS)N_rng_pid)rgetpidgetattr_Random_rngrb)selfcur_pids r&rngz_RandomNameSequence.rngs8**, gdJ5 5 DI#DMyyr<c|Sr8r9rgs r&__iter__z_RandomNameSequence.__iter__!s r<cndj|jj|jdS)N)k)rrichoices charactersrks r&__next__z_RandomNameSequence.__next__$s)wwtxx''1'=>>r<N) __name__ __module__ __qualname____doc__rrpropertyrirlrsr9r<r&r_r_s*+9J ?r<r_c g}dD]+}tj|}|s|j|-tjdk(rR|j tj j dtj jdddddgn|j gd  |jtj|S#ttf$r#|jtjY|SwxYw) z[Generate a list of candidate temporary directories which _get_default_tempdir will try.)TMPDIRTEMPTMPntz~\AppData\Local\Tempz%SYSTEMROOT%\Tempzc:\tempzc:\tmpz\tempz\tmp)z/tmpz/var/tmpz/usr/tmp) rgetenvappendr#extendr expanduser expandvarsgetcwdAttributeErrorrcurdir)dirlistenvnamedirnames r&_candidate_tempdir_listr'sG+,**W% GNN7+,  xx4,,-DE,,-AB#Y'D E 9:#szz|$ N G $#szz" N#s,#C.DDc|t}t}|D]}|tjk7rtjj |}t dD]}t|}tjj||} tj|td} tj|dtj| tj||ccSt+t,j.d|z#tj|wxYw#tj|wxYw#t$rYt$r^tj dk(rFtjj#|r'tj$|tj&rYSYt($rYwxYw)aqCalculate the default directory to use for temporary files. This routine should be called exactly once. We determine whether or not a candidate temp dir is usable by trying to create and write to a file in that directory. If this is successful, the test file is deleted. To prevent denial of service, the name of the test file must be randomized.dsblatr}z)No usable temporary directory found in %s)r_rrrrabspathrangenextrr,_bin_openflagswriter1rFileExistsErrorPermissionErrorr#isdiraccessW_OKrFileNotFoundError_errnoENOENT)namerrr[seqr#r*rDs r&_get_default_tempdirrBsS !E%'G #** ((""3'C: C;Dxx}}S$/H XXh>)& "g. " JJx(   8 FMMG#$ %% " JJx(" " HH$)<JJsCHH-  sID>#D 9D$D> D!!D$$D;;D>> F; AF;.F;:F;ct?tj t tatj tStS#tj wxYw)z7Common setup sequence for all user-callable interfaces.)_name_sequence _once_lockacquirer_releaser9r<r&_get_candidate_namesrpsP !%!4!6    >    A A"ctjj|}t}|turt tj |}ttD]f}t|}tjj|||z|z}tjd| tj||d} | |fcStt(j*d#t$rYt$rZtj dk(rEtjj#|r&tj$|tj&rYwxYw)z>Code common to mkstemp, TemporaryFile, and NamedTemporaryFile.ztempfile.mkstemprr}z#No usable temporary file name found)rrrrr@maprXrr rrrauditr,rrr#rrrrEEXIST) r[presufflagsr\r"rr#filerDs r&_mkstemp_innerr~s  ((  3 C "EeCLL%(W~E{xx}}S#*s"23 %t, $u-B4x!$ &--? AA   D SXX^^C%8 3) s&C E )AE  E c|tjvr ||g|ddiytjdk(stjj |s ||g|yy)Nr)Fr})rsupports_follow_symlinksr#rr)funcrr;s r&_dont_follow_symlinksrsO s+++ T0D0%0 T !6 TD"7r<c tj}t||dttj|dy#t$rY'wxYw)Nr)rchflagsrrchmod)rrs r& _resetpermsrsB0++ gtQ/#))T51    s; AAc4tjtS)z7The default prefix for temporary directories as string.)rrArWr9r<r&r r  << !!r<c4tjtS)z6The default prefix for temporary directories as bytes.)rrXrWr9r<r&r r rr<ct?tj t tatj tStS#tj wxYw)z&Private accessor for tempfile.tempdir.)r rrrrr9r<r& _gettempdirrsL !.0    N7N    rc<tjtS)z Returns tempfile.tempdir as str.)rrArr9r<r&r r  << &&r<c<tjtS)z"Returns tempfile.tempdir as bytes.)rrXrr9r<r&rrrr<cbt|||\}}}}|rt}nt}t|||||S)aUser-callable function to create and return a unique temporary file. The return value is a pair (fd, name) where fd is the file descriptor returned by os.open, and name is the filename. If 'suffix' is not None, the file name will end with that suffix, otherwise there will be no suffix. If 'prefix' is not None, the file name will begin with that prefix, otherwise a default prefix is used. If 'dir' is not None, the file will be created in that directory, otherwise a default directory is used. If 'text' is specified and true, the file is opened in text mode. Else (the default) the file is opened in binary mode. If any of 'suffix', 'prefix' and 'dir' are not None, they must be the same type. If they are bytes, the returned name will be bytes; str otherwise. The file is readable and writable only by the creating user ID. If the operating system uses permission bits to indicate whether a file is executable, the file is executable by no one. The file descriptor is not inherited by children of this process. Caller is responsible for deleting the file when done with it. )r]_text_openflagsrr)rZrYr[textr\rs r&rrs;:(8'L$FFC  #vvuk BBr<ct|||\}}}}t}|turttj |}t tD]}t|}tjj|||z|z}tjd| t j|dtjj)|cStt*j,d#t$rYt$r[tj dk(rFtjj#|r't j$|tj&rY wxYw)aUser-callable function to create and return a unique temporary directory. The return value is the pathname of the directory. Arguments are as for mkstemp, except that the 'text' argument is not accepted. The directory is readable, writable, and searchable only by the creating user. Caller is responsible for deleting the directory when done with it. ztempfile.mkdtemprr}z(No usable temporary directory name found)r]rr@rrrXrr rrrrrmkdirrrr#rrrrrr)rZrYr[r\r"rr#rs r&rrs(8'L$FFC "EeCLL%(W~&E{xx}}S&4-&"89 %t,  IIdE "xx%%!&$ &--D FF   D SXX^^C%8 3) sC++ E6AEErnc | t}t}ttD]B}t |}t j j|||z|z}t|r@|cSttjd)aUser-callable function to return a unique temporary file name. The file is not created. Arguments are similar to mkstemp, except that the 'text' argument is not accepted, and suffix=None, prefix=None and bytes file names are not supported. THIS FUNCTION IS UNSAFE AND SHOULD NOT BE USED. The file name may refer to a file that did not exist at some point, but by the time you get around to creating it, someone else may have beaten you to the punch. z"No usable temporary filename found) r rrr rrrrrLrrr)rZrYr[r"rr#rs r&rrsw$ {l "EW~E{xx}}S&4-&"89t}K  &--> @@r<cfeZdZdZdZdZd dZejdk(ejfdZ dZ dZ y) _TemporaryFileCloserzA separate object allowing proper closing of a temporary file's underlying file object, without adding a __del__ method to the temporary file.Fc<||_||_||_||_yr8)rr#deletedelete_on_closergrr#rrs r&__init__z_TemporaryFileCloser.__init__Cs   .r<r}c|jsed|_ |js!d|_|jj|jr#|r |j s ||j yyyy#t$rYywxYw#|jr2|r |j s# ||j w#t$rYwwxYwwwxYwNT)cleanup_called close_calledrr1rrr#r)rgwindowsrs r&cleanupz_TemporaryFileCloser.cleanupIs"""&D  (((,D%IIOO%;;D4H4Htyy)5I;#-;;D4H4Htyy),5I;sA-BA33 A?>A?CB10C1 B=:C<B==Cc|jsMd|_ |jj|jr|jr|j yyyy#|jr|jr|j wwwxYwr)rrr1rrrrks r&r1z_TemporaryFileCloser.closeYsm  $D  # !;;4#7#7LLN$8; ! ;;4#7#7LLN$8;s A,Bc$|jyr8)rrks r&__del__z_TemporaryFileCloser.__del__bs  r<NTT) rtrurvrwrrrrr#rrr1rr9r<r&rr;s;NL/ #xx4/ #r<rc6eZdZdZd dZdZdZdZdZdZ y) _TemporaryFileWrapperzTemporary file wrapper This class provides a wrapper around files opened for temporary use. In particular, it seeks to automatically remove the file when it is no longer needed. cF||_||_t|||||_yr8)rr#r_closerrs r&rz_TemporaryFileWrapper.__init__ns%  +D$,;= r<c|jd}t||}t|dr2|tjfd}|j |_|}t |ts t||||S)Nr__call__c|i|Sr8r9)r;kwargsrs r& func_wrapperz7_TemporaryFileWrapper.__getattr__..func_wrapper|sT,V,,r<) __dict__rdhasattr _functoolswrapsrr?intsetattr)rgr#rarrs @r& __getattr__z!_TemporaryFileWrapper.__getattr__tsy}}V$ D$  1j !D   d # -$ -$(<.openers!#vvukJD r< bufferingnewlineencodingrrbufferraw) r]rrr# O_TEMPORARY_io text_encodingr,rdrr1r)r%rrrrZrYr[rrrrrrrr#r\s ``` @@@r&rrs6(8'L$FFC E xx4F   $$$X. DxxTY '(6%' $$/C#uc*CCH(tV_M M  JJL    HH O JJt  s/C .B;;CC1Dposixcygwin O_TMPFILErc  d|vrtj|}t\ t trId  fd} tj ||||||} t | d| } t | d| } | _| Sd  fd}tj ||||||} t | d| } t | d| } | _| S#t$rdaYXt$rYbwxYw) aCreate and return a temporary file. Arguments: 'prefix', 'suffix', 'dir' -- as for mkstemp. 'mode' -- the mode argument to io.open (default "w+b"). 'buffering' -- the buffer size argument to io.open (default -1). 'encoding' -- the encoding argument to io.open (default None) 'newline' -- the newline argument to io.open (default None) 'errors' -- the errors argument to io.open (default None) The file is created as mkstemp() would do it. Returns an object with a file-like interface. The file has no name, and will cease to exist when it is closed. rNctjztjz}tj|dS)Nr)rrO_CREATr,)r;flags2r[rDrs r&rzTemporaryFile..openers3#--/CKK<?XXc651 r<rrrFct\} tj|S#t$r}tjd}~wwxYwr8)rrr BaseExceptionr1) r;r#er[rDrr\rYrZs r&rzTemporaryFile..opener'sQ%c665+NHB  4 I!  "  s, AA  A) rrr]r_O_TMPFILE_WORKSr,rdr#IsADirectoryErrorr)r%rrrrZrYr[rrrrrDrr\s ``` @@@r&rrs$ d?((2H+;FFC+P([ B   xxTY(/('-f>dHd3c5#. &  xxTY '(6%'dHd+c5#& E% ) $)   s>C C*C*)C*cDeZdZdZdZ d%dddZeejZ dZ dZ dZ d Z d Zd Zd Zed ZedZedZdZdZdZedZedZedZdZdZdZdZdZdZ dZ!dZ"dZ#dZ$d&d Z%d!Z&d"Z'd#Z(d$Z)y)'rzTemporary file wrapper, specialized to switch from BytesIO or StringIO to a real file when it exceeds a certain size or when a fileno is needed. FNrc  d|vrtj|_nEtj|}tjtj|| ||_||_d|_|||||||| d|_y)Nr)rrrF)r%rrZrYrrr[r)rBytesIO_filer TextIOWrapper _max_size_rolled_TemporaryFileArgs) rgmax_sizer%rrrrZrYr[rs r&rzSpooledTemporaryFile.__init__?sy $;DJ((2H**3;;=%-f$+-DJ" +/i-3v/7G*-#Ar<c|jry|j}|r%|j|kDr|jyyyr8)rrtellrollover)rgrrs r&_checkzSpooledTemporaryFile._checkRs4 <<>>  h. MMO/8r<c|jry|j}tdi|jx}|_|`|j }t |dr8|j j|jjn|j|j|j|dd|_y)NrrTr9) rrrrrrrrdetachgetvalueseek)rgrnewfileposs r&rzSpooledTemporaryFile.rolloverXs <<zz,Gt/F/FGG$*  #iik 7H % NN !7!7!9 : MM$--/ * S! r<cH|jjr td|S)Nz%Cannot enter context with closed file)rclosed ValueErrorrks r&rzSpooledTemporaryFile.__enter__ms ::  DE E r<c8|jjyr8rr1rgrrrs r&rzSpooledTemporaryFile.__exit__r r<c6|jjSr8)rrlrks r&rlzSpooledTemporaryFile.__iter__vzz""$$r<c|js=tjdj|td||j yy)NzUnclosed file {!r}) stacklevelsource)r  _warningswarnformatResourceWarningr1rks r&rzSpooledTemporaryFile.__del__ys<{{ NN$++D1   JJLr<c8|jjyr8r#rks r&r1zSpooledTemporaryFile.closer%r<c.|jjSr8)rr rks r&r zSpooledTemporaryFile.closedzz   r<c.|jjSr8)rrrks r&rzSpooledTemporaryFile.encodingzz"""r<c.|jjSr8)rrrks r&rzSpooledTemporaryFile.errorsr2r<cV|j|jjSr8)rrfilenorks r&r7zSpooledTemporaryFile.filenos zz  ""r<c8|jjyr8)rflushrks r&r9zSpooledTemporaryFile.flushr%r<c6|jjSr8)risattyrks r&r;zSpooledTemporaryFile.isattyzz  ""r<cl |jjS#t$r|jdcYSwxYw)Nr%)rr%rrrks r&r%zSpooledTemporaryFile.modes5 3::?? " 3**62 2 3s 33cN |jjS#t$rYywxYwr8)rr#rrks r&r#zSpooledTemporaryFile.names' ::?? "  rMc.|jjSr8)rnewlinesrks r&r@zSpooledTemporaryFile.newlinesr4r<c6|jjSr8)rreadablerks r&rBzSpooledTemporaryFile.readabler'r<c4|jj|Sr8)rreadrgr;s r&rDzSpooledTemporaryFile.readtzz%%r<c4|jj|Sr8)rread1rEs r&rHzSpooledTemporaryFile.read1stzz&&r<c8|jj|Sr8)rreadintorgrs r&rJzSpooledTemporaryFile.readintoszz""1%%r<c8|jj|Sr8)r readinto1rKs r&rMzSpooledTemporaryFile.readinto1szz##A&&r<c4|jj|Sr8)rreadlinerEs r&rOzSpooledTemporaryFile.readlines"tzz""D))r<c4|jj|Sr8)r readlinesrEs r&rQzSpooledTemporaryFile.readliness#tzz##T**r<c6|jjSr8)rseekablerks r&rSzSpooledTemporaryFile.seekabler'r<c4|jj|Sr8)rrrEs r&rzSpooledTemporaryFile.seekrFr<c6|jjSr8)rrrks r&rzSpooledTemporaryFile.tellszz  r<c||jjS||jkDr|j|jj|Sr8)rtruncaterr)rgsizes r&rWzSpooledTemporaryFile.truncatesD <::&&( (dnn$ ::&&t, ,r<c6|jjSr8)rwritablerks r&rZzSpooledTemporaryFile.writabler'r<cb|j}|j|}|j||Sr8)rrr)rgsrrvs r&rzSpooledTemporaryFile.writes)zz ZZ] D r<cb|j}|j|}|j||Sr8)r writelinesr)rgiterablerr]s r&r_zSpooledTemporaryFile.writeliness*zz __X & D r<c6|jjSr8)rrrks r&rzSpooledTemporaryFile.detachr<r<)rw+bNNNNNr8)*rtrurvrwrr classmethod_types GenericAlias__class_getitem__rrrrrlrr1rxr rrr7r9r;r%r#r@rBrDrHrJrMrOrQrSrrrWrZrr_rr9r<r&rr8s.G9;(,/3A?CA"$F$7$78 * %!!##!!##33  ##%&'&'*+%&!-%  #r<rceZdZdZ d dddZed dZeddZdZd Z d Z d Z ee jZy)raCreate and return a temporary directory. This has the same behavior as mkdtemp but can be used as a context manager. For example: with TemporaryDirectory() as tmpdir: ... Upon exiting the context, the directory and everything contained in it are removed (unless delete=False is passed or an exception is raised during cleanup and ignore_cleanup_errors is not True). Optional Arguments: suffix - A str suffix for the directory name. (see mkdtemp) prefix - A str prefix for the directory name. (see mkdtemp) dir - A directory to create this temp dir in. (see mkdtemp) ignore_cleanup_errors - False; ignore exceptions during cleanup? delete - True; whether the directory is automatically deleted. NT)rct||||_||_||_t j ||j |jdj||j|j|_y)NzImplicitly cleaning up {!r}) warn_messagerCr) rr#_ignore_cleanup_errors_delete_weakreffinalize_cleanupr. _finalizer)rgrZrYr[ignore_cleanup_errorsrs r&rzTemporaryDirectory.__init__s`FFC0 &;# "++ $--6==dC55dllLr<c6fd}t|y)Nc2t|tr]r |k(rry |k7r(ttjj |t| tj |yyyt|trysy#t$rj|Y4t$r]tjj|rtjj|rrYyj||k(YwxYw#t$rYywxYw)NrC)rCrepeated) r?rrrrrrr rEr isjunctionr)rrrclsrCr#rus r&onexcz)TemporaryDirectory._rmtree..onexcs#/ $t|#CHH$4$4T$:;%= 4(=G"C!23$%+-G D F* = #xx~~d3sxx7J7J47P, &! D .2dl$= =)sH8D BD D "AD*D ,DD DD DD)rx)rE)rwr#rCrurxs```` r&rEzTemporaryDirectory._rmtrees$ L E"r<cd|r.|j||tj|tyyNrt)rEr,r-r/)rwr#rjrCrs r&rozTemporaryDirectory._cleanup/s(  KKMK : NN< 9 r<cbdj|jj|jS)Nz <{} {!r}>)r. __class__rtr#rks r&__repr__zTemporaryDirectory.__repr__5s#!!$.."9"9499EEr<c|jSr8)r#rks r&rzTemporaryDirectory.__enter__8s yyr<c>|jr|jyyr8)rlrr$s r&rzTemporaryDirectory.__exit__;s << LLN r<c|jjs)tjj |j r(|j |j |jyyrz)rprrrexistsr#rErkrks r&rzTemporaryDirectory.cleanup?sE ?? ! ! #sxxtyy'A LL$2M2ML N(Br<NNNF)FF)FT)rtrurvrwrrdrEror}rrrrerfrgr9r<r&rrsp&6:',L8<L'#'#R:: FO$F$7$78r<r)FNr)NNN)rbrcNNNNNT)rbrcNNNNN)Rrw__all__ functoolsrwarningsr,iorosrshutil_shutilrmtreerE ImportErrorsysrr+rrr0r,rr supports_dir_fdr supports_fdrr>errnorrandomrFretypesreweakrefrm_thread allocate_lock_allocate_lockO_RDWRrO_EXCLrrrGrrHr rWrrLrUr]r_rrrrrrrr r r rr rrrrrrrr#platformrr IOBaserrr9r<r&rsl2 J- NN'T$&&**s{{*SZZ7 3 s~~%O  3 cll"N 3 kkGG   :,$??06*%X A:2""  ''$CN&FPX4@@((V<<|;?9=(,<8<'+<|88w$--83'M sK09=8<I*.IVl#3::l#^\9\9sG-2B*?X#((CJJ B(()>[[COO3>XX!=!== 1-mG-sFBH  H