
    Tf                     |    d Z ddlZddlZddlZddlZddgZ ej        d          Z G d de          Z	dd	Z
d
 ZdS )zPThe debug module contains utilities and functions for better
debugging Gunicorn.    Nspewunspewz\W+c                       e Zd ZddZd ZdS )SpewNTc                 "    || _         || _        d S )Ntrace_namesshow_values)selfr	   r
   s      @/var/www/html/env/lib/python3.11/site-packages/gunicorn/debug.py__init__zSpew.__init__   s    &&    c                 T   |dk    r|j         }d|j        v rd|j        d         }|                    d          s|                    d          r
|d d         }|j        d         }t          j        ||          }nFd}	 t          j        |          }||         }n&# t          $ r d|j        j	        |j
        fz  }Y nw xY w| j        	|| j        v rt          |d	|d
|                                           | j        s| S g }	t                              |          }
|
D ]^}||j        v r%|	                    |d|j        |                    ||j        v r%|	                    |d|j        |                    _|	r%t          dd                    |	          z             | S )Nline__file__z.pycz.pyo__name__z	[unknown]z,Unknown code named [%s].  VM instruction #%d:z: =z	%s )f_lineno	f_globalsendswith	linecachegetlineinspectgetsourcelinesIOErrorf_codeco_namef_lastir	   printrstripr
   _token_splitersplitappendf_localsjoin)r   frameeventarglinenofilenamenamer   srcdetailstokenstoks               r   __call__zSpew.__call__   s   F??^FU_,, ?:6%%f-- - ))&11-'}Hz2 (6::"=!077Cv;DD = = =I,emM= =DDD= '443C+C+CTTT6664;;===ABBB'  K'--d33! M MCeo--###us7K7K'LMMMen,,###u~c7J7J'KLLL 6&388G#4#44555s   ?B  B?>B?)NT)r   
__module____qualname__r   r3    r   r   r   r      s7        ' ' ' '    r   r   Fc                 J    t          j        t          | |                     dS )zpInstall a trace hook which writes incredibly detailed logs
    about what code is being executed to stdout.
    N)syssettracer   r   s     r   r   r   ;   s$     Lk;//00000r   c                  .    t          j        d           dS )z-Remove the trace hook installed by spew.
    N)r8   r9   r6   r   r   r   r   B   s     Lr   )NF)__doc__r8   r   rer   __all__compiler$   objectr   r   r   r6   r   r   <module>r@      s     


     				 8
F##% % % % %6 % % %P1 1 1 1    r   