관리-도구
편집 파일: sentry.cpython-311.pyc
� �Cg� � �. � d dl Z d dlZd dlZd dlZd dlmZ d dlmZmZm Z m Z d dlmZ d dl Zd dlmZ d dlmZ d dlZd dlmZmZ d dlmZ d Z G d � dej j � � Z G d� d e� � Z G d� de� � Z G d� de� � Z d� Z!d� Z"dS )� N)� TracebackType)�Dict�Set�Tuple�Type)�URLError)�Client)�ThreadedHTTPTransport)�cpapi�get_lve_version)�get_rhn_systemid_valuezehttps://9713d1296f804031b058b8f2d789d7ac:8ddacae32d8246cf8b25cf826bf3fc0a@cl.sentry.cloudlinux.com/12c � � e Zd Zd� ZdS )�RemoveConnectStringc � � |� dg � � D ]F}|� dg � � D ]-}t |t � � r|� dd � � �.�Gd S )N�frames�vars�connect_string)�get� isinstance�dict�pop)�self�data�frame� variabless ��/builddir/build/BUILDROOT/lve-stats-4.2.10-1.el8.x86_64/opt/cloudlinux/venv/lib/python3.11/site-packages/lvestats/lib/commons/sentry.py�filter_stacktracez%RemoveConnectString.filter_stacktrace ss � ��X�X�h��+�+� :� :�E�"�Y�Y�v�r�2�2� :� :� ��i��.�.� :��M�M�"2�D�9�9�9�� :� :� :� N)�__name__� __module__�__qualname__r � r r r r s# � � � � � �:� :� :� :� :r r c � � e Zd ZdZ ej � � Z e� � Zed� � � Z ed� � � Z d� Zd� Zd� Z d� ZdS ) �LveStatsSentryFilterz/var/lve/errors_record_listc � � t � � | _ t j | j � � d S # t $ r Y d S w xY w�N)�set�_record_list_cache�os�unlink�_record_list_file�OSError��clss r �clear_record_listz&LveStatsSentryFilter.clear_record_list) sP � � "%����� ��I�c�+�,�,�,�,�,��� � � ��D�D� ���s �0 � >�>c � � | j t j � � dz k r.| � � � t j � � | _ d S d S )Ni�� )�_last_clean�timer/ r- s r �_clean_muted_recordsz)LveStatsSentryFilter._clean_muted_records2 sE � ��?�T�Y�[�[�5�0�0�0��!�!�#�#�#�"�i�k�k�C�O�O�O� 1�0r c � � t | j dd�� � 5 }d� |D � � }d d d � � n# 1 swxY w Y ||v S # t $ r Y dS w xY w)N�r�utf-8��encodingc �8 � g | ]}|� d � � ��S )� )�rstrip)�.0�lines r � <listcomp>z7LveStatsSentryFilter.in_record_list.<locals>.<listcomp><