ÿØÿâ MSV FM

MSV FM

Path : /opt/alt/python27/lib64/python2.7/multiprocessing/
File Upload :
Current < : //opt/alt/python27/lib64/python2.7/multiprocessing/util.pyc

�
�[
bc@s�ddlZddlZddlZddlZddlZddlmZddlmZm	Z	dddddd	d
ddd
ddddgZ
dZdZdZ
dZdZdZdZdaead�Zd�Zd�Zd�Zd�Zdd�Zd�Zej�Zej�Z d �Z!d!�Z"iZ#ej�Z$d
e%fd"��YZ&dd#�Z'd$�Z(ea)eee'e	ed%�Z*ej+e*�de%fd&��YZ,dej-fd'��YZ.dS((i����N(t_args_from_interpreter_flags(tcurrent_processtactive_childrent	sub_debugtdebugtinfotsub_warningt
get_loggert
log_to_stderrtget_temp_dirtregister_after_forkt
is_exitingtFinalizetForkAwareThreadLocktForkAwareLocaltSUBDEBUGt
SUBWARNINGiii
iitmultiprocessings+[%(levelname)s/%(processName)s] %(message)scGs trtjt||�ndS(N(t_loggertlogR(tmsgtargs((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRDscGs trtjt||�ndS(N(RRtDEBUG(RR((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRHscGs trtjt||�ndS(N(RRtINFO(RR((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRLscGs trtjt||�ndS(N(RRR(RR((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRPscCs�ddl}ddl}|j�z�ts�|jt�adt_|jtd�|jt	d�t
|d�r�|jt�|j
t�q�|jjtdif�|jjtdif�nWd|j�XtS(	s0
    Returns logger used by multiprocessing
    i����NiRRt
unregister(((tloggingtatexitt_acquireLockRt	getLoggertLOGGER_NAMEt	propagatetaddLevelNameRRthasattrRt_exit_functiontregistert
_exithandlerstremovetappendt_releaseLock(RR((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRTs
	
 cCsjddl}t�}|jt�}|j�}|j|�|j|�|r`|j|�nta	t
S(sB
    Turn on logging and add a handler which prints to stderr
    i����N(RRt	FormattertDEFAULT_LOGGING_FORMATt
StreamHandlertsetFormattert
addHandlertsetLeveltTruet_log_to_stderrR(tlevelRtloggert	formatterthandler((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRqs	

cCs�t�jdkrwddl}ddl}|jdd�}td|�td|jd|gdd�|t�_nt�jS(Ni����tprefixspymp-screated temp directory %sRtexitpriorityi����(	Rt_tempdirtNonetshutilttempfiletmkdtempRRtrmtree(R7R8ttempdir((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR	�s
cCsqttj��}|j�xN|D]F\\}}}}y||�Wq#tk
rh}td|�q#Xq#WdS(Ns after forker raised exception %s(tlistt_afterfork_registrytitemstsortt	ExceptionR(R>tindextidenttfunctobjte((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt_run_after_forkers�s
cCs#|ttj�t|�|f<dS(N(R=t_afterfork_countertnexttid(RDRC((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR
�scBsGeZdZdddd�Zdd�Zd�Zd�Zd�ZRS(sA
    Class which supports object finalization using weakrefs
    cCs�|dks*t|�ttfks*t�|dk	rNtj||�|_n|dk	s`t�||_||_	|p{i|_
|tj�f|_
tj�|_|t|j
<dS(N(R6ttypetinttlongtAssertionErrortweakreftreft_weakreft	_callbackt_argst_kwargst_finalizer_counterRHt_keytostgetpidt_pidt_finalizer_registry(tselfRDtcallbackRtkwargsR4((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt__init__�s*		cCs�yt|j=Wntk
r+td�n�X|jtj�krTtd�d}n4td|j|j	|j
�|j|j	|j
�}d|_|_|_	|_
|_|SdS(sQ
        Run the callback unless it has already been called or cancelled
        sfinalizer no longer registereds+finalizer ignored because different processs/finalizer calling %s with args %s and kwargs %sN(RYRUtKeyErrorRRXRVRWR6RQRRRSRP(RZtwrtres((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt__call__�s

	%cCsKyt|j=Wntk
r!n&Xd|_|_|_|_|_dS(s3
        Cancel finalization of the object
        N(RYRUR^R6RPRQRRRS(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pytcancel�s

cCs
|jtkS(sS
        Return whether this finalizer is still waiting to invoke callback
        (RURY(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pytstill_active�scCs�y|j�}Wnttfk
r/d}nX|dkr@dSdt|jd|j�}|jr|dt|j�7}n|jr�|dt|j�7}n|j	ddk	r�|dt|j	d�7}n|dS(	Ns<Finalize object, dead>s<Finalize object, callback=%st__name__s, args=s	, kwargs=is, exitprority=t>(
RPtAttributeErrort	TypeErrorR6tgetattrRQRRtstrRSRU(RZRDtx((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt__repr__�s
		(N(	Rdt
__module__t__doc__R6R]RaRbRcRk(((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR�s		cs�tdkrdS�dkr(d�}n�fd�}gtj�D]}||�rD|^qD}|jdt�xV|D]N\}}td|�y|�Wqytk
r�ddl}|j�qyXqyW�dkr�tj	�ndS(s�
    Run all finalizers whose exit priority is not None and at least minpriority

    Finalizers with highest priority are called first; finalizers with
    the same priority will be called in reverse order of creation.
    NcSs|dddk	S(Ni(R6(tp((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt<lambda>tcs&|dddk	o%|dd�kS(Ni(R6(Rn(tminpriority(s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRo
Rptreverses
calling %si����(
RYR6R>R?R-RR@t	tracebackt	print_exctclear(RqtfRjR>tkeyt	finalizerRs((Rqs9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt_run_finalizers�s +

cCstptdkS(s6
    Returns true if the process is shutting down
    N(t_exitingR6(((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR!scCs�|d�|d�|d�|�dk	r�x:|�D]/}|jr7|d|j�|jj�q7q7Wx.|�D] }|d|j�|j�qtWn|d�|�dS(Nsprocess shutting downs2running all "atexit" finalizers with priority >= 0is!calling terminate() for daemon %sscalling join() for process %ss)running the remaining "atexit" finalizers(R6t	_daemonictnamet_popent	terminatetjoin(RRRyRRRn((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR!)s	


	
cBseZd�Zd�ZRS(cCs|j�t|tj�dS(N(t_resetR
R
(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR]Ts
cCs1tj�|_|jj|_|jj|_dS(N(t	threadingtLockt_locktacquiretrelease(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR�Xs(RdRlR]R�(((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR
Ss	cBseZd�Zd�ZRS(cCst|d��dS(NcSs
|jj�S(N(t__dict__Ru(RD((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyRo_Rp(R
(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR]^scCst|�dfS(N((RJ(RZ((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt
__reduce__`s(RdRlR]R�(((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyR]s	(/RVt	itertoolsRNRR�t
subprocessRtmultiprocessing.processRRt__all__tNOTSETRRRRRR(R6RtFalseR.RRRRRRR	tWeakValueDictionaryR=tcountRGRFR
RYRTtobjectRRyRRzR!R"R
tlocalR(((s9/opt/alt/python27/lib64/python2.7/multiprocessing/util.pyt<module>#sT										N'		"

jlklyejr@51.89.254.255: ~ $