관리-도구
편집 파일: __init__.cpython-37.pyc
B ��Y � @ sr d Z ddlmZ ddlZddlZddlZddlmZ ddlm Z ddl mZ e�d�Z dd � ZG d d� de �ZdS )z� raven.contrib.awslambda ~~~~~~~~~~~~~~~~~~~~ Raven wrapper for AWS Lambda handlers. :copyright: (c) 2010-2012 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. � )�absolute_importN)�FunctionType)�Client)� HTTPTransportzsentry.errors.clientc C s ddddddd�S )NZAWS_LAMBDA_FUNCTION_NAMEZAWS_LAMBDA_FUNCTION_VERSIONZAWS_LAMBDA_FUNCTION_MEMORY_SIZEZAWS_LAMBDA_LOG_GROUP_NAMEZAWS_LAMBDA_LOG_STREAM_NAMEZ AWS_REGION)�lambda�versionZmemory_sizeZ log_groupZ log_streamZregion� r r r �Q/opt/alt/python37/lib/python3.7/site-packages/raven/contrib/awslambda/__init__.py�get_default_tags s r c sf e Zd ZdZ� fdd�Z� fdd�Z� fdd�Zdd d �Zedd� �Z ed d� �Z edd� �Z� ZS )�LambdaClienta� Raven decorator for AWS Lambda. By default, the lambda integration will capture unhandled exceptions and instrument logging. Usage: >>> from raven.contrib.awslambda import LambdaClient >>> >>> >>> client = LambdaClient() >>> >>> @client.capture_exceptions >>> def handler(event, context): >>> ... >>> raise Exception('I will be sent to sentry!') c s* |� dt�}tt| �j|d|i|�� d S )N� transport)�getr �superr �__init__)�self�args�kwargsr )� __class__r r r 8 s zLambdaClient.__init__c s� d|kri |d<