/usr/lib/python3/dist-packages/twisted/python/__pycache__
NameSizeModeActions
compat.cpython-310.pyc153980644editdlrm
components.cpython-310.pyc143640644editdlrm
constants.cpython-310.pyc4680644editdlrm
context.cpython-310.pyc46570644editdlrm
deprecate.cpython-310.pyc252210644editdlrm
failure.cpython-310.pyc189600644editdlrm
fakepwd.cpython-310.pyc72920644editdlrm
filepath.cpython-310.pyc520500644editdlrm
formmethod.cpython-310.pyc127170644editdlrm
htmlizer.cpython-310.pyc35820644editdlrm
lockfile.cpython-310.pyc51380644editdlrm
log.cpython-310.pyc230160644editdlrm
logfile.cpython-310.pyc104590644editdlrm
modules.cpython-310.pyc254690644editdlrm
monkey.cpython-310.pyc23150644editdlrm
procutils.cpython-310.pyc13890644editdlrm
randbytes.cpython-310.pyc37350644editdlrm
rebuild.cpython-310.pyc55780644editdlrm
reflect.cpython-310.pyc191270644editdlrm
release.cpython-310.pyc15250644editdlrm
roots.cpython-310.pyc89330644editdlrm
runtime.cpython-310.pyc56170644editdlrm
sendmsg.cpython-310.pyc25800644editdlrm
shortcut.cpython-310.pyc24640644editdlrm
syslog.cpython-310.pyc33680644editdlrm
systemd.cpython-310.pyc30510644editdlrm
text.cpython-310.pyc42690644editdlrm
threadable.cpython-310.pyc35200644editdlrm
threadpool.cpython-310.pyc105020644editdlrm
url.cpython-310.pyc2790644editdlrm
urlpath.cpython-310.pyc92820644editdlrm
usage.cpython-310.pyc286350644editdlrm
util.cpython-310.pyc279390644editdlrm
versions.cpython-310.pyc3560644editdlrm
win32.cpython-310.pyc48410644editdlrm
zippath.cpython-310.pyc91460644editdlrm
zipstream.cpython-310.pyc88260644editdlrm
_appdirs.cpython-310.pyc8620644editdlrm
_inotify.cpython-310.pyc25800644editdlrm
_pydoctor.cpython-310.pyc57500644editdlrm
_release.cpython-310.pyc181330644editdlrm
_shellcomp.cpython-310.pyc188550644editdlrm
_textattributes.cpython-310.pyc106420644editdlrm
_tzhelper.cpython-310.pyc33850644editdlrm
_url.cpython-310.pyc2690644editdlrm
__init__.cpython-310.pyc5460644editdlrm
Edit: /usr/lib/python3/dist-packages/twisted/python/__pycache__/rebuild.cpython-310.pyc (5578B)
o b@sUdZddlZddlZddlZddlZddlmZddlmZddlm Z ddl m Z m Z ea GdddZiZe eefed <d d Zd d ZGdddeZddZddZdddZdS)z& *Real* reloading support for Python. N)reload) ModuleType)Dict)logreflectc@s,eZdZdZeZddZddZddZdS) Sensitivez A utility mixin that's sensitive to rebuilds. This is a mixin for classes (usually those which represent collections of callbacks) to make sure that their code is up-to-date before running. cCs|jtk}|SN) lastRebuild)selfynr 8/usr/lib/python3/dist-packages/twisted/python/rebuild.pyneedRebuildUpdate$s zSensitive.needRebuildUpdatecCst|_dSr)timer r r r r rebuildUpToDate(szSensitive.rebuildUpToDatecCsXt|}|tjkr t|S|tjkr%|jdurt|j|jSt|j|jSt d|S)z Get the latest version of an object. This can handle just about anything callable; instances, functions, methods, and classes. Nzwarning returning anObject!) typetypes FunctionTypelatestFunction MethodType__self__getattrim_class__name__rmsg)r anObjecttr r r latestVersionOf+s    zSensitive.latestVersionOfN)r __module__ __qualname____doc__r rrrr r r r rs  r _modDictIDMapcCs,t|j}t|}|dur|St||jS)z/ Get the latest version of a function. N)id __globals__r"getrr)oldFuncdictIDmoduler r r rBs   rcCszt|j}t||j}dd|jD}|jdkr|Szt||_|WSty<t|}||jt|t |j YSw)z, Get the latest version of a class. cSsg|]}t|qSr ) latestClass).0baser r r UszlatestClass..builtins) r namedModulerrr __bases__tuple TypeErrorrdict__dict__)oldClassr(newClassnewBasesctorr r r r)Os     r)c@seZdZdZdS) RebuildErrorzT Exception raised when trying to rebuild a class whereas it's not possible. N)rrr r!r r r r r8dsr8cCst|j|_dS)z, Updates an instance to be current. N)r) __class__rr r r updateInstancejsr:cCsF|dkrtdt|tdt|jd|dt||}|S)z< A getattr method to cause a class to be refreshed. __del__zWithout this, Python segfaults.z(rebuilding stale z instance (z)))AttributeErrorr:rrrqualr9r)r nameresultr r r __injectedgetattr__qs   r@c Cstat|dr|jstd|rtdt|jdddl m }d|_ |j }|t t|<i}i}i}i}|rFtdt|jd |D]@\}} tt| tjrn| j|j urmd || <|rmtjd tjqJt| tr| j|jkrd || <|rtjd tjqJ|||||j} |}|}|}|rtd tdt|jdt|t|rtdt|jd |D]3} t || j| urtdt!"| dq|rtjdtjd| _#| j $t%| _&|j| _q|r ddl'} |D]0} t || j}|| ur&td(t!"| q | )| D]}t |dd| ur9||_*q+q |rQtd tdt|jd d}t+j,D]{\}}|d }||ksj|durlqXt|dstqXt|dr|qXd}|j D]6\}} zt-| Wn t.yYqw| | r|rtjd tjt/| }d }t0|||q|r|s|ddkrtjdtjqXd|_ |rtd tdt|jd|S)zO Reload a module and do as much as possible to replace its references. ALLOW_TWISTED_REBUILDzI am not allowed to be rebuilt.z Rebuilding z...r) componentsTz (scanning z): rAfoz (reload )z (cleaning zWARNING: class z not replaced by reload!xr Nz-WARNING: new-class {} not replaced by reload!r9z (fixing __file__ __bundle__ .Fz Rebuilt )1rr hasattrrB RuntimeErrorrrstrrtwisted.pythonrCALLOW_DUPLICATESr3r"r#items issubclassrrrr$logfilewriteflush isinstancerupdate __contains__keysr linecache clearcacherrr=r/clearr@ __getattr__gcformat get_referrersr9sysmoduleshash Exceptionrsetattr)r(doLogrCd newclassesclasses functionsvalueskv fromOldModuleclazzr_nclassgarmodcountmkmodchangednvr r r rebuild}s                              ry)rA)r!r[rbrrimprrtypingrrPrrr rr"int__annotations__rr)rer8r:r@ryr r r r s$   %