관리-도구
편집 파일: templates.cpython-311.pyc
� R�DgF � � � d dl mZ d dlmZ erd dlmZ d dlmZ d dlmZ d dlmZ d dlm Z d dl mZ n# e$ r d d l mZ Y nw xY wd � Zd� Zd� Zd � ZdS )� )�TemplateSyntaxError)�MYPY)�Any)�Dict)�Optional)�Iterator)�Tuple)�Origin)�LoaderOriginc �z � t | d� � rt | j � � S t | d� � rt | j � � S t | t � � r]t | d� � rM| j }t |t t f� � r*t |d t � � rt |� � S d S )N�template_debug�django_template_source�sourcer )�hasattr�_get_template_frame_from_debugr �_get_template_frame_from_sourcer � isinstancer r �tuple�listr )� exc_valuer s ��/builddir/build/BUILD/imunify360-venv-2.4.0/opt/imunify360/venv/lib/python3.11/site-packages/sentry_sdk/integrations/django/templates.py�!get_template_frame_from_exceptionr s� � � �y�*�+�+� H�-�i�.F�G�G�G� �y�2�3�3� �.��,� � � � �)�0�1�1� ;�g�i��6R�6R� ;��!���f�u�d�m�,�,� ;��F�1�I�v�1N�1N� ;�2�6�:�:�:��4� c � � | �d S | d }| d }|�d}g }g }d }| d D ]?\ }}||k r|� |� � �!||k r|� |� � �=|}�@|||dd � |d d� |dd�S ) N�line�name�<django template>�source_lines���� T)�filename�lineno�pre_context�post_context�context_line�in_app)�append)�debugr"