/usr/local/lib/python3.6/site-packages/jinja2/__pycache__
NameSizeModeActions
async_utils.cpython-36.pyc24350644editdlrm
bccache.cpython-36.pyc130970644editdlrm
compiler.cpython-36.pyc543690644editdlrm
constants.cpython-36.pyc14960644editdlrm
debug.cpython-36.pyc53440644editdlrm
defaults.cpython-36.pyc12410644editdlrm
environment.cpython-36.pyc523970644editdlrm
exceptions.cpython-36.pyc54980644editdlrm
ext.cpython-36.pyc262740644editdlrm
filters.cpython-36.pyc497540644editdlrm
idtracking.cpython-36.pyc111250644editdlrm
lexer.cpython-36.pyc199830644editdlrm
loaders.cpython-36.pyc202170644editdlrm
meta.cpython-36.pyc37460644editdlrm
nativetypes.cpython-36.pyc48050644editdlrm
nodes.cpython-36.pyc411930644editdlrm
optimizer.cpython-36.pyc18610644editdlrm
parser.cpython-36.pyc276350644editdlrm
runtime.cpython-36.pyc328630644editdlrm
sandbox.cpython-36.pyc116960644editdlrm
tests.cpython-36.pyc64820644editdlrm
utils.cpython-36.pyc272170644editdlrm
visitor.cpython-36.pyc38390644editdlrm
_identifier.cpython-36.pyc18500644editdlrm
__init__.cpython-36.pyc18650644editdlrm
Edit: /usr/local/lib/python3.6/site-packages/jinja2/__pycache__/runtime.cpython-36.pyc (32863B)
3 ^TBg@s2dZddlZddlZddlZddlmZddlmZddl m Z ddl m Z ddl m Z dd l mZdd l mZdd lmZdd lmZdd lmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZejdZejdej dej!fdZ"ej#rNddl$Z$ddl%Z&ddl'm(Z(Gddde&j)Z*dddd d!d"d#d$d%d&d'd(d)d*d+gZ+d,d-d.gZ,eed/d0d'Z-ej.ej!e/d1d2d%Z0ej.ej!e/d1d3d&Z1ej.ej!e/d1d4d5Z2dQd7ej3e/ej4e/ej d8gej5e/ffej3ej4e/ej!fe6ej3ej7e/ej!fej3ej8e/ej!fd8d9d:d;Z9Gdd?Z;ej8jGdCddZ?GdDd,d,e?Z@GdEddZAGdFd*d*ZBdeBfej3dGejCeBejCeBdHdIdJZDGdKdLdLeBZEGdMdNdNeBZFGdOdPdPeBZGeB`HeE`HeF`HeG`HdS)Rz;The runtime functions and state used by compiled templates.N)abc)chain)escape)Markup)soft_str) auto_aiter) auto_await)TemplateNotFound)TemplateRuntimeError)UndefinedError) EvalContext)_PassArg)concat) internalcode)missing) Namespace)object_type_repr)pass_eval_contextVF.)Zbound) Environmentc@s(eZdZdejedeedddZdS)LoopRenderFuncr)reciterloop_render_funcdepthreturncCsdS)N)selfrrrrr0/tmp/pip-build-0s3hx122/Jinja2/jinja2/runtime.py__call__#szLoopRenderFunc.__call__N)r) __name__ __module__ __qualname__tIterablerintstrr rrrrr"sr LoopContextTemplateReferenceMacrorr rrr markup_joinstr_joinidentityr r UndefinedrAsyncLoopContextrr )xrcCs|S)zLReturns its argument. Useful for certain things in the environment. r)r0rrrr-Es)seqrcCsLg}tt|}x4|D],}|j|t|drtdjt||SqWt|S)z?Concatenation that escapes if necessary and converts to string.__html__)maprappendhasattrrjoinrr)r1bufiteratorargrrrr+Ls    cCsttt|S)z3Simple args to string conversion and concatenation.)rr4r')r1rrrr,WscCs ddl}|jdtddt|S)NrzWThis template must be recompiled with at least Jinja 3.0, or it will fail in Jinja 3.1.) stacklevel)warningswarnDeprecationWarningr,)r1r=rrr unicode_join\s r@FrContext) environment template_nameblocksvarssharedglobalslocalsrc Csp|dkr i}|r|}nt|pff|}|r\|r6t|}x$|jD]\}} | tk r@| ||<q@W|j|||||dS)z%Internal helper for context creation.N)rG)dictitemsrZ context_class) rBrCrDrErFrGrHparentkeyvaluerrr new_contexths  rNc@s@eZdZdZdddddZeejddd Zed d d Z dS) r)zThe `self` in templates.rAN)contextrcCs ||_dS)N)_TemplateReference__context)rrOrrr__init__szTemplateReference.__init__)namercCs|jj|}t||j|dS)Nr)rPrDBlockReference)rrRrDrrr __getitem__s zTemplateReference.__getitem__)rcCsdt|jd|jjdS)N< >)typer!rPrR)rrrr__repr__szTemplateReference.__repr__) r!r"r#__doc__rQr'r$AnyrTrYrrrrr)s) dict_methodrcs,tjdtjdfdd }tjt|S)NrA)rrcs |jS)N)get_all)r)r\rrf_allsz_dict_method_all..f_all) functoolswrapsr$r[castr)r\r^r)r\r_dict_method_allsrbc @seZdZUdZdZejeddddZd)dej e ej fej e ej e ej dgeje ffej eje ej fdd d Ze ej dgeje fejd*d ddZd+e ej ej dddZe ejej d fdddZe ej dddZej e ej fdddZej e ej fdddZeej ej ej ejej d fdddZd,ej ej e ej fddd d!ZeejZeejZeejZe ed"d#d$Z e ej dd%d&Z!e dd'd(Z"dS)-rAaThe template context holds the variables of a template. It stores the values passed to the template and also the names the template exports. Creating instances is neither supported nor useful as it's created automatically at various stages of the template evaluation and should not be created by hand. The context is immutable. Modifications on :attr:`parent` **must not** happen and modifications on :attr:`vars` are allowed from generated template code only. Template filters and global functions marked as :func:`pass_context` get the active context passed as first argument and are allowed to access the context read-only. The template context supports read only dict operations (`get`, `keys`, `values`, `items`, `iterkeys`, `itervalues`, `iteritems`, `__getitem__`, `__contains__`). Additionally there is a :meth:`resolve` method that doesn't fail with a `KeyError` but returns an :class:`Undefined` object for missing variables. FN)rcCsDd|jkrd|_n.d|jks"|jr@ddl}|jdtddd|_dS) Nresolve_or_missingFresolverzOverriding 'resolve' is deprecated and will not have the expected behavior in Jinja 3.1. Override 'resolve_or_missing' instead r;)r<T)__dict___legacy_resolve_moder=r>r?)clsr=rrr__init_subclass__s zContext.__init_subclass__r)rBrKrRrDrGcCs^||_i|_||_t|j||_t|_||_|dkrsz$Context.__init__..) rKrErBr eval_ctxset exported_varsrRZ globals_keysrJrD)rrBrKrRrDrGrrrrQszContext.__init__rSr.)rRcurrentrc Cs\y$|j|}|j|d}||Wn(tk rL|jjd|dddSXt||||S)zRender a parent block.rz there is no parent block called .super)rR)rDindex LookupErrorrB undefinedrS)rrRrprDrsrrrrrs  z Context.super)rLdefaultrc Cs"y||Stk r|SXdS)zLook up a variable by name, or return a default if the key is not found. :param key: The variable name to look up. :param default: The value to return if the key is not found. N)KeyError)rrLrvrrrgetsz Context.get)rLrcCs`|jr<||jkr|j|S||jkr.|j|S|jj|dS|j|}|tkr\|jj|dS|S)aNLook up a variable by name, or return an :class:`Undefined` object if the key is not found. If you need to add custom behavior, override :meth:`resolve_or_missing`, not this method. The various lookup functions use that method, not this one. :param key: The variable name to look up. )rR)rfrErKrBrurcr)rrLrvrrrrds      zContext.resolvecCsN|jr"|j|}t|trtS|S||jkr6|j|S||jkrJ|j|StS)aNLook up a variable by name, or return a ``missing`` sentinel if the key is not found. Override this method to add custom lookup behavior. :meth:`resolve`, :meth:`get`, and :meth:`__getitem__` use this method. Don't call this method directly. :param key: The variable name to look up. )rfrd isinstancer.rrErK)rrLryrrrrcs       zContext.resolve_or_missingcsfddjDS)z+Get a new dict with the exported variables.csi|]}j||qSr)rE)rirj)rrrrl*sz(Context.get_exported..)ro)rr)rr get_exported(szContext.get_exportedcCs(|js |jS|js|jSt|jf|jS)zReturn the complete context as dict including the exported variables. For optimizations reasons this might not return an actual copy so be careful with using it. )rErKrI)rrrrr],s zContext.get_all) _Context__objargskwargsrc Osd}t|dr$tj|jdk r$|j}tj|}|tjkrt|jdrP|j|d}|jdrh|j|d}|f|}n.|tjkr|jf|}n|tj kr|j f|}|j dd|j ddy |||St k r|j j dSXdS)zCall the callable with the arguments and keyword arguments provided but inject the active context or environment as first argument if the callable has :func:`pass_context` or :func:`pass_environment`. Tr NZ _loop_varsZ _block_varszGvalue was undefined because a callable raised a StopIteration exception) r6rZfrom_objr rOrxderivedZ eval_contextrmrBpop StopIterationru)Z_Context__selfr|r}r~Z__traceback_hide__Zpass_argrrrcall7s,             z Context.call)rHrcCsDt|j|ji|jdd|}|j|_|jjdd|jjD|S)zInternal helper function to create a derived context. This is used in situations where the system needs a new context in the same template that is independent. TNcss|]\}}|t|fVqdS)N)list)rirjrkrrr msz"Context.derived..)rNrBrRr]rmrDupdaterJ)rrHrOrrrrds zContext.derived)rRrcCs||jkp||jkS)N)rErK)rrRrrr __contains__tszContext.__contains__cCs|j|}|tkrt||S)zpLook up a variable by name with ``[]`` syntax, or raise a ``KeyError`` if the key is not found. )rcrrw)rrLitemrrrrTws zContext.__getitem__cCs$dt|jd|jd|jdS)NrUrVz of rW)rXr!r]rR)rrrrrYszContext.__repr__)N)rSr.)N)N)#r!r"r#rZrfr$ZClassVarboolrhDictr'r[OptionalCallableIteratorMutableMappingrQUnionrrrxrdrcr{r]rrrrbrIkeysvaluesrJrrTrYrrrrrAs* X    *$    c@szeZdZdZedejejdgejefe ddddZ e ej ddd d Z eedd d Zeedd dZdS)rSz"One block on a template reference.rAN)rRrOstackrrcCs||_||_||_||_dS)N)rR_context_stack_depth)rrRrOrrrrrrQszBlockReference.__init__r.)rcCsJ|jdt|jkr0|jjjd|jdddSt|j|j|j|jdS)zSuper the block.rz there is no parent block called rqrr)rR)rlenrrrBrurRrS)rrrrrrszBlockReference.supercs@tdd|j|j|j2dHIdH}|jjjrs z.BlockReference._async_call..)rrrrrm autoescaper)rryrrr _async_calls ( zBlockReference._async_callcCs>|jjjr|jSt|j|j|j}|jjjr:t |S|S)N) rrBis_asyncrrrrrmrr)rryrrrr s   zBlockReference.__call__)rSr.)r!r"r#rZr'r$Listrrr&rQpropertyrrrrrr rrrrrSs rSc@seZdZUdZd2ZdZejee Z ej  e Z ej  e Z ej  e Zej d3ejeejdejdedddd Zeejeejed d d Zeed ddZed ddZeed ddZeed ddZeed ddZeed ddZeed ddZej d ddZeed ddZ eej!ej dfd d d!Z"eej!ej dfd d"d#Z#eed$d%d&Z$ej ed'd(d)Z%dd d*d+Z&ej'ej dfd d,d-Z(e)ejee*d d.d/Z+e*d d0d1Z,dS)4r(zeA wrapper iterable for dynamic ``for`` loops, with information about the loop and iteration. rNrr.r)iterablerurecursedepth0rcCs(||_|j||_||_||_||_dS)a@ :param iterable: Iterable to wrap. :param undefined: :class:`Undefined` class to use for next and previous items. :param recurse: The function to render the loop body when the loop is marked recursive. :param depth0: Incremented when looping recursively. N) _iterable _to_iterator _iterator _undefined_recurser)rrrurrrrrrQs  zLoopContext.__init__)rrcCst|S)N)iter)rrrrrszLoopContext._to_iterator)rc Csl|jdk r|jSyt|j|_WnDtk rdt|j}|j||_t||j|jt k |_YnX|jS)zLength of the iterable. If the iterable is a generator or otherwise does not have a size, it is eagerly evaluated to get a size. N) _lengthrr TypeErrorrrrrs_afterr)rrrrrlengths    zLoopContext.lengthcCs|jS)N)r)rrrr__len__szLoopContext.__len__cCs |jdS)zBHow many levels deep a recursive loop currently is, starting at 1.r)r)rrrrrszLoopContext.depthcCs |jdS)z-Current iteration of the loop, starting at 1.r)index0)rrrrrsszLoopContext.indexcCs |j|jS)zrNumber of iterations from the end of the loop, ending at 0. Requires calculating :attr:`length`. )rrs)rrrr revindex0szLoopContext.revindex0cCs |j|jS)zrNumber of iterations from the end of the loop, ending at 1. Requires calculating :attr:`length`. )rr)rrrrrevindexszLoopContext.revindexcCs |jdkS)z0Whether this is the first iteration of the loop.r)r)rrrrfirstszLoopContext.firstcCs$|jtk r|jSt|jt|_|jS)a Return the next element in the iterable, or :data:`missing` if the iterable is exhausted. Only peeks one item ahead, caching the result in :attr:`_last` for use in subsequent checks. The cache is reset when :meth:`__next__` is called. )rrnextr)rrrr _peek_nexts zLoopContext._peek_nextcCs |jtkS)zWhether this is the last iteration of the loop. Causes the iterable to advance early. See :func:`itertools.groupby` for issues this can cause. The :func:`groupby` filter avoids that issue. )rr)rrrrlastszLoopContext.lastcCs|jr|jdS|jS)zZThe item in the previous iteration. Undefined during the first iteration. zthere is no previous item)rr_before)rrrrprevitem)s zLoopContext.previtemcCs|j}|tkr|jdS|S)a The item in the next iteration. Undefined during the last iteration. Causes the iterable to advance early. See :func:`itertools.groupby` for issues this can cause. The :func:`jinja-filters.groupby` filter avoids that issue. zthere is no next item)rrr)rryrrrnextitem3s  zLoopContext.nextitem)r}rcGs|s td||jt|S)zReturn a value from the given args, cycling through based on the current :attr:`index0`. :param args: One or more values to cycle through. zno items for cycling given)rrr)rr}rrrcycleCszLoopContext.cycle)rMrcGs|j|kr||_dSdS)zReturn ``True`` if previously called with a different value (including when called for the first time). :param value: One or more values to compare to the last call. TF)_last_changed_value)rrMrrrchangedNs zLoopContext.changedcCs|S)Nr)rrrr__iter__ZszLoopContext.__iter__cCsF|jtk r|j}t|_n t|j}|jd7_|j|_||_||fS)Nr)rrrrr_currentr)rryrrr__next__]s  zLoopContext.__next__cCs&|jdkrtd|j||j|jdS)zWhen iterating over nested data, render the body of the loop recursively with the given inner iterable data. The loop must have the ``recursive`` marker for this to work. NzCThe loop must have the 'recursive' marker to be called recursively.)r)rrr)rrrrrr is zLoopContext.__call__cCs"dt|jd|jd|jdS)NrUrV/rW)rXr!rsr)rrrrrYwszLoopContext.__repr__)Nr)-r!r"r#rZrrr$rr&rrr[rrrr%rTyperQ staticmethodrrrrrrrsrrrrrrrrrrrrTuplerrr'r rYrrrrr(sN            c@seZdZUejejeejej e ej e feje dddZ e edddZe edddZe edd d Zejdd d Ze edd dZe ejejdfdddZddddZejejdfdddZdS)r/)rrcCst|S)N)r)rrrrr~szAsyncLoopContext._to_iterator)rc s||jdk r|jSyt|j|_WnTtk rtdd|j2dHIdH}|j||_t||j|jtk |_YnX|jS)Nc s.g|y 3dH}Wn tk s"X|qYS)N)r)rir0rrrrs z+AsyncLoopContext.length..) rrrrrrrsrr)rrrrrrs   zAsyncLoopContext.lengthcs|jIdH|jS)N)rrs)rrrrrszAsyncLoopContext.revindex0cs|jIdH|jS)N)rr)rrrrrszAsyncLoopContext.revindexc sH|jtk r|jSy|jjIdH|_Wntk r@t|_YnX|jS)N)rrr __anext__r)rrrrrs  zAsyncLoopContext._peek_nextcs|jIdHtkS)N)rr)rrrrrszAsyncLoopContext.lastr.cs$|jIdH}|tkr |jdS|S)Nzthere is no next item)rrr)rryrrrrs zAsyncLoopContext.nextitemcCs|S)Nr)rrrr __aiter__szAsyncLoopContext.__aiter__csL|jtk r|j}t|_n|jjIdH}|jd7_|j|_||_||fS)Nr)rrrrrrr)rryrrrrs zAsyncLoopContext.__anext__N)r!r"r#r$ AsyncIteratorr[rrrr%r AsyncIterablerrr&rrrrrrrrrrrrrrr/{s"    c @seZdZdZddejdefeejeeeeej edddZ e e ej ej edd d Zejej eed d d Zejej eed ddZedddZdS)r*zWraps a macro function.Nr.)rBfuncrR arguments catch_kwargs catch_varargscallerdefault_autoescapec Csl||_||_t||_||_||_||_||_||_d|k|_ |dkrbt |j r\|j d}n|j }||_ dS)Nr) _environment_funcr_argument_countrRrrrrexplicit_callercallabler_default_autoescape) rrBrrRrrrrrrrrrQs     zMacro.__init__)r}r~rc Os|r*t|dtr*|dj}|dd}n|j}t|d|j}t|}d}||jkrx`|jt|dD]B}y|j|}Wnt k rt }YnX|dkrd}|j |qlWn|j }|j r| r|jdd} | dkr|jjddd} |j | |jr|j |n@|rHd|kr*td|jd td|jd tt||jrf|j ||jdn.t||jkrtd|jd t|jd |j||S) NrrFrTzNo caller defined)rRzmacro zX was invoked with two values for the special caller argument. This is most likely a bug.z takes no keyword argument z takes not more than z argument(s))rzr rrrrrrrrwrr5rrrrurrrRrrr_invoke) rr}r~rroffZ found_callerrRrMrrrrr sH        zMacro.__call__)rrrcs |j|IdH}|rt|S|S)N)rr)rrrryrrr _async_invoke0szMacro._async_invokecCs.|jjr|j||S|j|}|r*t|}|S)N)rrrrr)rrrryrrrr8s   z Macro._invoke)rcCs0|jdkrdnt|j}dt|jd|dS)NZ anonymousrUrVrW)rRreprrXr!)rrRrrrrYCszMacro.__repr__)N)r!r"r#rZr$rr'rrrrQrrr[r rrrYrrrrr*s 4L c@seZdZdZd'Zdedefeje ej eje ej e dddd Z ee d d d Zeej ej d dddZee ej dddZeZZZZeZZZZeZZeZZeZZ eZ!Z"eZ#Z$eZ%Z&Z'Z(eZ)Z*Z+eZ,Z-ej e.dddZ/ej e.dddZ0e1d ddZ2e d ddZ3e1d ddZ4ej5ej d dd Z6ej7ej d d!d"Z8e.d d#d$Z9e d d%d&Z:dS)(r.ahThe default undefined type. This undefined type can be printed and iterated over, but every other access will raise an :exc:`UndefinedError`: >>> foo = Undefined(name='foo') >>> str(foo) '' >>> not foo True >>> foo + 42 Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined _undefined_hint_undefined_obj_undefined_name_undefined_exceptionN)hintobjrRexcrcCs||_||_||_||_dS)N)rrrr)rrrrRrrrrrQ^szUndefined.__init__)rcCsZ|jr |jS|jtkr"|jdSt|jtsDt|jd|jSt|jd|jS)zXBuild a message about the undefined value based on how it was accessed. z is undefinedz has no element z has no attribute )rrrrrzr'r)rrrr_undefined_messagejs   zUndefined._undefined_messagez te.NoReturn)r}r~rcOs|j|jdS)zeRaise an :exc:`UndefinedError` when operations are performed on the undefined value. N)rr)rr}r~rrr_fail_with_undefined_errorsz$Undefined._fail_with_undefined_error)rRrcCs |dddkrt||jS)Nr;__)AttributeErrorr)rrRrrr __getattr__szUndefined.__getattr__)otherrcCst|t|kS)N)rX)rrrrr__eq__szUndefined.__eq__cCs |j| S)N)r)rrrrr__ne__szUndefined.__ne__cCs tt|S)N)idrX)rrrr__hash__szUndefined.__hash__cCsdS)Nr3r)rrrr__str__szUndefined.__str__cCsdS)Nrr)rrrrrszUndefined.__len__ccsfEdHdS)Nr)rrrrrszUndefined.__iter__cCsxfD] }dVqWdS)Nr)r_rrrrs zUndefined.__aiter__cCsdS)NFr)rrrr__bool__szUndefined.__bool__cCsdS)Nr.r)rrrrrYszUndefined.__repr__)rrrr);r!r"r#rZ __slots__rr r$rr'r[rr rQrrrrr__add____radd____sub____rsub____mul____rmul__Z__div__Z__rdiv__ __truediv__ __rtruediv__ __floordiv__ __rfloordiv____mod____rmod____pos____neg__r rT__lt____le____gt____ge____int__ __float__ __complex____pow____rpow__rrrr&rrrrrrrrrYrrrrr.HsH   zlogging.Logger)loggerbasercsZdkr,ddl}|jtj|jtjtddfdd Gfddd|}|S)akGiven a logger object this returns a new undefined class that will log certain failures. It will log iterations and printing. If no logger is given a default logger is created. Example:: logger = logging.getLogger(__name__) LoggingUndefined = make_logging_undefined( logger=logger, base=Undefined ) .. versionadded:: 2.8 :param logger: the logger to use. If not provided, a default logger is created. :param base: the base class to add logging functionality to. This defaults to :class:`Undefined`. Nr)undefrcsjd|jdS)NzTemplate variable warning: %s)warningr)r)rrr _log_messagesz,make_logging_undefined.._log_messagecsteZdZfZejejddfdd Zedfdd Zej ejdfdd Z e dfd d Z Z S) z0make_logging_undefined..LoggingUndefinedz te.NoReturn)r}r~rcsLytj||Wn4|jk rF}zjd||WYdd}~XnXdS)NzTemplate variable error: %s)rrrrerror)rr}r~e) __class__rrrrs  zKmake_logging_undefined..LoggingUndefined._fail_with_undefined_error)rcs|tjS)N)rrr)r)rrrrrsz8make_logging_undefined..LoggingUndefined.__str__cs|tjS)N)rrr)r)rrrrrsz9make_logging_undefined..LoggingUndefined.__iter__cs|tjS)N)rrr)r)rrrrrsz9make_logging_undefined..LoggingUndefined.__bool__)r!r"r#rr$r[rr'rrrrr __classcell__r)rr)rrLoggingUndefineds r )logging getLoggerr! addHandler StreamHandlersysstderrr.)rrr r r)rrrmake_logging_undefineds rc@s6eZdZdZfZedddZeddddZeZdS) ChainableUndefinedaAn undefined that is chainable, where both ``__getattr__`` and ``__getitem__`` return itself rather than raising an :exc:`UndefinedError`. >>> foo = ChainableUndefined(name='foo') >>> str(foo.bar['baz']) '' >>> foo.bar['baz'] + 42 Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined .. versionadded:: 2.11.0 )rcCst|S)N)r')rrrrr2szChainableUndefined.__html__)rrcCs|S)Nr)rrrrrr szChainableUndefined.__getattr__N) r!r"r#rZrr'r2rrTrrrrrs rc@s"eZdZdZfZedddZdS)DebugUndefinedaAn undefined that returns the debug info when printed. >>> foo = DebugUndefined(name='foo') >>> str(foo) '{{ foo }}' >>> not foo True >>> foo + 42 Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined )rcCsL|jrd|j}n,|jtkr&|j}ndt|jd|jd}d|dS)Nzundefined value printed: zno such element: []z{{ z }})rrrrr)rmessagerrrrs  zDebugUndefined.__str__N)r!r"r#rZrr'rrrrrrs rc@s:eZdZdZfZejZZZ ejZ Z Z Z ejZdS)StrictUndefinedasAn undefined that barks on print and iteration as well as boolean tests and all kinds of comparisons. In other words: you can do nothing with it except checking if it's defined using the `defined` test. >>> foo = StrictUndefined(name='foo') >>> str(foo) Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined >>> not foo Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined >>> foo + 42 Traceback (most recent call last): ... jinja2.exceptions.UndefinedError: 'foo' is undefined N)r!r"r#rZrr.rrrrrrrrrrrrrr/s r)NFNN)IrZr_rZtypingr$ collectionsr itertoolsrZ markupsaferrrZ async_utilsrr exceptionsr r r Znodesr utilsrrrrrrrZTypeVarrrr[rZ TYPE_CHECKINGr Ztyping_extensionsterBrZProtocolrZexportedZasync_exportedr-r%r'r+r,r@rrrrrMappingrNr)rbregisterrArSr(r/r*r.rrrrrrrrrrs                      hl0FGq: