
    6Dh                          " S  S\ 5      r " S S\5      r " S S\5      r " S S\5      r " S S	\5      r " S
 S\5      r " S S\5      r " S S\5      r	g)c                       \ rS rSrSrg)PlotlyError    N__name__
__module____qualname____firstlineno____static_attributes__r       J/var/www/html/env/lib/python3.13/site-packages/_plotly_utils/exceptions.pyr   r          r   r   c                       \ rS rSrSrg)PlotlyEmptyDataError   r   Nr   r   r   r   r   r      r   r   r   c                   2   ^  \ rS rSrSU 4S jjrS rSrU =r$ )PlotlyGraphObjectError	   c                 p   > Xl         Xl        [        U5      U l        X0l        [
        [        U ]  U5        g)z
General graph object error for validation failures.

:param (str|unicode) message: The error message.
:param (iterable) path: A path pointing to the error.
:param notes: Add additional notes, but keep default exception message.

N)messageplain_messagelistpathnotessuperr   __init__)selfr   r   r   	__class__s       r   r   PlotlyGraphObjectError.__init__
   s0     $J	
$d4W=r   c                     U R                   SSR                  S U R                   5       5      -   S-   SR                  U R                  5      S.nSR                  " S0 UD6$ )	z6This is called by Python to present the error message.[z][c              3   8   #    U  H  n[        U5      v   M     g 7fN)repr).0ks     r   	<genexpr>1PlotlyGraphObjectError.__str__.<locals>.<genexpr>   s     #?YDGGYs   ]
r   r   r   z){message}

Path To Error: {path}

{notes}r   )r   joinr   r   format)r   format_dicts     r   __str__PlotlyGraphObjectError.__str__   sX     ||$))#?TYY#???#EYYtzz*

 ?EETTTr   )r   r   r   r   ) r   r   )r   r   r	   r
   r   r/   r   __classcell__r   s   @r   r   r   	   s    >U Ur   r   c                   ,   ^  \ rS rSrSU 4S jjrSrU =r$ )PlotlyDictKeyError#   r   c                    > US   UR                   S.nSR                  " S0 UD6nUR                  SS9/[        U5      -   n[        [
        U ]  XRUS9  g)	3See PlotlyGraphObjectError.__init__ for param docs.	attributeobject_namez/'{attribute}' is not allowed in '{object_name}'Treturn_helpr+   Nr   )_namer-   helpr   r   r5   r   r   objr   r   r.   r   r   s         r   r   PlotlyDictKeyError.__init__$   se    $(HSYYGCJJ 

 d+,tE{: $0e 	1 	
r   r   r   r   r	   r
   r   r   r2   r3   s   @r   r5   r5   #       	
 	
r   r5   c                   ,   ^  \ rS rSrSU 4S jjrSrU =r$ )PlotlyDictValueError0   r   c                    > US   UR                   S.nSR                  " S0 UD6nUR                  US   SS9/[        U5      -   n[        [
        U ]  XSUS9  g)	r8   r9   r:   z6'{attribute}' has invalid value inside '{object_name}'Tr=   )r   r   r   Nr   )r?   r-   r@   r   r   rH   r   rA   s         r   r   PlotlyDictValueError.__init__1   sk    $(HSYYGJQQ 

 $r(56eD"D2t 	3 	
r   rD   rE   r3   s   @r   rH   rH   0   rF   r   rH   c                   ,   ^  \ rS rSrSU 4S jjrSrU =r$ )PlotlyListEntryError=   r   c                    > US   UR                   S.nSR                  " S0 UD6nUR                  SS9/[        U5      -   n[        [
        U ]  XRUS9  g)	r8   r9   indexr<   :Invalid entry found in '{object_name}' at index, '{index}'Tr=   r+   Nr   )r?   r-   r@   r   r   rM   r   rA   s         r   r   PlotlyListEntryError.__init__>   se     $RCNUU 

 d+,tE{:"D2e 	3 	
r   rD   rE   r3   s   @r   rM   rM   =   rF   r   rM   c                   ,   ^  \ rS rSrSU 4S jjrSrU =r$ )PlotlyDataTypeErrorJ   r   c                    > US   UR                   S.nSR                  " S0 UD6nSnU/[        U5      -   n[        [        U ]  XRUS9  g)r8   r9   rP   rR   z=It's invalid because it doesn't contain a valid 'type' value.r+   Nr   )r?   r-   r   r   rU   r   )r   rB   r   r   r.   r   noter   s          r   r   PlotlyDataTypeError.__init__K   s_     $RCNUU 

 Oe$!41e 	2 	
r   rD   rE   r3   s   @r   rU   rU   J   s    

 

r   rU   c                       \ rS rSrSrS rSrg)PlotlyKeyErrorX   z
KeyErrors are not printed as beautifully as other errors (this is so that
{}[''] prints    "KeyError: ''" and not "KeyError:"). So here we use
LookupError's __str__ to make a PlotlyKeyError object which will print nicer
error messages for KeyErrors.
c                 ,    [         R                  U 5      $ r#   )LookupErrorr/   )r   s    r   r/   PlotlyKeyError.__str__`   s    ""4((r   r   N)r   r   r	   r
   __doc__r/   r   r   r   r   r[   r[   X   s    )r   r[   N)
	Exceptionr   r   r   r5   rH   rM   rU   KeyErrorr[   r   r   r   <module>rc      sk   	) 		; 	U[ U4

/ 



1 



1 


0 
	)X 	)r   