+
     þÎj}  ã                   ó°   € ^ RI Ht ^ RIHt ^ RIHt ^ RIHt ^ RIt^ RI	t	^ RI
H
t
 ^ RI t  ^ RIHt R t ! R
 R]4      tR#   ] d    ^ RIHt R	 t Li ; i)é    )ÚTestCase)Úutils)Úconvert)ÚreadsN)Úcopy)ÚEmptyc                 ó"   € \        V \        4      # ©N)Ú
isinstanceÚstr©Úss   &ÚL/opt/data/home/.local/lib/python3.14/site-packages/numba/testing/notebook.pyÚisstrr      s   € Ü˜!œSÓ!Ð!ó    c                 ó"   € \        V \        4      # r
   )r   Ú
basestringr   s   &r   r   r      s   € Ü˜!œZÓ(Ð(r   c                   óh   a € ] tR t^t o Rt. ROt. ROt^tR tR t	R t
R tR tR tR tR	 tR
tV tR# )ÚNotebookTestaF  Validate a notebook. All code cells are executed in order. The output is either checked
for errors (if no reference output is present), or is compared against expected output.


Useful references:
http://nbformat.readthedocs.org/en/latest/format_description.html
http://jupyter-client.readthedocs.org/en/latest/messaging.html
c                óº  € \        V4      ;_uu_ 4       p\        \        VP                  4       4      V P                  4      pR R R 4       \
        P                  ! 4       w  rV\        XP                   Uu. uF  qwP                  R8X  g   K  VNK  	  up4       F'  w  r‡V P                  V P                  V4      W†V4       K)  	  R #   + '       g   i     L‹; iu upi )NÚcode)Úopenr   r   ÚreadÚNBFORMAT_VERSIONr   Ústart_new_kernelÚ	enumerateÚcellsÚ	cell_typeÚ_test_notebook_cellÚsanitize_cell)	ÚselfÚnotebookÚtestÚfÚnbÚ_ÚkernelÚcÚis	   &&&      r   Ú_test_notebookÚNotebookTest._test_notebook(   s˜   € ä�(�^Œ^˜qÜœ˜qŸv™v›x›¨$×*?Ñ*?Ó@ˆB÷ ä×*Ò*Ó,‰	ˆÜ¨"¯(ª(ÓL©( Q·k±kÀVÑ6KŸq˜q©(ÑLÖM‰DˆAØ×$Ñ$ T×%7Ñ%7¸Ó%:¸AÀtÖLó N÷ �^üò Ms   ”.CÁ4CÂCÃC	c                óR  a € \        VR 4      '       d   VP                  pMVP                  pVP                  pVP	                  V4       . pRpRp	Rp
RpS P                  V4      '       dç    VP                  R^R7      pTR,          S P                  9  g   KE  TR,          R8X  d?   RTR,          R	,          ,           R
,           TR,          R,          ,           pRp	T
R8X  d   Tp
\        T4      pT\        TP                  4      8  ;'       d    TP                  T,          ;'       g    . pS P                  YŒ4      pTP                  T4       Ký  VR8X  d   S P                  V	RW«3,          4       R# V 3R lpV! V4      pV! VP                  4      pR#   \         d     EKQ  i ; i)ÚsourceNTÚ )ÚblockÚtimeoutÚmsg_typeÚerrorz  ÚcontentÚenamez
  ÚevalueFÚcheck_errorz*Executing cell %d resulted in an error:
%sc                 óV   <€ SP                  \        SP                  V 4      4      4      # r
   )Údump_canonicalÚlistÚscrub_outputs)Úxr!   s   &€r   Ú<lambda>Ú2NotebookTest._test_notebook_cell.<locals>.<lambda>S   s    ø€ ˜d×1Ñ1´$°t×7IÑ7IÈ!Ó7LÓ2MÔNr   éÿÿÿÿ)Úhasattrr-   ÚinputÚiopub_channelÚexecuteÚshould_continueÚget_msgr   ÚIGNORE_TYPESÚlenÚoutputsÚtransform_messageÚappendÚ
assertTrue)r!   Úcellr)   r'   r#   r   ÚiopubrG   ÚmsgÚno_errorÚfirst_errorÚ	error_msgÚexpectedÚoÚscrubÚscrubbeds   f&&&&           r   r   Ú NotebookTest._test_notebook_cell0   sv  ø€ ä�4˜×"Ò"Ø—;‘;‰Dà—:‘:ˆDØ×$Ñ$ˆØ�‰�tÔØˆØˆØˆØˆØˆ	Ø×"Ñ" 3×'Ò'ðØ—m‘m¨$¸�mÓ:�ð �:� d×&7Ñ&7Ö7Ø�z•? gÔ-Ø $ s¨9¥~°gÕ'>Õ >ÀÕ GÈ#ÈiÍ.ÐYaÕJbÕ b�IØ$�HØ" bÔ(Ø&'˜Ü˜“L�Øœs 4§<¡<Ó0Ñ0×DÐD°T·\±\À!µ_×JÐJÈ�Ø×*Ñ*¨3Ó9�Ø—‘˜qÖ!à�MÔ!Ø�O‰O˜HÐ&SÐU`ÐTlÕ&lÖmô
 OˆEÙ˜W“~ˆHÙ˜TŸ\™\Ó*ŠHøô+ ô Ûðús   Á,F ÆF&Æ%F&c                ó4   € \         P                  ! V^RR7      # )é   T)ÚindentÚ	sort_keys)ÚjsonÚdumps)r!   Úobjs   &&r   r8   ÚNotebookTest.dump_canonicalZ   s   € Ü�zŠz˜# a°4Ô8Ð8r   c              #  ór  aa"  € V Fª  p\        V4      pR F’  w  ooVV3R lpRV9   d   V! VR,          4      VR&   RV9   g   K/  \        VR,          \        4      '       d5   VR,          P                  4        F  w  rVV! V4      VR,          V&   K  	  K€  V! VR,          4      VR&   K”  	  Vx € K¬  	  R# 5i)z-
