
    Mhi                     ,   d Z ddlZddlZddlZddlZddlmZ ddlZddl	m
Z
 ddlmZ ddlmZ ddlmZ ddlmZ 	 dd	lmZ n# e$ r	 dd
lmZ Y nw xY wddlmZmZmZ 	 ddlmZ ddlmZ ddlm Z m!Z! dZ"n/# e$ r dZ"Y n&e#$ rZ$e$j%        j&        dk    rdZ"ne$Y dZ$[$ndZ$[$ww xY w e'edd          pej(        Z) G d d          Z* G d d          Z+ G d d          Z, G d d          Z- G d d          Z. G d d          Z/ G d  d!          Z0dS )"z/Debugger implementation for the IPython kernel.    N)Path)get_ipython)leading_empty_lines)Event)Queue)jsonapi)json_default)date_default   )get_file_nameget_tmp_directoryget_tmp_hash_seed)api)pydevd_frame_utils)SuspendedFramesManager_FramesTrackerTFDebuggerInitializationError
ROUTING_IDc                       e Zd ZdZd ZdS )	_FakeCodezFake code class.c                 "    || _         || _        dS Init.N)co_filenameco_name)selfr   r   s      R/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/ipykernel/debugger.py__init__z_FakeCode.__init__3   s    &    N__name__
__module____qualname____doc__r    r   r   r   r   0   s)            r   r   c                       e Zd ZdZd ZdS )
_FakeFramezFake frame class.c                 >    || _         || _        || _        d| _        dS r   )f_code	f_globalsf_localsf_back)r   r)   r*   r+   s       r   r   z_FakeFrame.__init__<   s"    " r   Nr    r%   r   r   r'   r'   9   s)            r   r'   c                       e Zd ZdZd ZdS )
_DummyPyDBzFake PyDb class.c                 D    ddl m} |                                | _        dS )r   r   )	PyDevdAPIN)_pydevd_bundle.pydevd_apir0   VariablePresentationvariable_presentation)r   r0   s     r   r   z_DummyPyDB.__init__G   s.    777777%.%C%C%E%E"""r   Nr    r%   r   r   r.   r.   D   s.        F F F F Fr   r.   c                   ,    e Zd ZdZd Zd Zd ZddZdS )VariableExplorerzA variable explorer.c                     t                      | _        t                      | _        t	          | j        | j                  | _        d| _        dS )zInitialize the explorer.N)r   suspended_frame_managerr.   py_dbr   trackerframer   s    r   r   zVariableExplorer.__init__Q   s<    '='?'?$\\
%d&BDJOO


r   c                     t                      j        }t          t          dt	          d                    ||          | _        | j                            dt          j	        | j                             dS )zStart tracking.<module>zsys._getframe()thread1N)
r   user_nsr'   r   r   r:   r9   trackr   create_frames_list_from_frame)r   vars     r   r@   zVariableExplorer.trackX   sd    mm#	*mDU6V6V W WY\^abb
9&8&VW[Wa&b&bcccccr   c                 8    | j                                          dS )zStop tracking.N)r9   untrack_allr;   s    r   rD   zVariableExplorer.untrack_all^   s      """""r   Nc                     |}|st          | j                  }| j                            |          }d |                                D             S )z1Get the child variables for a variable reference.c                 6    g | ]}|                                 S r%   )get_var_data).0xs     r   
<listcomp>z;VariableExplorer.get_children_variables.<locals>.<listcomp>h   s"    MMMQ  MMMr   )idr:   r7   get_variableget_children_variables)r   variable_refvar_ref	variabless       r   rM   z'VariableExplorer.get_children_variablesb   sR     	%nnG0==gFF	MM)*J*J*L*LMMMMr   N)r!   r"   r#   r$   r   r@   rD   rM   r%   r   r   r5   r5   N   sd          d d d# # #N N N N N Nr   r5   c                   @    e Zd ZdZdZdZdZdZd Zd Z	d Z
d	 Zd
 ZdS )DebugpyMessageQueuezA debugpy message queue.zContent-Length:    z

   c                 ~    d| _         |                                  || _        t                      | _        || _        dS )zInit the queue. N)
