관리-도구
편집 파일: breadcrumbs.cpython-37.pyc
B ��Y- � @ s* d dl mZ d dlZd dlZd dlZd dlmZ d dlmZm Z m Z mZ d dlm Z g Zi Ze�d�Zdd� ZG d d � d e�ZG dd� de�Zd,dd�Zdd� Zd-dd�Zdd� Zd.dd�Zdd� Ze dd� �Zd/dd�Zdd� Zd d!� Zi Z d"d#� Z!e!d$�d%d&� �Z"e!d'�d(d)� �Z#d*d+� Z$d dl%Z&dS )0� )�absolute_importN)�FunctionType)� iteritems�get_code� text_type�string_types)�once�ravenc C sP | d |d koN| d |d koN| d |d koN| d |d koN| d |d kS )N�type�level�message�category�data� )�a�br r �B/opt/alt/python37/lib/python3.7/site-packages/raven/breadcrumbs.py�event_payload_considered_equal s r c @ s0 e Zd Zddd�Zddd�Zdd� Zd d � ZdS ) �BreadcrumbBuffer�d c C s g | _ || _d S )N)�buffer�limit)�selfr r r r �__init__ s zBreadcrumbBuffer.__init__Nc C sZ |s|s|st d��|d kr$t�� }| j�|p0d|||||d�|f� | jd | j �= d S )Nz6You must pass either `message`, `data`, or `processor`�default)r � timestampr r r r )� ValueError�timer �appendr )r r r r r r r � processorr r r �record# s zBreadcrumbBuffer.recordc C s | j d d �= d S )N)r )r r r r �clear4 s zBreadcrumbBuffer.clearc C s� g }x�t | j�D ]v\}\}}|d k rby||� W n" tk rR t�d� d }Y nX |d f| j|<