remove all scrubs from output data and text
c                 ó°   <€ \        V 4      '       d   \        P                  ! SSV 4      # V  Uu. uF  p\        P                  ! SSV4      NK  	  up# u upi r
   )r   ÚreÚsub)ÚlinesÚlinerS   ra   s   & €€r   Ú_scrubLinesÚ/NotebookTest.scrub_outputs.<locals>._scrubLinese   sD   ø€ Ü˜U—|’|Ü!Ÿvšv e¨S°%Ó8Ð8áEJÓKÁU¸T¤§¢ u¨c°4Ö 8ÁUÑKÐKùÒKs   ¯!AÚtextÚdataN© )r   r   ÚdictÚitems)	r!   rG   ÚoutputÚoutrd   Úmimerg   rS   ra   s	   &&     @@r   r:   ÚNotebookTest.scrub_outputs]   s©   ùé € ó ˆFÜ�v“,ˆCã ‘
��söLð ˜S”=Ù"-¨c°&­kÓ":�C˜‘Kà˜S–=Ü! # f¥+¬t×4Ò4Ø*-¨f­+×*;Ñ*;Ö*=™J˜DÙ0;¸DÓ0A˜C �K¨Ó-ó +>ñ '2°#°fµ+Ó&>˜˜F›ñ !ð  ŒIó' ùs   „=B7ÁA1B7c                óP   € V P                    F  pVP                  VR4       K  	  V# )z5
remove keys from STRIP_KEYS to ensure comparability
N)Ú
STRIP_KEYSÚpop)r!   ÚdÚkeys   && r   Ú
strip_keysÚNotebookTest.strip_keysv   s%   € ð —?”?ˆCØ�E‰E�#�tÖñ #àˆr   c                óN   € VP                    F  pV P                  V4       K  	  V# )z 
remove non-reproducible things
)rG   rt   )r!   rK   rk   s   && r   r    ÚNotebookTest.sanitize_cell~   s#   € ð —l”lˆFØ�O‰O˜FÖ#ñ #àˆr   c                ó:  € RRRRR//pRVR,          /pVP                  VR,          4       V P                  V4      pVP                  4        F-  w  rVWT9   g   K  WE,          V9   g   K  WdV,          ,          WE&   K/  	  RV9   d   RV9  d   VR,          VR	&   VR V# )
z6
transform a message into something like the notebook
Úoutput_typeÚpyoutÚexecute_resultÚpyerrr2   r1   r3   rg   rf   )Úupdatert   rj   )r!   rM   rQ   Ú	SWAP_KEYSrk   rs   Úswapss   &&&    r   rH   ÚNotebookTest.transform_message†   s©   € ð
 ØÐ)Ø˜ðð
ˆ	ð ˜C 
�Oð
ˆð 	�‰�c˜)•nÔ%à—‘ Ó(ˆØ#Ÿ/™/Ö+‰JˆCØŽ} ¥°Ö!5Ø#¨3¥KÕ0�“ñ ,ð �VÔ ¨hÔ 6Ø# F�^ˆF�6‰NØ�v�àˆr   c                óf   € Vf   R# VR,          R8H  ;'       d    VR,          R,          R8H  '       * # )zA
determine whether the current message is the last for this cell
Tr1   Ústatusr3   Úexecution_stateÚidlerh   )r!   rM   s   &&r   rC   ÚNotebookTest.should_continue¡   sB   € ð Š;Ùà˜
•O xÑ/÷ @ð @Ø˜	•NÐ#4Õ5¸Ñ?ôAð 	Ar   rh   N)Úexecute_requestÚexecute_inputr‚   Úpyin)Úexecution_countÚ	tracebackÚprompt_numberr-   )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__rE   rp   r   r*   r   r8   r:   rt   r    rH   rC   Ú__static_attributes__Ú__classdictcell__)Ú__classdict__s   @r   r   r      sN   ø‡ € ñò J€LÚL€JØÐòMò%+òT9òò2òò÷6Að Ar   r   )Úunittestr   Úipykernel.testsr   Únbformat.converterr   Únbformat.readerr   r`   rZ   r   Úqueuer   r   ÚImportErrorÚQueuer   rh   r   r   Ú<module>r›      sS   ðÝ å !Ý &Ý !ã 	Û Ý Û ð)åò"ôPA�8ö PAøð ô )åô)ð	)ús   ¬	A ÁAÁA