%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3.9/site-packages/ansible/_vendor/jinja2/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3.9/site-packages/ansible/_vendor/jinja2/__pycache__/exceptions.cpython-39.pyc

a

��+b��@s�ddlZejrddlmZGdd�de�ZGdd�deee�Z	Gdd	�d	e	�Z
Gd
d�de�ZGdd
�d
e�ZGdd�de�Z
Gdd�de
�ZGdd�de
�ZGdd�de
�ZdS)�N���	UndefinedcsHeZdZdZd	ejedd��fdd�
Zeejed�dd��Z	�Z
S)
�
TemplateErrorz"Baseclass for all template errors.N)�message�returncst��|�dS�N)�super�__init__)�selfr��	__class__��E/usr/lib/python3.9/site-packages/ansible/_vendor/jinja2/exceptions.pyr

szTemplateError.__init__�rcCs|jr|jdSdS)Nr)�args�rrrrr
szTemplateError.message)N)�__name__�
__module__�__qualname__�__doc__�t�Optional�strr
�propertyr�
__classcell__rrrrrsrc@s\eZdZUdZdZejeed<dejej	edfejedd�dd�Z
ed�d	d
�ZdS)�TemplateNotFoundz�Raised if a template does not exist.

    .. versionchanged:: 2.11
        If the given name is :class:`Undefined` and no message was
        provided, an :exc:`UndefinedError` is raised.
    Nrr)�namerrcCsNt�||�|dur6ddlm}t||�r2|��|}||_||_|g|_dS)Nrr)	�IOErrorr
�runtimer�
isinstanceZ_fail_with_undefined_errorrr�	templates)rrrrrrrr
s
zTemplateNotFound.__init__rcCs
t|j�Sr)rrrrrr�__str__1szTemplateNotFound.__str__)N)rrrrrrrr�__annotations__�Unionr
r"rrrrrs
	��rcsBeZdZdZdejejedfejedd��fdd�
Z	�Z
S)	�TemplatesNotFounda�Like :class:`TemplateNotFound` but raised if multiple templates
    are selected.  This is a subclass of :class:`TemplateNotFound`
    exception, so just catching the base exception will catch both.

    .. versionchanged:: 2.11
        If a name in the list of names is :class:`Undefined`, a message
        about it being undefined is shown rather than the empty string.

    .. versionadded:: 2.2
    rNr)�namesrrcs�|dur^ddlm}g}|D]&}t||�r8|�|j�q|�|�qd�tt|��}d|��}t��	|rp|dnd|�t
|�|_dS)Nrrz, z(none of the templates given were found: ���)rrr �appendZ_undefined_message�join�maprr	r
�listr!)rr&rr�partsrZ	parts_strrrrr
As

zTemplatesNotFound.__init__)rN)rrrrr�Sequencer$rrr
rrrrrr%5s
��r%csReZdZdZdeeejeejedd��fdd�
Zed�dd�Z	d	d
�Z
�ZS)�TemplateSyntaxErrorzBRaised to tell the user that there is a problem with the template.N)r�linenor�filenamercs.t��|�||_||_||_d|_d|_dS)NF)r	r
r/rr0�source�
translated)rrr/rr0rrrr
[szTemplateSyntaxError.__init__rcCs�|jrt�t|j�Sd|j��}|jp*|j}|r@d|�d|��}t�t|j�d|g}|jdur�z|j�	�|jd}Wnt
y�Yn0|�d|���d�
|�S)Nzline zFile "z", z  rz    �
)r2r�castrrr/r0rr1�
splitlines�
IndexErrorr(�stripr))r�locationr�lines�linerrrr"ls
zTemplateSyntaxError.__str__cCs|j|j|j|j|jffSr)r
rr/rr0rrrr�
__reduce__�szTemplateSyntaxError.__reduce__)NN)rrrrr�intrrr
r"r;rrrrrr.Xs��r.c@seZdZdZdS)�TemplateAssertionErroraLike a template syntax error, but covers cases where something in the
    template caused an error at compile time that wasn't necessarily caused
    by a syntax error.  However it's a direct subclass of
    :exc:`TemplateSyntaxError` and has the same attributes.
    N�rrrrrrrrr=�sr=c@seZdZdZdS)�TemplateRuntimeErrorzoA generic runtime error in the template engine.  Under some situations
    Jinja may raise this exception.
    Nr>rrrrr?�sr?c@seZdZdZdS)�UndefinedErrorz<Raised if a template tries to operate on :class:`Undefined`.Nr>rrrrr@�sr@c@seZdZdZdS)�
SecurityErrorzWRaised if a template tries to do something insecure if the
    sandbox is enabled.
    Nr>rrrrrA�srAc@seZdZdZdS)�FilterArgumentErrorzQThis error is raised if a filter was called with inappropriate
    arguments
    Nr>rrrrrB�srB)�typingr�
TYPE_CHECKINGrr�	Exceptionrr�LookupErrorrr%r.r=r?r@rArBrrrr�<module>s##3

Zerion Mini Shell 1.0