tcp_buffer_reset_tcp_posevent_callbackr   message_queuelog)r   rZ   r\   s      r   r   zDebugpyMessageQueue.__init__s   s:    ,+077r   c                 >    d| _         d| _        d| _        d| _        d S )Nr   )
header_posseparator_posmessage_sizemessage_posr;   s    r   rY   z"DebugpyMessageQueue._reset_tcp_pos{   s'    r   c                    | j                             d           t          j        t          j        t
          t          j        f         t          j        |                    }|d         dk    rK| j                             d           | j                             |           | 	                    |           d S | j                             d           | j                             |           | j
                            |           d S )NzQUEUE - _put_message:typeeventzQUEUE - received event:zQUEUE - put message:)r\   debugtcastDictstrAnyr   loadsrZ   r[   
put_nowait)r   raw_msgmsgs      r   _put_messagez DebugpyMessageQueue._put_message   s    .///fQVCJ'w)?)?@@v;'!!HNN4555HNN3$$$$$HNN1222HNN3))#.....r   c                 ^   | xj         |z  c_         | j                            d           	 | j        dk    r)| j                             t
          j                  | _        | j        dk    rdS | j                            d| j                   | j        dk    r>| j        t
          j        z   }| j                             t
          j	        |          | _        | j        dk    rdS | j                            d| j                   | j
        dk    rS| j        t
          j        z   }| j        t
          j        z   | _
        t          | j         || j                           | _        | j                            d| j
                   | j                            d| j                   t          | j                   | j
        z
  | j        k     rdS |                     | j         | j
        | j
        | j        z                       t          | j                   | j
        z
  | j        k    r7| j                            d	           d
