0x1949 Team - FAZEMRX - MANAGER
Edit File: _format.cpython-310.pyc
o �bb. � @ s� d Z ddlmZ ddlmZ ddlmZmZm Z mZm Z mZmZ ddl mZ ddlmZ ddlmZ ddlmZ d d lmZmZ d dlmZ dZd edefdd�Zd ededefdd�Zedfde e de e dedefdd�Z e fd edee e gef de e fdd�Z!G dd� de�Z"dedeeef defd d!�Z#d edefd"d#�Z$d$edefd%d&�Z%d edefd'd(�Z&d)d)d)e fd ed*e'd+e'd,e'deegef defd-d.�Z(d/S )0z& Tools for formatting logging events. � )�Mapping)�datetime)�Any�Callable�Iteratorr �Optional�Union�cast)� NamedConstant)�FixedOffsetTimeZone)�Failure)� safe_repr� )� aFormatter� flatFormat)�LogEventz%Y-%m-%dT%H:%M:%S%z�event�returnc C s t | dddd�S )aa Formats an event as text, using the format in C{event["log_format"]}. This implementation should never raise an exception; if the formatting cannot be done, the returned string will describe the event generically so that a useful message is emitted regardless. @param event: A logging event. @return: A formatted string. F)�includeTraceback�includeTimestamp� includeSystem)�eventAsText)r � r �8/usr/lib/python3/dist-packages/twisted/logger/_format.py�formatEvent s �r �errorc C sV zdj | |d�W S ty* t� }d�dd� | �� D ��}dj t|�||d� Y S w )z� Formats an event as text that describes the event generically and a formatting error. @param event: A logging event. @param error: The formatting error. @return: A formatted string. z)Unable to format event {event!r}: {error})r r z, c s s* � | ]\}}d � t|�t|�f�V qdS )z = N)�joinr )�.0�key�valuer r r � <genexpr>B s � � �z+formatUnformattableEvent.<locals>.<genexpr>zrMESSAGE LOST: unformattable object logged: {error} Recoverable data: {text} Exception during formatting: {failure})r �failure�text)�format� BaseExceptionr r �itemsr )r r r! r"