ó
    F j;  ã                  óÜ   • S SK Jr  S SKrS SKJr  S SKJr  S SKJr  SSK	J
r
Jr  SS	KJr   " S
 S\\   5      r\" 5       r " S S5      r\ S     SS jj5       rSSS jjrSS jrSS jrg)é    )ÚannotationsN)Ú	Generator)Úcontextmanager)ÚTracebackTypeé   )Ú	TaskGroupÚ
TaskStatusé   )Úget_async_backendc                  ó"   • \ rS rSrSSS jjrSrg)Ú_IgnoredTaskStatusé   Nc                ó   • g ©N© ©ÚselfÚvalues     Ú<c:\Py\emelo-reg\venv\Lib\site-packages\anyio/_core/_tasks.pyÚstartedÚ_IgnoredTaskStatus.started   s   € Øó    r   r   )r   ÚobjectÚreturnÚNone)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__r   Ú__static_attributes__r   r   r   r   r      s   † ÷ñ r   r   c                  ó  • \ rS rSrSr\R                  SS.     SS jjrSSS jjr\	SS j5       r
\
R                  SS	 j5       r
\	SS
 j5       r\	SS j5       r\	SS j5       r\R                  SS j5       rSS jr        SS jrSrg)ÚCancelScopeé   aH  
Wraps a unit of work that can be made separately cancellable.

:param deadline: The time (clock value) when this scope is cancelled automatically
:param shield: ``True`` to shield the cancel scope from external cancellation
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread
F©ÚdeadlineÚshieldc               ó0   • [        5       R                  X!S9$ )N)r&   r%   )r   Úcreate_cancel_scope)Úclsr%   r&   s      r   Ú__new__ÚCancelScope.__new__   s   € ô !Ó"×6Ñ6¸fÐ6ÐXÐXr   Nc                ó   • [         e)zf
Cancel this scope immediately.

:param reason: a message describing the reason for the cancellation

©ÚNotImplementedError)r   Úreasons     r   ÚcancelÚCancelScope.cancel#   s
   € ô "Ð!r   c                ó   • [         e)z{
The time (clock value) when this scope is cancelled automatically.

Will be ``float('inf')`` if no timeout has been set.

r-   ©r   s    r   r%   ÚCancelScope.deadline,   ó
   € ô "Ð!r   c                ó   • [         er   r-   r   s     r   r%   r4   6   ó   € ä!Ð!r   c                ó   • [         e)z+``True`` if :meth:`cancel` has been called.r-   r3   s    r   Úcancel_calledÚCancelScope.cancel_called:   s
   € ô "Ð!r   c                ó   • [         e)aO  
``True`` if this scope suppressed a cancellation exception it itself raised.

This is typically used to check if any work was interrupted, or to see if the
scope was cancelled due to its deadline being reached. The value will, however,
only be ``True`` if the cancellation was triggered by the scope itself (and not
an outer scope).

r-   r3   s    r   Úcancelled_caughtÚCancelScope.cancelled_caught?   s
   € ô "Ð!r   c                ó   • [         e)z
``True`` if this scope is shielded from external cancellation.

While a scope is shielded, it will not receive cancellations from outside.

r-   r3   s    r   r&   ÚCancelScope.shieldL   r5   r   c                ó   • [         er   r-   r   s     r   r&   r?   V   r7   r   c                ó   • [         er   r-   r3   s    r   Ú	__enter__ÚCancelScope.__enter__Z   s   € Ü!Ð!r   c                ó   • [         er   r-   )r   Úexc_typeÚexc_valÚexc_tbs       r   Ú__exit__ÚCancelScope.__exit__]   s
   € ô "Ð!r   r   )r%   Úfloatr&   Úboolr   r"   r   )r/   z
