+
    õäûjW  ã                   óT  € R t ^ RIt^ RIt^ RIHtHt ]P                  tR t]	! ]4      ]P                  n        ]P                  P                  ]P                  n        ]P                  ]P                  n        ]P                  ]P                  n        ]P                  ]P                  n        ]P                   ;]P                  n        ]P                  n        ]'       d"   ]! R4      P%                  ]P                  4        ! R R]4      t ! R R]4      t ! R	 R
]4      tR tR# )zÌFix missing-API problems in logging module (circa Python 2.3)

Adds constants to the log objects.
Adds getException(err) to log objects to retrieve 
formatted exception or err if traceback not available.
N)ÚERROR_LOGGINGÚFULL_LOGGINGc                óx   €  \         P                  ! ^
R7      #   \         d   p\        T 4      u Rp?# Rp?ii ; i)z&Get formatted traceback from exception)ÚlimitN)Ú	tracebackÚ
format_excÚ	ExceptionÚstr)ÚerrorÚerrs   & ÚGC:\Ai_Coding\apps\studio\ComfyUI\.venv\Lib\site-packages\OpenGL\logs.pyÚgetExceptionr      s2   € ðÜ×#Ò#¨2Ô/Ð/øÜô Ü�E‹|Õûðús   ‚ ™9¤
4®9´9úOpenGL.calltracec                   ó6   a € ] tR t^t o RtR tR tR tRtV t	R# )Ú_LoggedFunctionz.Proxy that overrides __call__ to log argumentsc                ó>   € WP                   R &   W P                   R&   R# )Ú ÚlogN)Ú__dict__)ÚselfÚbaser   s   &&&r   Ú__init__Ú_LoggedFunction.__init__   s   € Ø �‰�bÑØ"�‰�eÓó    c                ón   € VR 8w  d    \        V P                  R ,          W4       R# W P                  R &   R# )r   N)Úsetattrr   )r   ÚkeyÚvalues   &&&r   Ú__setattr__Ú_LoggedFunction.__setattr__!   s(   € Ø�"Œ9Ü�T—]‘] 2Õ&¨Ö4à %�M‰M˜"Ór   c                óp   € VR 8X  d   V P                   R ,          # \        V P                   R ,          V4      # )r   )r   Úgetattr)r   r   s   &&r   Ú__getattr__Ú_LoggedFunction.__getattr__&   s.   € Ø�"Œ9Ø—=‘= Õ$Ð$ä˜DŸM™M¨"Õ-¨sÓ4Ð4r   © N)
Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r"   Ú__static_attributes__Ú__classdictcell__©Ú__classdict__s   @r   r   r      s   ø‡ € Ù8ò#ò&÷
5ð 5r   r   c                   ó:   a € ] tR t^+t o Rt]! R4      tR tRtV t	R# )Ú_FullLoggedFunctionzHFully-logged function wrapper (logs all call params to OpenGL.calltrace)r   c                ó  € . p\        V R 4      pV F  pVP                  \        V4      4       K  	  VP                  4        F&  w  rgVP                  V: R\        V4      : 24       K(  	  RP	                  V4      pV P
                  P                  RVP                  V4        V! V/ VB #   \         dG   pT P                  P                  RTP                  T P                  P                  T4      4       h Rp?ii ; i)r   z = Ú,z%s( %s )úFailure on %s: %sN)r!   ÚappendÚreprÚitemsÚjoinÚ
_callTraceÚinfor%   r   r   Úwarningr   )	r   ÚargsÚnamedÚargReprÚfunctionÚargr   r   r   s	   &*,      r   Ú__call__Ú_FullLoggedFunction.__call__.   s×   € ØˆÜ˜D "Ó&ˆÛˆCØ�N‰NœD ›IÖ'ñ àŸ™ž‰IˆCØ�N‰N«¬D°­KÐ8Ö:ñ 'à—(‘(˜GÓ%ˆØ�‰×Ñ˜j¨(×*;Ñ*;¸WÔFð	Ù˜dÐ- eÑ-Ð-øÜô 	Ø�H‰H×ÑØ'¨×):Ñ):¸D¿H¹H×<QÑ<QÐSVÓ<Xôð ûð		ús   Â%B- Â-C>Â8AC9Ã9C>r$   N)
r%   r&   r'   r(   r)   ÚgetLogr7   r?   r*   r+   r,   s   @r   r/   r/   +   s   ø‡ € ÙRÙÐ+Ó-€J÷ð r   r/   c                   ó*   a € ] tR t^>t o RtR tRtV tR# )Ú_ErrorLoggedFunctionz On-error-logged function wrapperc                óÔ   € \        V R 4      p V! V/ VB #   \         dG   pT P                  P                  RTP                  T P                  P                  T4      4       h Rp?ii ; i)r   r2   N)r!   r   r   r9   r%   r   )r   r:   r;   r=   r   s   &*,  r   r?   Ú_ErrorLoggedFunction.__call__@   sg   € Ü˜D "Ó&ˆð	Ù˜dÐ- eÑ-Ð-øÜô 	Ø�H‰H×ÑØ'¨×):Ñ):¸D¿H¹H×<QÑ<QÐSVÓ<Xôð ûð		ús   Ž –A'¡AA"Á"A'r$   N)r%   r&   r'   r(   r)   r?   r*   r+   r,   s   @r   rC   rC   >   s   ø‡ € Ù*÷ð r   rC   c                ó‚   € \         '       g   \        '       d'   \        '       d   \        W4      pV# \        W4      pV# V # )zÛProduce possible log-wrapped version of function

function -- callable object to be wrapped
log -- the log to which to log information

Uses ERROR_LOGGING and FULL_LOGGING
to determine whether/how to wrap the function.
)r   r   r/   rC   )r=   r   ÚloggedFunctions   && r   Ú	logOnFailrH   K   s;   € ÷ ƒ}Ÿ›ß‹<Ü0°(ÓAˆNð Ðô 2°8ÓBˆNØÐàˆr   )r)   r   ÚloggingÚOpenGL._configflagsr   r   Ú	getLoggerrA   r   ÚstaticmethodÚLoggerr
   r   ÚDEBUGÚWARNÚINFOÚERRORÚERRÚsetLevelÚobjectr   r/   rC   rH   r$   r   r   Ú<module>rU      sÛ   ðñ÷ ß ;Ø	×	Ñ	€òñ +¨LÓ:€‡�Ô Ø—^‘^×)Ñ)€‡�Ô Ø—}‘}€‡�Ô Ø—l‘l€‡�Ô Ø—l‘l€‡�Ô Ø,3¯M©MÐ 9€‡�Ô �W—^‘^Ô)çÙ
ÐÓ ×)Ñ)¨7¯<©<Ô9ô5�vô 5ô˜?ô ô&
˜_ô 
ôr   