Uname: Linux web3.us.cloudlogin.co 5.10.226-xeon-hst #2 SMP Fri Sep 13 12:28:44 UTC 2024 x86_64
Software: Apache
PHP version: 8.1.31 [ PHP INFO ] PHP os: Linux
Server Ip: 162.210.96.117
Your Ip: 18.118.195.236
User: edustar (269686) | Group: tty (888)
Safe Mode: OFF
Disable Function:
NONE

name : test_threading.pyo
�
@��cc@sLddlZddlmZmZddlmZddlZddlZddlZej	j
d�Zej	j
d�Zddl
Z
ddlZddlZddlZddlZyddlZWnek
r�eZnXddlmZdefd��YZd	ejfd
��YZdejfd��YZd
efd��YZdefd��YZdefd��YZdejfd��YZdej fd��YZ dej!fd��YZ!dej fd��YZ"dej#fd��YZ#dej$fd��YZ$dej%fd ��YZ%d!�Z&e'd"krHe&�ndS(#i����N(tverbosetcpython_only(tassert_python_oktthreadt	threading(t
lock_teststCountercBs,eZd�Zd�Zd�Zd�ZRS(cCs
d|_dS(Ni(tvalue(tself((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt__init__scCs|jd7_dS(Ni(R(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytincscCs|jd8_dS(Ni(R(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytdecscCs|jS(N(R(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytget s(t__name__t
__module__R	R
RR(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRs			t
TestThreadcBseZd�Zd�ZRS(cCs>tjj|d|�||_||_||_||_dS(Ntname(RtThreadR	ttestcasetsematmutextnrunning(RRRRRR((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR	$s
			cCstj�d}tr/d|j|dfGHn|j��|j�I|jj�trk|jj�GdGHn|jj	|jj�d�WdQXt
j|�tr�dG|jGdGHn|j�R|jj�|jj
|jj�d�tr
d	|j|jj�fGHnWdQXWdQXdS(
Ng��@stask %s will run for %.1f usecg��.Astasks are runningittasktdoneis$%s is finished. %d tasks are running(trandomRRRRRR
RRtassertLessEqualttimetsleepRtassertGreaterEqual(Rtdelay((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytrun+s&


"


(R
RR	R(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR#s	tBaseTestCasecBseZd�Zd�ZRS(cCstjj�|_dS(N(ttestttest_supporttthreading_setupt_threads(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytsetUpDscCs$tjj|j�tjj�dS(N(R R!tthreading_cleanupR#t
reap_children(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttearDownGs(R
RR$R'(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRCs	tThreadTestscBs�eZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
ejeed�d
�d��Zejeed�d�d��Zd�ZRS(cCsCd}tjdd�}tj�}t�}g}xmt|�D]_}td|||||�}|j|�|j|j�|j	t
|�d�|j�q@Wtr�dGHnxg|D]_}|j
|�|j|j��|j|jd�|j|j�|j	t
|�d�q�Wtr)d	GHn|j|j�d�dS(
Ni
Ris<thread %d>s^<TestThread\(.*, initial\)>$s!waiting for all tasks to completeis^<TestThread\(.*, \w+ -?\d+\)>$sall tasks done(RtBoundedSemaphoretRLockRtrangeRtappendtassertIsNonetidenttassertRegexpMatchestreprtstartRtjointassertFalsetis_alivetassertNotEqualtassertIsNotNonetassertEqualR(RtNUMTASKSRRt
numrunningtthreadstitt((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_various_opsPs,	


csw|jtj�j���fd�}tj��g�tj|d��j�|j�d�tj�d=dS(Ncs$�jtj�j��j�dS(N(R,Rt
currentThreadR.tset((RR.(s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytfrsi((	R6RR>R.tEventRtstart_new_threadtwaitt_active(RR@((RR.s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt"test_ident_of_no_threading_threadsos
cCs^trdGHnytjd�Wn!tjk
rB|jd�nX|j�tjd�dS(Nswith 256kB thread stack size...is4platform does not support changing thread stack sizei(RRt
stack_sizeRterrortskipTestR=(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_various_ops_small_stack~s
cCs^trdGHnytjd�Wn!tjk
rB|jd�nX|j�tjd�dS(Nswith 1MB thread stack size...is4platform does not support changing thread stack sizei(RRRFRRGRHR=(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_various_ops_large_stack�s
cCsyd�}tj�}|j�tj||f�}|j�|j|tj�|jtj|tj�tj|=dS(NcSstj�|j�dS(N(Rtcurrent_threadtrelease(R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR@�s
(	RtLocktacquireRRBtassertInRDtassertIsInstancet_DummyThread(RR@Rttid((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_foreign_thread�s	

c	sQyddl}Wntk
r0|jd�nX|jj}dtfd��Y�|j��}tj�}y)||j	|�|�}x
t
r�q�WWn�k
r�nX|jd�y|j|d�Wnt
k
r�nXtj��tj��dtjf���fd��Y}|�}t
|_|j�trGd	GHntrUd
GHn||j	d�|�}|j|d�tr�dGHn�j�}|j|�tr�d
GHn|j|j�tr�dGHn||j	|j�|�}|j|d�tr	dGHn�jdd�|j|j�tr7dGHn|jrM|j�ndS(Ni����srequires ctypestAsyncExccBseZRS((R
R(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRT�ssAsyncExc not raiseditWorkercseZ���fd�ZRS(csktj�|_t|_y(x!tr>�j�tjd�qWWn$�k
rft|_�j�nXdS(Ng�������?(	Rt	get_identtidtFalsetfinishedtTrueR?RR(R(RTtworker_saw_exceptiontworker_started(s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�s		

	(R
RR((RTR[R\(s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRU�ss    started worker threads     trying nonsensical thread idis,    waiting for worker thread to get starteds"    verifying worker hasn't exiteds2    attempting to raise asynch exception in workers5    waiting for worker to say it caught the exceptionttimeouti
s    all OK -- joining worker(tctypestImportErrorRHt	pythonapitPyThreadState_SetAsyncExct	Exceptiont	py_objectRRVtc_longRZtfailR7tUnboundLocalErrorRRARtdaemonR1RRCt
assertTrueR3RYRWR2(	RR^t
set_async_exct	exceptionRRtresultRUR<tret((RTR[R\s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_PyThreadState_SetAsyncExc�sd
	


%
		

	cCstd�}tj}|t_zHtjdd��}|jtj|j�|j|tjkd�Wd|t_XdS(NcWstj��dS(N(RRG(targs((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytfail_new_threadsttargetcSsdS(N(tNone(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt<lambda>ts:Failed to cleanup _limbo map on failure of Thread.start().(	Rt_start_new_threadRtassertRaisesRRGR1R3t_limbo(RRoRtR<((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_limbo_cleanup�s			cCs`yddl}Wntk
r0|jd�nXtjtjddg�}|j|d�dS(Ni����srequires ctypess-csKif 1:
            import ctypes, sys, time, thread

            # This lock is used as a simple event variable.
            ready = thread.allocate_lock()
            ready.acquire()

            # Module globals are cleared before __del__ is run
            # So we save the functions in class dict
            class C:
                ensure = ctypes.pythonapi.PyGILState_Ensure
                release = ctypes.pythonapi.PyGILState_Release
                def __del__(self):
                    state = self.ensure()
                    self.release(state)

            def waitingThread():
                x = C()
                ready.release()
                time.sleep(100)

            thread.start_new_thread(waitingThread, ())
            ready.acquire()  # Be sure the other thread is waiting.
            sys.exit(42)
            i*(R^R_RHt
subprocesstcalltsyst
executableR7(RR^trc((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_finalize_runnning_thread
s
cCs�tjtjddgdtjdtj�}|j|jj�|j|jj�|j	�\}}|j
}|j|dkd�|j|dkdt
|��dS(	Ns-csOif 1:
            import sys, threading

            # A deadlock-killer, to prevent the
            # testsuite to hang forever
            def killer():
                import os, time
                time.sleep(2)
                print 'program blocked; aborting'
                os._exit(2)
            t = threading.Thread(target=killer)
            t.daemon = True
            t.start()

            # This is the trace function
            def func(frame, event, arg):
                threading.current_thread()
                return func

            sys.settrace(func)
            tstdouttstderrisinterpreted was blockedisUnexpected error: (RxtPopenRzR{tPIPEt
addCleanupR~tcloseRtcommunicatet
returncodeR3RhR0(RtpR~RR|((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_finalize_with_trace1s			cCs�tjtjddgdtjdtj�}|j|jj�|j|jj�|j	�\}}|j
|j�d�tj
dd|tj�j�}|j
|d�dS(Ns-cs�if 1:
                import threading
                from time import sleep

                def child():
                    sleep(1)
                    # As a non-daemon thread we SHOULD wake up and nothing
                    # should be torn down yet
                    print "Woke up, sleep function is:", sleep

                threading.Thread(target=child).start()
                raise SystemExit
            R~Rs5Woke up, sleep function is: <built-in function sleep>s
^\[\d+ refs\]Rs(RxR�RzR{R�R�R~R�RR�R7tstriptretsubt	MULTILINE(RR�R~R((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_join_nondaemon_on_shutdownSs		!cCs�tj}tj�}z~xwtdd�D]f}tj|d�tjdd��}|j�|j�|�}|j	||d||f�q(WWdtj|�XdS(NiidiRpcSsdS(N(Rq(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRrwRss&#1703448 triggered after %d trials: %s(
Rt	enumerateRztgetcheckintervaltxrangetsetcheckintervalRR1R2tassertNotIn(Rtenumtold_intervalR;R<tl((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_enumerate_after_joinms	

	cCs�dtfd��Y}|dt�}tj|�}|jj�~|jd|�ddtj	|���|dt
�}tj|�}|jj�~|jd|�ddtj	|���dS(NtRunSelfFunctioncBseZd�Zd�ZRS(c	SsH||_tjd|jd|fdi|d6�|_|jj�dS(NRpRntkwargstyet_another(tshould_raiseRRt_runRR1(RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR	�s
		cSs|jrt�ndS(N(R�t
SystemExit(Rt	other_refR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��s	(R
RR	R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��s		R�tmsgs%d references still around(tobjectRXtweakreftrefRR2R7RqRztgetrefcountRZ(RR�t
cyclic_objecttweak_cyclic_objecttraising_cyclic_objecttweak_raising_cyclic_object((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_no_refcycle_through_target�s

tforkstest needs fork()cCsBd}td|�\}}}|j|d�|j|d�dS(Ns�if 1:
            import thread, threading, os, time

            def background_thread(evt):
                # Creates and registers the _DummyThread instance
                threading.current_thread()
                evt.set()
                time.sleep(10)

            evt = threading.Event()
            thread.start_new_thread(background_thread, (evt,))
            evt.wait()
            assert threading.active_count() == 2, threading.active_count()
            if os.fork() == 0:
                assert threading.active_count() == 1, threading.active_count()
                os._exit(0)
            else:
                os.wait()
        s-cRs(RR7(Rtcodet_toutterr((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_dummy_thread_after_fork�ssneeds os.fork()cCs�tj�}tjd�z�x�td�D]�}tjdd��}|j�tj�}|dkr�tj	|j
�r~dnd�q)|j�tj|d�\}}|j
d|�q)WWdtj|�XdS(Ni
iRpcSsdS(N(Rq(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyRr�Rsii(RzR�R�R+RRR1tosR�t_exitR4R2twaitpidR7(RR�R;R<tpidtstatus((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_is_alive_after_fork�s

"
cCsxtdd�D]�}tj|�}gt|�D]}tjd|j�^q2}x|D]}|j�qZWx|D]}|j�quWgt|�D]}tjd|j�^q�}x|D]}|j�q�Wx|D]}|j�q�W|jt	|j�qWdS(Nii
Rp(
R+RR)RRNR1R2RLRut
ValueError(RtlimittbsR�R:R<((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_BoundedSemaphore_limit�s+

+

(R
RR=RERIRJRSRmRwR}R�R�R�R�tunittestt
skipUnlessthasattrR�R�R�R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR(Ls				
		X		$	"			$$tThreadJoinOnShutdowncBs�eZdZd�Zd�Zejeed�d�ej	e
jekd	�d
���Zejeed�d�ej	e
jekd	�d���Z
d�Zejeed�d�ej	e
jekd	�d
���Zejeed�d�ej	e
jekd	�d���Zejeed�d�ej	e
jekd	�d���Zeej	edkd�d���ZRS(tfreebsd4tfreebsd5tfreebsd6tnetbsd5tos2emxcCs�d|}tjtjd|gdtj�}|j�}|jj�jdd�}|jj	�|j
|d�|j|dkd�|j|d	kd
�dS(Ns�if 1:
            import sys, os, time, threading

            # a thread, which waits for the main program to terminate
            def joiningfunc(mainthread):
                mainthread.join()
                print 'end of thread'
        
s-cR~s
Rssend of main
end of thread
isinterpreter was blockedisUnexpected error(
RxR�RzR{R�RCR~treadtreplaceR�R7R3Rh(RtscriptR�R|tdata((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt
_run_and_join�s
$
cCsd}|j|�dS(Ns�if 1:
            import os
            t = threading.Thread(target=joiningfunc,
                                 args=(threading.current_thread(),))
            t.start()
            time.sleep(0.1)
            print 'end of main'
            (R�(RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_1_join_on_shutdown�s	R�sneeds os.fork()sdue to known OS bugcCsd}|j|�dS(NsFif 1:
            childpid = os.fork()
            if childpid != 0:
                os.waitpid(childpid, 0)
                sys.exit(0)

            t = threading.Thread(target=joiningfunc,
                                 args=(threading.current_thread(),))
            t.start()
            print 'end of main'
            (R�(RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_2_join_in_forked_processscCsd}|j|�dS(Ns9if 1:
            main_thread = threading.current_thread()
            def worker():
                childpid = os.fork()
                if childpid != 0:
                    os.waitpid(childpid, 0)
                    sys.exit(0)

                t = threading.Thread(target=joiningfunc,
                                     args=(main_thread,))
                print 'end of main'
                t.start()
                t.join() # Should not block: main_thread is already stopped

            w = threading.Thread(target=worker)
            w.start()
            (R�(RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt!test_3_join_in_forked_from_threadscCsxtjtjd|gdtj�}|j�}|jj�j�j	dd�}|j
|dd�|j
||�dS(Ns-cR~s
RsisUnexpected error(RxR�RzR{R�RCR~R�tdecodeR�R7(RR�texpected_outputR�R|R�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytassertScriptHasOutput4s!cCsd}|j|d�dS(NsDif 1:
            import os, time, threading

            finish_join = False
            start_fork = False

            def worker():
                # Wait until this thread's lock is acquired before forking to
                # create the deadlock.
                global finish_join
                while not start_fork:
                    time.sleep(0.01)
                # LOCK HELD: Main thread holds lock across this call.
                childpid = os.fork()
                finish_join = True
                if childpid != 0:
                    # Parent process just waits for child.
                    os.waitpid(childpid, 0)
                # Child process should just return.

            w = threading.Thread(target=worker)

            # Stub out the private condition variable's lock acquire method.
            # This acquires the lock and then waits until the child has forked
            # before returning, which will release the lock soon after.  If
            # someone else tries to fix this test case by acquiring this lock
            # before forking instead of resetting it, the test case will
            # deadlock when it shouldn't.
            condition = w._block
            orig_acquire = condition.acquire
            call_count_lock = threading.Lock()
            call_count = 0
            def my_acquire():
                global call_count
                global start_fork
                orig_acquire()  # LOCK ACQUIRED HERE
                start_fork = True
                if call_count == 0:
                    while not finish_join:
                        time.sleep(0.01)  # WORKER THREAD FORKS HERE
                with call_count_lock:
                    call_count += 1
            condition.acquire = my_acquire

            w.start()
            w.join()
            print('end of main')
            send of main
(R�(RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt+test_4_joining_across_fork_in_worker_thread<sFcCs d}d}|j||�dS(Nsif True:
            import os, time, threading

            start_fork = False

            def worker():
                # Wait until the main thread has attempted to join this thread
                # before continuing.
                while not start_fork:
                    time.sleep(0.01)
                childpid = os.fork()
                if childpid != 0:
                    # Parent process just waits for child.
                    (cpid, rc) = os.waitpid(childpid, 0)
                    assert cpid == childpid
                    assert rc == 0
                    print('end of worker thread')
                else:
                    # Child process should just return.
                    pass

            w = threading.Thread(target=worker)

            # Stub out the private condition variable's _release_save method.
            # This releases the condition's lock and flips the global that
            # causes the worker to fork.  At this point, the problematic waiter
            # lock has been acquired once by the waiter and has been put onto
            # the waiters list.
            condition = w._block
            orig_release_save = condition._release_save
            def my_release_save():
                global start_fork
                orig_release_save()
                # Waiter lock held here, condition lock released.
                start_fork = True
            condition._release_save = my_release_save

            w.start()
            w.join()
            print('end of main thread')
            s(end of worker thread
end of main thread
(R�(RR�toutput((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt(test_5_clear_waiter_locks_to_avoid_crash�s6cCsnd�}g}x=td�D]/}tjd|�}|j|�|j�qWx|D]}|j�qVWdS(NcSs<tj�}|dkr+tj|d�n
tjd�dS(Ni(R�R�R�R�(R�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pytdo_fork_and_wait�siRp(R+RRR,R1R2(RR�R:R;R<((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_reinit_tls_after_fork�s		

sneed _testcapi modulecs��fd��d����fd��d�_tj�}tj��z<tj��tj��xtd�D]
}��qvWWdtj|�XdS(Ncs�S(N((tframeteventtarg(t
noop_trace(s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��scssx	dVqWdS(Nt	generator((((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��scs+�jdkr���_nt�j�S(N(tgenRqtnext((tcallbackR�(s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��si(	RqR�RztgettracetsettraceRt	_testcapitcall_in_temporary_c_threadR+(Rt	old_traceR ((R�R�R�s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_frame_tstate_tracing�s			


(R�R�R�R�R�N(R
Rtplatforms_to_skipR�R�R�R�R�R�tskipIfRztplatformR�R�R�R�R�R�RR�RqR�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR��s"		
''	'H'9'tThreadingExceptionTestscBsGeZd�Zd�Zd�Zd�Zd�Zd�Zd�ZRS(cCs-tj�}|j�|jt|j�dS(N(RRR1RutRuntimeError(RR((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_start_thread_agains
cCs#tj�}|jt|j�dS(N(RRKRuR�R2(RRK((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_joining_current_threadscCs#tj�}|jt|j�dS(N(RRRuR�R2(RR((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_joining_inactive_threadscCs3tj�}|j�|jtt|dt�dS(NRg(RRR1RuR�tsetattrRZ(RR((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_daemonize_active_threads
cCsrd}td|�\}}}|j|d�|jd|�|jd|�|jd|�|jd|�dS(Ns�if 1:
            import threading
            import time

            running = False
            def run():
                global running
                running = True
                while running:
                    time.sleep(0.01)
                1.0/0.0
            t = threading.Thread(target=run)
            t.start()
            while not running:
                time.sleep(0.01)
            running = False
            t.join()
            s-cRssException in threads"Traceback (most recent call last):tZeroDivisionErrorsUnhandled exception(RR7ROR�(RR�R|R�R�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_print_exceptionscCsrd}td|�\}}}|j|d�|jd|�|jd|�|jd|�|jd|�dS(Ns�if 1:
            import sys
            import threading
            import time

            running = False
            def run():
                global running
                running = True
                while running:
                    time.sleep(0.01)
                1.0/0.0
            t = threading.Thread(target=run)
            t.start()
            while not running:
                time.sleep(0.01)
            sys.stderr = None
            running = False
            t.join()
            s-cRssException in threads"Traceback (most recent call last):R�sUnhandled exception(RR7ROR�(RR�R|R�R�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt%test_print_exception_stderr_is_none_1/scCsBd}td|�\}}}|j|d�|jd|�dS(Ns�if 1:
            import sys
            import threading
            import time

            running = False
            def run():
                global running
                running = True
                while running:
                    time.sleep(0.01)
                1.0/0.0
            sys.stderr = None
            t = threading.Thread(target=run)
            t.start()
            while not running:
                time.sleep(0.01)
            running = False
            t.join()
            s-cRssUnhandled exception(RR7R�(RR�R|R�R�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt%test_print_exception_stderr_is_none_2Ks(	R
RR�R�R�R�R�R�R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�s						t	LockTestscBseZeej�ZRS((R
RtstaticmethodRRMtlocktype(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�est
RLockTestscBseZeej�ZRS((R
RR�RR*R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�hst
EventTestscBseZeej�ZRS((R
RR�RRAt	eventtype(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�kstConditionAsRLockTestscBseZeej�ZRS((R
RR�Rt	ConditionR�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�nstConditionTestscBseZeej�ZRS((R
RR�RR�tcondtype(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�rstSemaphoreTestscBseZeej�ZRS((R
RR�Rt	Semaphoretsemtype(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�ustBoundedSemaphoreTestscBs;eZeej�Zejej	dkd�d��Z
RS(tdarwinstest macosx problemcCs�d}d}tjtjd|gdtj�}|j�\}}|j�jdd�}|j|j	dd�|j||�dS(	Ns}if True:
            import threading

            def recurse():
                return recurse()

            def outer():
                try:
                    recurse()
                except RuntimeError:
                    pass

            w = threading.Thread(target=outer)
            w.start()
            w.join()
            print('end of main thread')
            send of main thread
s-cR~s
RsisUnexpected error(
RxR�RzR{R�R�R�R�R7R�(RR�R�R�R~RR�((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyttest_recursion_limit{s(R
RR�RR)R�R�R�RzR�R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyR�xscCs/tjjttttttt	t
tt�
dS(N(
R R!trun_unittestR�R�R�R�R�R�R�R(R�R�(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt	test_main�st__main__((ttest.test_supportR RRttest.script_helperRRR�RzR!t
import_moduleRRRR�R�R�RxR�R_RqRR�RRRtTestCaseRR(R�R�R�R�R�R�R�R�R�R�R
(((s:/usr/local/python-2.7/lib/python2.7/test/test_threading.pyt<module>sF


 	���e#		
© 2025 GrazzMean