Current File : //usr/lib/python3/dist-packages/jmespath/__pycache__/exceptions.cpython-312.pyc
�

>��a ���ddlmZGd�de�ZeGd�de��ZeGd�de��ZeGd�d	e��ZeGd
�de��ZeGd�d
e��ZeGd�de��Z	Gd�de�Z
Gd�de�Zy)�)�with_str_methodc��eZdZy)�
JMESPathErrorN��__name__�
__module__�__qualname__���5/usr/lib/python3/dist-packages/jmespath/exceptions.pyrr���rrc�,��eZdZdZef�fd�	Zd�Z�xZS)�
ParseErrorzInvalid jmespath expressionc���tt|�|||�||_||_|j�|_||_d|_y�N)	�superr�__init__�lex_position�token_value�upper�
token_type�msg�
expression)�selfrrrr�	__class__s     �rrzParseError.__init__sD���
�j�$�(��{�J�O�(���&���$�*�*�,��������rc��d|jdzzdz}|j�d|j�d|j�d|j�d|j�d|��S)	N� ��^z: Parse error at column z	, token "z" (z), for expression:
"�"
)rrrrr�r�	underlines  r�__str__zParseError.__str__sN���4�,�,�q�0�1�C�7�	����$�+�+�T�-=�-=�t�������
,�	-r)rrr	�_ERROR_MESSAGErr#�
__classcell__�rs@rrrs���2�N�#��-rrc��eZdZd�Zd�Zy)�IncompleteExpressionErrorc�N�||_t|�|_d|_d|_yr)r�lenrrr)rrs  r�set_expressionz(IncompleteExpressionError.set_expression!s$��$����
�O��������rc�P�d|jdzzdz}d|j�d|��S)Nrrrz5Invalid jmespath expression: Incomplete expression:
"r )rrr!s  rr#z!IncompleteExpressionError.__str__'s1���4�,�,�q�0�1�C�7�	��/�/�9�
6�	7rN)rrr	r+r#r
rrr(r(s�� �7rr(c�&��eZdZd�fd�	Zd�Z�xZS)�
LexerErrorc�h��||_||_||_tt|�|||�||_yr)�lexer_position�lexer_value�messagerr.rr)rr0r1r2rrs     �rrzLexerError.__init__1s:���,���&������
�j�$�(��)4�)0�	2�%��rc�d�d|jzdz}d|j�d|j�d|��S)NrrzBad jmespath expression: z:
�
)r0r2rr!s  rr#zLexerError.__str__;s0���$�-�-�-��3�	��L�L�$�/�/�9�6�	6rr)rrr	rr#r%r&s@rr.r./s
���%�6rr.c��eZdZd�Zd�Zd�Zy)�
ArityErrorc�<�||_||_||_d|_yr)�expected_arity�actual_arity�
function_namer)r�expected�actual�names    rrzArityError.__init__Cs!��&���"���!�����rc��d|j�d|jd|j��d|j�d|j��S)Nz	Expected r�argument� for function �
(), received �r8�
_pluralizer:r9�rs rr#zArityError.__str__I�=���'�'��O�O�J��0C�0C�D��&�&��%�%�'�	(rc��|dk(r|S|dzS)Nr�sr
)r�word�counts   rrCzArityError._pluralizeQs���A�:��K��#�:�rN)rrr	rr#rCr
rrr6r6As���(�rr6c��eZdZd�Zy)�VariadictArityErrorc��d|j�d|jd|j��d|j�d|j��S)NzExpected at least rr?r@rArBrDs rr#zVariadictArityError.__str__ZrErN)rrr	r#r
rrrKrKXs��(rrKc��eZdZd�Zd�Zy)�JMESPathTypeErrorc�<�||_||_||_||_yr)r:�
current_value�actual_type�expected_types)rr:rPrQrRs     rrzJMESPathTypeError.__init__es"��*���*���&���,��rc	�p�d|j�d|j�d|j�d|j�d�	S)NzIn function z(), invalid type for value: z, expected one of: z
, received: "�")r:rPrRrQrDs rr#zJMESPathTypeError.__str__ls0���&�&��(:�(:��'�'��)9�)9�;�	<rN)rrr	rr#r
rrrNrNcs��-�<rrNc���eZdZ�fd�Z�xZS)�EmptyExpressionErrorc�,��tt|�d�y)Nz-Invalid JMESPath expression: cannot be empty.)rrVr)rrs �rrzEmptyExpressionError.__init__ts���
�"�D�2�;�	=r)rrr	rr%r&s@rrVrVss
���=�=rrVc��eZdZy)�UnknownFunctionErrorNrr
rrrYrYyr
rrYN)�jmespath.compatr�
ValueErrorrrr(r.r6rKrNrVrYr
rr�<module>r\s���+�	�J�	��-��-��-�,�7�
�7��7��6��6��6�"������,�(�*�(��(��<�
�<��<�=�=�=�	�=�	r