OwlCyberSecurity - MANAGER
Edit File: __init__.cpython-311.pyc
� ��bg� � �j � d Z ddlmZ ddlZddlmZ ddlmZ ddlm Z ddl mZ G d� d e� � Z dS ) z� raven.contrib.bottle ~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2013 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. � )�absolute_importN)�request)� setup_logging)�get_data_from_request)� SentryHandlerc �2 � e Zd ZdZd d�Zd� Zd� Zd� Zd� ZdS ) �Sentryav Bottle application for Sentry. >>> sentry = Sentry(app, client) Automatically configure logging:: >>> sentry = Sentry(app, client, logging=True) Capture an exception:: >>> try: >>> 1 / 0 >>> except ZeroDivisionError: >>> sentry.captureException() Capture a message:: >>> sentry.captureMessage('hello, world!') Fc � � || _ || _ || _ | j r!t t | j � � � � | | j _ d S �N)�app�client�loggingr r �sentry)�selfr r r s �n/builddir/build/BUILD/cloudlinux-venv-1.0.7/venv/lib/python3.11/site-packages/raven/contrib/bottle/__init__.py�__init__zSentry.__init__) sF � �����������<� 6��-���4�4�5�5�5������� c � � | j � |� d� � t t � � d| j i�� � d S )N�exc_infor )r �data�extra)r �captureException�getr r r )r �args�kwargss r �handle_exceptionzSentry.handle_exception1 sQ � ���$�$��Z�Z� �+�+�&�w�/�/��t�x�� %� � � � � r c � � �� d� �fd� } � � ||� � S # t $ r) � � t j � � �� � � w xY w)Nc �N �� |��� |�� � �| ||� � S )N�r )r )�status�headersr r �start_responses ��r �session_start_responsez/Sentry.__call__.<locals>.session_start_response; s4 �� ��#��%�%�x�%�8�8�8�!�>�&�'�8�<�<�<r r r )r � Exceptionr �sysr )r �environr"