Uname : Linux premium36.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
Soft : LiteSpeed
Ip : 198.54.115.237
Port : 443
~
/
opt
/
hc_python
/
lib64
/
python3.12
/
site-packages
/
sentry_sdk
/
integrations
/
__pycache__
[ HOME ]
Exec
Submit
File Name : asyncio.cpython-312.pyc
� w�/i � � � d dl Z d dlZd dlZd dlmZ d dlmZmZ d dlm Z m Z mZ d dlZd dl mZ d dlmZmZ er%d dlmZmZmZ d d lmZ d d lmZ ededef � � Zd� Zd� Zd� Zd� Z G d� de� Zy# e$ r ed� �w xY w)� N)�OP)�Integration�DidNotEnable)�event_from_exception�logger�reraise)�Taskzasyncio not available)�cast� TYPE_CHECKING)�Any�Callable�TypeVar)� Coroutine)�ExcInfo�T.)�boundc �B � t | dd � xs t | dd � xs dS )N�__qualname__�__name__zcoroutine without __name__)�getattr)�coros �N/opt/hc_python/lib/python3.12/site-packages/sentry_sdk/integrations/asyncio.py�get_namer s. � � ��n�d�+� (��4��T�*� (�'�� c �P � t j t j | dd�� S )N)r r � )�wrapped�assigned�updated)� functools�partial�update_wrapper)r s r �_wrap_coroutiner# # s) � � ���� � ��-�� � r c �� �� d � t j � } | j � ��fd�}| j |� y # t $ r t j d� Y y w xY w)Nc �" ��� t �� �fd�� }d }�r �| |� fi |��}|�,t |� fd| i|��}|j r |j d= t d|� j t �� � d�� |S # t $ r Y |S w xY w)Nc � � �K � d } t j � 5 t j t j t �� t j �� 5 �� d { ��� } d d d � d d d � | S 7 �# t $ r}|d �d }~wt $ r t t � � Y �>w xY w# 1 sw Y �CxY w# 1 sw Y | S xY w�w)N)�op�name�origin)� sentry_sdk�isolation_scope� start_spanr �FUNCTIONr �AsyncioIntegrationr) �StopAsyncIteration� Exceptionr �_capture_exception)�result�er s �r �_task_with_sentry_span_creationzTpatch_asyncio.<locals>._sentry_task_factory.<locals>._task_with_sentry_span_creation8 s� �� �� � ���/�/�1�#�.�.��;�;�%�d�^�1�8�8�� ;�+/�Z�F� � 2� � � &0��1� .�"#��-��(� ;�#�%7�%9�:�;��� �� 2� � �sp �B?�>B2�B&�A8�A6� A8�$B2�, B?�6A8�8 B#�B�B#� B&�"B#�#B&�&B/ �+B2�2B<�7B?�loop���zasyncio.Task[Any]z (Sentry-wrapped))r# r �_source_tracebackr �set_namer �AttributeError)r5 r �kwargsr4 �task�orig_task_factorys ` �r �_sentry_task_factoryz+patch_asyncio.<locals>._sentry_task_factory5 s� �� � �T� "� � #� �&