str | Noner   r   ©r   rJ   )r   rJ   r   r   )r   rK   )r   rK   r   r   )r   r"   )rE   ztype[BaseException] | NonerF   zBaseException | NonerG   zTracebackType | Noner   rK   )r   r   r   r   Ú__doc__ÚmathÚinfr*   r0   Úpropertyr%   Úsetterr9   r<   r&   rB   rH   r    r   r   r   r"   r"      sè   † ñð #'§(¡(¸5ñYØðYØ48ðYà	õYö
"ð ó"ó ð"ð ‡__ó"ó ð"ð ó"ó ð"ð ó
"ó ð
"ð ó"ó ð"ð ‡]]ó"ó ð"ô"ð"à,ð"ð &ð"ð %ð	"ð
 
÷"r   r"   c              #  ó2  #   • [        5       R                  nU b
  U" 5       U -   O[        R                  n[        5       R	                  X1S9 nUv •  SSS5        WR
                  (       a  U" 5       UR                  :¼  a  [        egg! , (       d  f       N<= f7f)a  
Create a context manager which raises a :class:`TimeoutError` if does not finish in
time.

:param delay: maximum allowed time (in seconds) before raising the exception, or
    ``None`` to disable the timeout
:param shield: ``True`` to shield the cancel scope from external cancellation
:return: a context manager that yields a cancel scope
:rtype: :class:`~typing.ContextManager`\[:class:`~anyio.CancelScope`\]
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread

Nr$   )r   Úcurrent_timerN   rO   r(   r<   r%   ÚTimeoutError)Údelayr&   rS   r%   Úcancel_scopes        r   Ú
fail_afterrW   f   s†   é € ô" %Ó&×3Ñ3€LØ+0Ñ+<‘“ Ò&Ä$Ç(Á(€HÜ	Ó	×	0Ñ	0Øð 
1ñ 
à	ØÒ÷
ð
 ×$×$©«¸<×;PÑ;PÓ)PÜÐð *QÐ$÷
õ 
üs   ‚A	BÁBÁ6BÂ
BÂBc                óŒ   • U b  [        5       R                  5       U -   O[        R                  n[        5       R	                  X!S9$ )a“  
Create a cancel scope with a deadline that expires after the given delay.

:param delay: maximum allowed time (in seconds) before exiting the context block, or
    ``None`` to disable the timeout
:param shield: ``True`` to shield the cancel scope from external cancellation
:return: a cancel scope
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread

r$   )r   rS   rN   rO   r(   )rU   r&   r%   s      r   Úmove_on_afterrY   ‚   sB   € ð 9>Ñ8IÔ	Ó	×	)Ñ	)Ó	+¨eÒ	3ÌtÏxÉxð ô Ó×2Ñ2¸HÐ2ÐTÐTr   c                 ó2   • [        5       R                  5       $ )aŠ  
Return the nearest deadline among all the cancel scopes effective for the current
task.

:return: a clock value from the event loop's internal clock (or ``float('inf')`` if
    there is no deadline in effect, or ``float('-inf')`` if the current scope has
    been cancelled)
:rtype: float
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread

)r   Úcurrent_effective_deadliner   r   r   r[   r[   ”   s   € ô Ó×9Ñ9Ó;Ð;r   c                 ó2   • [        5       R                  5       $ )z•
Create a task group.

:return: a task group
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread

)r   Úcreate_task_groupr   r   r   r]   r]   ¤   s   € ô Ó×0Ñ0Ó2Ð2r   )F)rU   úfloat | Noner&   rK   r   z"Generator[CancelScope, None, None])rU   r^   r&   rK   r   r"   rL   )r   r   )Ú
__future__r   rN   Úcollections.abcr   Ú
contextlibr   Útypesr   Ú
abc._tasksr   r	   Ú
_eventloopr   r   r   ÚTASK_STATUS_IGNOREDr"   rW   rY   r[   r]   r   r   r   Ú<module>rf      s‚   ðÝ "ã Ý %Ý %Ý ç .Ý )ô˜ FÑ+ô ñ
 )Ó*Ð ÷O"ñ O"ðd à(-ðØðØ!%ðà'ôó ðö6Uô$<õ 	3r   