| _         |                                  dS | j         | j
        | j        z   d         | _         | j                            d| j                    |                                  )zPut a tcp frame in the queue.zQUEUE - received frameTr^   NzQUEUE - found header at pos %iz!QUEUE - found separator at pos %izQUEUE - found message at pos %izQUEUE - message size is %izQUEUE - resetting tcp_bufferrW   zQUEUE - slicing tcp_buffer: %s)rX   r\   rf   r_   findrS   HEADERr`   HEADER_LENGTH	SEPARATORrb   SEPARATOR_LENGTHintra   lenrp   rY   )r   r:   hintsize_poss       r   put_tcp_framez!DebugpyMessageQueue.put_tcp_frame   so   5 /000(	""$$"&/"6"67J7Q"R"R"$$HNN;T_MMM !R'')<)JJ%)_%9%9:M:WY]%^%^"!R''HNN>@RSSS2%%?-@-NN#'#58K8\#\ $'4CU8U(V$W$W!HNN<d>NOOOHNN79JKKK4?##d&669JJJ 043CdFW3W WX   4?##d&66$:KKK=>>>"$##%%%"od.>AR.R.T.TUDOHNN;T_MMM!!!Q(	"r   c                 D   K   | j                                          d{V S )zGet a message from the queue.N)r[   getr;   s    r   get_messagezDebugpyMessageQueue.get_message   s-      '++---------r   N)r!   r"   r#   r$   rs   rt   ru   rv   r   rY   rp   r{   r~   r%   r   r   rS   rS   k   s{        ""FMI    
/ 
/ 
/-" -" -"^. . . . .r   rS   c                   T    e Zd ZdZd Zd Zd Zd Zd Zd Z	d Z
d	 Zd
 Zd Zd ZdS )DebugpyClientzA client for debugpy.c                     || _         || _        || _        t          | j        | j                   | _        d| _        d| _        d| _        d| _	        t                      | _        d| _        dS )zInitialize the client.	127.0.0.1r^   NT)r\   debugpy_streamrZ   rS   _forward_eventr[   debugpy_hostdebugpy_port
routing_idwait_for_attachr   
init_eventinit_event_seq)r   r\   r   rZ   s       r   r   zDebugpyClient.__init__   sh    ,,01DdhOO'#'' r   c                 `    |                                  \  }}d|z   dz   t          |          z   S )Ntcp://:)get_host_portrj   )r   hostports      r   _get_endpointzDebugpyClient._get_endpoint   s1    ''))
d$$s4yy00r   c                     |d         dk    r&| j                                          |d         | _        |                     |           d S )Nre   initializedseq)r   setr   rZ   r   ro   s     r   r   zDebugpyClient._forward_event   sK    w<=((O!!!"%e*DC     r   c                 (   | j         )| j        j                            t                    | _         t          j        |t          dd          }t          t          |                    }t          j        |z   t          j        z                       d          }||z  }| j                            d           | j                            | j                    | j                            |           | j                            | j         |f           d S )NF)defaultensure_ascii	allow_nanasciizDEBUGPYCLIENT:)r   r   socket
getsockoptr   r   dumpsr	   rj   rx   rS   rs   ru   encoder\   rf   send_multipart)r   ro   contentcontent_lengthbufs        r   _send_requestzDebugpyClient._send_request   s    ?""18CCJOODO- 	
 
 
 S\\**")N:=P=ZZbb
 
 	w'(((t'''s**DOS+ABBBBBr   c                 D   K   | j                                          d {V S rQ   )r[   r~   r;   s    r   _wait_for_responsez DebugpyClient._wait_for_response   s/       '33555555555r   c                   K   | j                                          d {V  dt          | j                  dz   dd}|                     |           |                                  d {V  |                                  d {V S )Nrequestr   configurationDone)rd   r   command)r   waitrw   r   r   r   )r   r   s     r   _handle_init_sequencez#DebugpyClient._handle_init_sequence   s      o""$$$$$$$$$ t*++a/*
 

 	,--- %%''''''''' ,,.........r   c                    | j         dk    r| j        j        }|                    d| j        z              |                    t          j                                      d          | _	        |
                    | j	                   | j	                            d          }| j	        |dz   d         | _         | j        | j         fS )zGet the host debugpy port.r^   r   utf-8r   r   N)r   r   r   bind_to_random_portr   r   zmqLAST_ENDPOINTdecodeendpointunbindrfind)r   r   indexs      r   r   zDebugpyClient.get_host_port  s    ""(/F&&x$2C'CDDD"--c.?@@GGPPDMMM$-(((M'',,E $eaikk :D $"333r   c                     | j         j                            |                                            | j         j                            t
                    | _        dS )zConnect to the tcp socket.N)r   r   connectr   r   r   r   r;   s    r   connect_tcp_socketz DebugpyClient.connect_tcp_socket  sG    "**4+=+=+?+?@@@-4??
KKr   c                     | j         j                            |                                            d| _        t                      | _        d| _        d| _        dS )zDisconnect from the tcp socket.Nr^   T)	r   r   
disconnectr   r   r   r   r   r   r;   s    r   disconnect_tcp_socketz#DebugpyClient.disconnect_tcp_socket  sP    "--d.@.@.B.BCCC'' #r   c                 :    | j                             |           dS )zReceive a dap frame.N)r[   r{   )r   r:   s     r   receive_dap_framezDebugpyClient.receive_dap_frame  s    ((/////r   c                 <  K   |                      |           | j        r/|d         dk    r#|                                  d{V }d| _        |S |                                  d{V }| j                            d           | j                            |           |S )zSend a dap request.r   attachNFzDEBUGPYCLIENT - returning:)r   r   r   r   r\   rf   )r   ro   reps      r   send_dap_requestzDebugpyClient.send_dap_request"  s      3 	C	Nh$>$>2244444444C#(D J++--------3444s
r   N)r!   r"   r#   r$   r   r   r   r   r   r   r   r   r   r   r   r%   r   r   r   r      s        ! ! !1 1 1! ! !C C C&6 6 6/ / /$	4 	4 	4L L L
$ $ $0 0 0    r   r   c                       e Zd ZdZg dZg dZ	 ddZd Zd Zd Z	d	 Z
d
 Zed             Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd ZdS )DebuggerzThe debugger class.)dumpCellsetBreakpointssource
stackTracerP   r   r   )	debugInfoinspectVariablesrichInspectVariablesmodulescopyToGlobalsTc                    || _         t          ||| j                  | _        || _        || _        d| _        || _        || _        t                      | _
        i | _        t          j        D ]}t          | |          | j        |<   i | _        t          j        D ]}t          | |          | j        |<   i | _        t%                      | _        d| _        i | _        d| _        d| _        d| _        t3                      | _        dS )zInitialize the debugger.Fr   r   N)r\   r   _handle_eventdebugpy_clientshell_socketsession
is_startedrZ   just_my_coder   stopped_queuestarted_debug_handlersr   started_debug_msg_typesgetattrstatic_debug_handlersstatic_debug_msg_typesbreakpoint_listr   stopped_threadsdebugpy_initialized_removed_cleanupr   r   r   r5   variable_explorer)r   r\   r   rZ   r   r   r   msg_types           r   r   zDebugger.__init__G  s    +CASTT(,(+077&(# 8 	L 	LH4;D(4K4KD'11%'" 7 	K 	KH3:43J3JD&x00!"uu#(  "'!1!3!3r   c                    |d         dk    rg|d         d         r| j                             |           d S | j                            |d         d                    |                     |           d S |d         dk    r_|d         d         rt                      | _        n&| j                            |d         d                    |                     |           d S |                     |           d S )Nre   stoppedbodyallThreadsStoppedthreadId	continuedallThreadsContinued)r   rm   r   addrZ   r   remover   s     r   r   zDebugger._handle_eventh  s    w<9$$6{./ "--c222 $$S[%<===$$$$$\[((6{01 E'*uu$$$++CK
,CDDD$$$$$$$$$$r   c                 F   K   | j                             |           d {V S rQ   )r   r   r   s     r   _forward_messagezDebugger._forward_messagey  s/      (99#>>>>>>>>>r   c                 Z      fd|D             }|d         d|d         d|d         d|idS )Nc                 J    g | ]}                     |d                    | S nameaccept_variablerH   rB   r   s     r   rJ   z6Debugger._build_variables_response.<locals>.<listcomp>}  s0    RRRC0D0DS[0Q0QRCRRRr   r   responseTr   rP   )r   rd   request_seqsuccessr   r   r%   )r   r   rP   var_lists   `   r   _build_variables_responsez"Debugger._build_variables_response|  sO    RRRR9RRR5>"5>y) (+
 
 	
r   c                     g d}||vS )N)IPythonHistorySavingThreadzThread-2zThread-3zThread-4r%   )r   thread_nameforbid_lists      r   _accept_stopped_threadzDebugger._accept_stopped_thread  s     YXX+--r   c                 ^  K   | j                                          d{V }|d         dz   ddd}|                     |           d{V }|d         d         D ]=}|                     |d                   r | j                            |d	                    >|                     |           dS )
zHandle a stopped event.Nr   r   r   threads)r   rd   r   r   r   rK   )r   r}   r   r   r   r   rZ   )r   re   reqr   threads        r   handle_stopped_eventzDebugger.handle_stopped_event  s       (,,........ElQ&	iPP))#........&k), 	7 	7F**6&>:: 7$((666E"""""r   c                     | j         S rQ   )r   r;   s    r   
tcp_clientzDebugger.tcp_client  s    ""r   c           	         | j         st                      }t          |                                          s#t          |                              d           | j                                        \  }}d}|d|z   dz   |z   dz   z  }|dd}| j                            | j	        d|d	| j	        
                    t                               | j                            | j	        d
          \  }}|d         d         dk    | _         t                      j        j        }t           |v r7|                    t                     }	|                    |	          | j        |	<   | j                                         | j         S )zStart the debugger.T)parentszimport debugpy;zdebugpy.listen(("z",z)))codesilentexecute_requestNr   )moder   statusok)r   r   r   existsmkdirr   r   r   sendr   r   r   recvr   input_transformer_managercleanup_transformsr   r   popr   r   )
r   tmp_dirr   r   r  r   identro   r  r   s
             r   startzDebugger.start  sz   ' 	H'))G=='')) 2W##D#111,::<<JD$$D'$.5<tCCD#t44GL!!"--j99   **4+<1*EEJE3'*9~h'?4'GD$ )]]DW"444&,,-@AAE+=+A+A%+H+HD!%(..000''r   c                     | j                                          t                      j        j        }t          | j                  D ]2}| j                            |          }|                    ||           3dS )zStop the debugger.N)	r   r   r   r  r  sortedr   r  insert)r   r  r   funcs       r   stopzDebugger.stop  s|    11333 )]]DWD122 	3 	3E(,,U33D%%eT2222	3 	3r   c                    K   |d         d         }t          |          }t          |dd          5 }|                    |           ddd           n# 1 swxY w Y   d|d         d	|d
         d|idS )zHandle a dump cell message.	argumentsr  wr   encodingNr   r   Tr   
sourcePathrd   r   r   r   r   )r   openwrite)r   messager  	file_namefs        r   r   zDebugger.dumpCell  s      {#F+!$''	)S7333 	qGGDMMM	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 "5>y)!9-
 
 	
s   AAAc                    K   |d         d         d         }|d         d         | j         |<   |                     |           d{V }|                    d          r d |d         d         D             | j         |<   |S )	z!Handle a set breakpoints message.r  r   pathbreakpointsNr   c                 "    g | ]}d |d          iS )liner%   )rH   
breakpoints     r   rJ   z+Debugger.setBreakpoints.<locals>.<listcomp>  s2     , , , F+,, , ,r   r   )r   r   r}   )r   r$  r   message_responses       r   r   zDebugger.setBreakpoints  s      %h/7'.{';M'JV$!%!6!6w!?!??????? 	** 	, ,"26":="I, , ,D (  r   c                 F  K   d|d         |d         d}|d         d         d         }t          |                                          rHt          |d	          5 }d
|d<   d|                                i|d<   ddd           n# 1 swxY w Y   nd|d<   d|d<   i |d<   |S )zHandle a source message.r   r   r   )rd   r   r   r  r   r(  r   r  Tr   r   r   NFzsource unavailabler$  )r   is_filer"  read)r   r$  replysource_pathr&  s        r   r   zDebugger.source  s      #GENwW`Oabbk*84V<$$&& 	kG444 6#'i !*AFFHH 5f6 6 6 6 6 6 6 6 6 6 6 6 6 6 6  %E)3E)E&Ms   BB
B
c           	      L  K   |                      |           d{V }	 |d         d         }t          |          t          d t          t	          |          d          D                       z
  }|d         d         d|dz            |d         d<   n# t
          $ r Y nw xY w|S )zHandle a stack trace message.Nr   stackFramesc              3   D   K   | ]\  }}|d          dk    |dk    |V  dS )r   r=   r   Nr%   )rH   ivs      r   	<genexpr>z&Debugger.stackTrace.<locals>.<genexpr>   sI       - -a6jAXAX]^bc]c]c]c]c]c]c- -r   r   )r   rx   next	enumeratereversedStopIteration)r   r$  r1  sf_list
module_idxs        r   r   zDebugger.stackTrace  s      ++G44444444	FmM2GW - -'(9(91==- - - ) ) J ,1=+GHX*WX.HX+YE&M-(( 	 	 	D	s   A4B 
B! B!c                     g d}||v}|o"t          t          j        d|                     }|o|dd         dk    }|S )zAccept a variable by name.)r!   r$   __package__
__loader____spec____annotations____builtins____builtin____display__r   debugpyexitquitInOut_oh_dh______z^_\dr      _i)boolresearch)r   variable_namer   conds       r   r   zDebugger.accept_variable  s]    
 
 
, K/CD7M!B!BCCC2ac*d2r   c                    K   i } j         s< j                            |d         d                   }                     ||          S                      |           d{V } fd|d         d         D             |d         d<   |S )zHandle a variables message.r  variablesReferenceNc                 J    g | ]}                     |d                    | S r   r   r   s     r   rJ   z&Debugger.variables.<locals>.<listcomp>0  sA     &
 &
 &
9M9McRXk9Z9Z&
&
 &
 &
r   r   rP   )r   r   rM   r   r   )r   r$  r1  rP   s   `   r   rP   zDebugger.variables%  s      # 	F.EE$%9: I 11'9EEE++G44444444&
 &
 &
 &
 =5&
 &
 &
fk" r   c                    K   | j                                         \  }}||d|d         d<   d|d         d<   | j        sdg|d         d<   |                     |           d{V S )	zHandle an attach message.)r   r   r  r   T	logToFileDebugStdLibdebugOptionsN)r   r   r   r   )r   r$  r   r   s       r   r   zDebugger.attach5  s      (6688
d37*F*FY',0[)
   	C4A?GK 0**7333333333r   c                 :   K   |d         d|d         d|d         dS )z$Handle a configuration done message.r   r   Tr   )r   rd   r   r   r   r%   )r   r$  s     r   r   zDebugger.configurationDoneB  s3       5>"5>y)
 
 	
r   c                 0  K   g }| j                                         D ]\  }}|                    ||d           d|d         d|d         | j        dt	                      t                      t          j        z   d|t          | j	                  ddgdd	
d
S )zHandle a debug info message.)r   r)  r   r   Tr   Murmur2.pyzPython Exceptions)
	isStarted
hashMethodhashSeedtmpFilePrefixtmpFileSuffixr)  stoppedThreadsrichRenderingexceptionPathsr   r!  )
r   itemsappendr   r   r   osseplistr   )r   r$  r   keyvalues        r   r   zDebugger.debugInfoL  s      .4466 	J 	JJC""c%#H#HIIII"5>y)!_'-//!2!4!4rv!=!&."&t';"<"<!%#6"7!% 
 
 	
r   c                    K   | j                                          t                      | _         | j                                          | j                                         }|                     ||          S )z$Handle an inspect variables message.)r   rD   r5   r@   rM   r   )r   r$  rP   s      r   r   zDebugger.inspectVariablesd  sj      **,,, "2!3!3$$&&&*AACC	--gyAAAr   c           	        K   d|d         d|d         d}|d         d         }t                               |          }|si i d|d	<   |d
k    s|dk    rd|d<   |S i i }| j        spt                                          ||i          |         }|                    dd          dk    r,|                    di           |                    di           }nkd| d}|d         d         }|d         }	|                     dd|	dz   ||ddd           d{V }|d         r t          |d	         d         i i           \  }fd|                                D             d}
|
|d	<   d|d<   |S )z(Handle a rich inspect variables message.r   r   Fr   )rd   sequence_seqr   r   r  variableName)datametadatar   zspecial variableszfunction variablesTr   r
  errorr  rv  rw  z'get_ipython().display_formatter.format()frameIdr   evaluater   	clipboard)
expressionrz  contextrd   r   r   r  Nresultc                 $    i | ]\  }}|v 	||S r%   r%   )rH   kr7  	repr_datas      r   
<dictcomp>z1Debugger.richInspectVariables.<locals>.<dictcomp>  s$    RRR$!Q1	>>A>>>r   )	rj   isidentifierr   r   user_expressionsr}   r   evalrk  )r   r$  r1  var_name
valid_namerepr_metadatar  r  frame_idr   r   r  s              @r   r   zDebugger.richInspectVariableso  s      #ENy)	
 
 ;'7%%h//
 	%'R88E&M...(>R2R2R#'i L	# 	Q !]]33Xx4HII(SFzz(G,,44"JJvr22	 &

:r : : IXHHHD{+I6H%.C//%)704Va!b!b	        E Y Q+/fh0GR+P+P(	= RRRR-*=*=*?*?RRR
 

 fir   c           	         K   |d         d         }|d         d         }|d         d         }d| d}|d         }|                      dd	|d
z   |||dd           d {V S )Nr  dstVariableNamesrcVariableName
srcFrameIdzglobals()['z']r   r   setExpressionr   )r}  rq  rz  r  )r   )r   r$  dst_var_namesrc_var_namesrc_frame_idr}  r   s          r   r   zDebugger.copyToGlobals  s      {+,=>{+,=>{+L93<333
en**!*Qw",)+ 		 	
 
 
 
 
 
 
 
 	
r   c                   K   t          t          j                                                  }|                    dd          }|                    dt          |                    }g }t          ||          D ]_}||         }t          t          |dd          dd          }|r3|                    d          r|	                    ||j
        |d           `d	|t          |          d
iS )zHandle a modules message.startModuler   moduleCountrB  Noriginrb  )rK   r   r(  r   )r   totalModules)ro  sysr   valuesr}   rx   ranger   endswithrl  r!   )	r   r$  r   r  r  modsr6  modulefilenames	            r   r   zDebugger.modules  s      s{))++,,kk-33kk-W>>{K00 	R 	RAQZFwvz4@@(DQQH RH--e44 R1foxPPQQQD#g,,GGHHr   c                   K   i }|d         dk    rk| j         r| j                            d           nI|                                 | _         | j         r| j                            d           nd|d         dddd	}| j                            |d         d
          }| ||           d
{V }nW| j         rP| j                            |d         d
          }| ||           d
{V }n|                     |           d
{V }|d         dk    rO|                                  i | _	        t                      | _        d| _         | j                            d           |S )zProcess a request.r   
initializez The debugger has already startedzThe debugger has startedr      Fr   )r   r   r   r   rd   Nr   zThe debugger has stopped)r   r\   infor  r   r}   r   r   r  r   r   r   )r   r$  r1  handlers       r   process_requestzDebugger.process_request  s     9-- @AAAA"&**,,? 	HMM"<==== $0'.u~ #( * E ,001CTJJ!''********EE_ 	=155gi6H$OOG"%gg........"33G<<<<<<<<9--IIKKK#%D #&55D #DOHMM4555r   N)T)r!   r"   r#   r$   r   r   r   r   r   r   r   r  propertyr  r  r  r   r   r   r   r   rP   r   r   r   r   r   r   r   r  r%   r   r   r   r   0  s            X\4 4 4 4B% % %"? ? ?	
 	
 	
. . .
# 
# 
# # # X#( ( (<3 3 3
 
 
          ,  :   4 4 4
 
 

 
 
0	B 	B 	B2 2 2h
 
 
(I I I% % % % %r   r   )1r$   rm  rT  r  typingrg   pathlibr   r   IPython.core.getipythonr   IPython.core.inputtransformer2r   tornado.locksr   tornado.queuesr   	zmq.utilsr   jupyter_client.jsonutilr	   ImportErrorr
   compilerr   r   r   debugpy.serverr   _pydevd_bundler   &_pydevd_bundle.pydevd_suspended_framesr   r   _is_debugpy_available	Exceptione	__class__r!   r   IDENTITYr   r   r'   r.   r5   rS   r   r   r%   r   r   <module>r     sO   5 5 				 				 



           



 / / / / / / > > > > > >                        E4444444 E E EDDDDDDDDE J I I I I I I I I I""""""111111       
 ! " " "!    	{<<< % 		 WS,--=
              F F F F F F F FN N N N N N N N:S. S. S. S. S. S. S. S.ll l l l l l l l^z z z z z z z z z zs/   A AAA6 6B"?B"BB"