Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 107

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 234

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 235

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 236

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 237

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 238

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 239
U i_h @sdZdZddlZddlZddlmZddlmZddlmZddlm Z dd ej ej gej fej eejejejej eejej efd d d ZdS) zFSupport for running coroutines in parallel with staggered start times.)staggered_raceN)events) exceptions)locks)tasks)loop)coro_fnsdelayrreturnc sp tt|ddggtjtjddfdd d}|zfd}|t krt IdH\}}t |}|D]$}| r|s|r|qqlfWSD] }| qXdS)aRun coroutines with staggered start times and take the first to finish. This method takes an iterable of coroutine functions. The first one is started immediately. From then on, whenever the immediately preceding one fails (raises an exception), or when *delay* seconds has passed, the next coroutine is started. This continues until one of the coroutines complete successfully, in which case all others are cancelled, or until all coroutines fail. The coroutines provided should be well-behaved in the following way: * They should only ``return`` if completed successfully. * They should always raise an exception if they did not complete successfully. In particular, if they handle cancellation, they should probably reraise, like this:: try: # do work except asyncio.CancelledError: # undo partially completed work raise Args: coro_fns: an iterable of coroutine functions, i.e. callables that return a coroutine object when called. Use ``functools.partial`` or lambdas to pass arguments. delay: amount of time, in seconds, between starting coroutines. If ``None``, the coroutines will run sequentially. loop: the event loop to use. Returns: tuple *(winner_result, winner_index, exceptions)* where - *winner_result*: the result of the winning coroutine, or ``None`` if no coroutines won. - *winner_index*: the index of the winning coroutine in ``coro_fns``, or ``None`` if no coroutines won. If the winning coroutine may return None on success, *winner_index* can be used to definitively determine whether any coroutine won. - *exceptions*: list of exceptions returned by the coroutines. ``len(exceptions)`` is equal to the number of coroutines actually started, and the order is the same as in ``coro_fns``. The winning coroutine's entry is ``None``. N)previous_failedr c sN|dk r6ttjt|IdHW5QRXzt\}}Wntk r\YdSXt } |} |t |dkst dt |dkstz|IdH}WnLttfk rYnptk r }z||<|W5d}~XYn>Xdkst||tD]\}}||kr,|q,dS)Nr) contextlibsuppressexceptions_mod TimeoutErrorrwait_forwaitnext StopIterationrEvent create_taskappendlenAssertionError SystemExitKeyboardInterrupt BaseExceptionset enumeratecancel) r Z this_indexZcoro_fnZ this_failedZ next_taskresulteitr Z enum_coro_fnsrr run_one_coroZ running_tasksZ winner_indexZ winner_result0/opt/python38/lib/python3.8/asyncio/staggered.pyr&Rs4    z$staggered_race..run_one_coror)rZget_running_looprtypingOptionalrrrrr rrrdone cancelled exception) r r rZ first_taskr$Z done_countr+_dr'r%r(rs,=  0   r)__doc____all__rr)rrrrrIterableCallable Awaitabler*floatZAbstractEventLoopZTupleZAnyintZList Exceptionrr'r'r'r(s&