%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /snap/core20/2599/lib/python3/dist-packages/jinja2/__pycache__/
Upload File :
Create Path :
Current File : //snap/core20/2599/lib/python3/dist-packages/jinja2/__pycache__/exceptions.cpython-38.pyc

U

aG�\L�@s�dZddlmZmZmZmZGdd�de�ZeGdd�dee	e��Z
Gdd�de
�ZeGd	d
�d
e��ZGdd�de�Z
Gd
d�de�ZGdd�de�ZGdd�de�ZGdd�de�ZdS)z�
    jinja2.exceptions
    ~~~~~~~~~~~~~~~~~

    Jinja exceptions.

    :copyright: (c) 2017 by the Jinja Team.
    :license: BSD, see LICENSE for more details.
�)�imap�	text_type�PY2�implements_to_stringc@sJeZdZdZer0ddd�Zedd��Zdd�Zndd	d�Zed
d��ZdS)
�
TemplateErrorz"Baseclass for all template errors.NcCs&|dk	rt|��d�}t�||�dS)N�utf-8)r�encode�	Exception�__init__��self�message�r�3/usr/lib/python3/dist-packages/jinja2/exceptions.pyr
szTemplateError.__init__cCs(|jr$|jd}|dk	r$|�dd�SdS)Nrr�replace)�args�decoderrrrr
s
zTemplateError.messagecCs
|jpdS)N��r
�rrrr�__unicode__szTemplateError.__unicode__cCst�||�dS�N)r	r
rrrrr
!scCs |jr|jd}|dk	r|SdS)Nr)rrrrrr
$s
)N)N)	�__name__�
__module__�__qualname__�__doc__rr
�propertyr
rrrrrrs



rc@s&eZdZdZdZddd�Zdd�ZdS)�TemplateNotFoundz$Raised if a template does not exist.NcCs.t�|�|dkr|}||_||_|g|_dSr)�IOErrorr
r
�name�	templates)rrr
rrrr
4s
zTemplateNotFound.__init__cCs|jSrrrrrr�__str__<szTemplateNotFound.__str__)N)rrrrr
r
r!rrrrr,s
rc@seZdZdZddd�ZdS)�TemplatesNotFoundz�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.

    .. versionadded:: 2.2
    rNcCsD|dkrdd�tt|��}t�||r.|dp0d|�t|�|_dS)Nz(none of the templates given were found: z, ���)�joinrrrr
�listr )r�namesr
rrrr
Hs�zTemplatesNotFound.__init__)rN)rrrrr
rrrrr"@sr"c@s"eZdZdZddd�Zdd�ZdS)�TemplateSyntaxErrorzBRaised to tell the user that there is a problem with the template.NcCs.t�||�||_||_||_d|_d|_dS)NF)rr
�linenor�filename�source�
translated)rr
r(rr)rrrr
TszTemplateSyntaxError.__init__cCs�|jr|jSd|j}|jp |j}|r2d||f}|jd|g}|jdk	r�z|j��|jd}Wntk
rzd}YnX|r�|�d|�	��d�
|�S)Nzline %dz
File "%s", %sz  �z    �
)r+r
r(r)rr*�
splitlines�
IndexError�append�stripr$)r�locationr�lines�linerrrr!_s


zTemplateSyntaxError.__str__)NN)rrrrr
r!rrrrr'Ps
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�rrrrrrrrr5wsr5c@seZdZdZdS)�TemplateRuntimeErrorzoA generic runtime error in the template engine.  Under some situations
    Jinja may raise this exception.
    Nr6rrrrr7sr7c@seZdZdZdS)�UndefinedErrorz<Raised if a template tries to operate on :class:`Undefined`.Nr6rrrrr8�sr8c@seZdZdZdS)�
SecurityErrorzWRaised if a template tries to do something insecure if the
    sandbox is enabled.
    Nr6rrrrr9�sr9c@seZdZdZdS)�FilterArgumentErrorzQThis error is raised if a filter was called with inappropriate
    arguments
    Nr6rrrrr:�sr:N)rZjinja2._compatrrrrr	rr�LookupErrorrr"r'r5r7r8r9r:rrrr�<module>s	&

Zerion Mini Shell 1.0