관리-도구
편집 파일: boto3.cpython-37.pyc
B T a1 � @ s� d dl mZ d dlmZ d dlmZmZ d dlmZ d dl m Z d dlmZ er�d dl mZ d dl mZ d d l mZ d d l mZ y4d dlmZ d dlmZ d d lmZ d dlmZ W n ek r� ed��Y nX G dd� de�Zdd� Zdd� Zdd� ZdS )� )�absolute_import)�Hub)�Integration�DidNotEnable)�Span)�partial)�MYPY)�Any)�Dict)�Optional)�Type)�__version__)� BaseClient)� StreamingBody)� AWSRequestzbotocore is not installedc @ s e Zd ZdZedd� �ZdS )�Boto3IntegrationZboto3c st y t ttt�d�d d� ��} W n& ttfk rF td�t���Y nX | dk rXtd��t j � � fdd�}|t _ d S )N�.� zUnparsable botocore version: {})� � z#Botocore 1.12 or newer is required.c sX � | f|�|� | j }|jj�� }|j�dtt|d�� |j�dt� |j�dt � d S )Nzrequest-created)� service_idz after-callzafter-call-error) �metaZ service_modelr Z hyphenize�events�registerr �_sentry_request_created�_sentry_after_call�_sentry_after_call_error)�self�args�kwargsr r )� orig_init� �N/opt/alt/python37/lib/python3.7/site-packages/sentry_sdk/integrations/boto3.py�sentry_patched_init) s z8Boto3Integration.setup_once.<locals>.sentry_patched_init)�tuple�map�int�BOTOCORE_VERSION�split� ValueError� TypeErrorr �formatr �__init__)�versionr# r! )r r"