Files
aitsc/.venv/Lib/site-packages/jinja2/__pycache__/runtime.cpython-312.pyc

352 lines
48 KiB
Plaintext
Raw Normal View History

2025-02-23 09:07:52 +08:00
<EFBFBD>
2025-08-17 18:52:05 +08:00
-<2D><>h<EFBFBD><68><00><00>r<00>dZddlZddlZddlZddlmZddlmZddl m
2025-02-23 09:07:52 +08:00
Z
ddl m Z ddl m Z dd l mZdd
l mZdd lmZdd lmZdd lmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZej<d<16>Zej<dej@dejBf<00><19>Z"ejFr#ddl$Z$ddl%Z&ddl'm(Z(Gd<1B>de&jR<00>Z*gd<1D>Z+gd<1E>Z,ded efd!<21>Z-d"ej\ejBd e/fd#<23>Z0d"ej\ejBd e/fd$<24>Z1 dHd%d&d'ejde/d(ejfe/ej@d)gejhe/ffd*ejdejfe/ejBfd+e5d,ejdejle/ejBfd-ejdejne/ejBfd d)fd.<2E>Z8Gd/<2F>d0<64>Z9d1e"d e"fd2<64>Z:ejnjvGd3<64>d)<29><00>Z<Gd4<64>d5<64>Z=Gd6<64>d7<64>Z>Gd8<64>d9e><3E>Z?Gd:<3A>d;<3B>Z@Gd<<3C>d=<3D>ZAdeAfd>ejdd?d@ej<>eAd ej<>eAfdA<64>ZCGdB<64>dCeA<65>ZDGdD<64>dEeA<65>ZEGdF<64>dGeA<65>ZFy)Iz;The runtime functions and state used by compiled templates.<2E>N)<01>abc)<01>chain)<01>escape)<01>Markup)<01>soft_str<74><00><01>
auto_aiter)<01>
2025-08-16 19:28:45 +08:00
auto_await)<01>TemplateNotFound)<01>TemplateRuntimeError)<01>UndefinedError)<01> EvalContext)<01>_PassArg)<01>concat)<01> internalcode)<01>missing)<01> Namespace)<01>object_type_repr)<01>pass_eval_context<78>V<>F.)<01>bound)<01> Environmentc <00>B<00>eZdZ ddejedddedefd<05>Zy)<08>LoopRenderFunc<6E>reciter<65>loop_render_func<6E>depth<74>returnc<00><00>y<00>N<>)<04>selfrrrs <20>2D:\aitsc\.venv\Lib\site-packages\jinja2\runtime.py<70>__call__zLoopRenderFunc.__call__&s<00><00>
2025-02-23 09:07:52 +08:00
<16>N)r) <09>__name__<5F>
__module__<EFBFBD> __qualname__<5F>t<>Iterabler<00>int<6E>strr&r#r'r%rr%s:<00><00>
<1B>  <16><16>Z<EFBFBD>Z<EFBFBD><01>]<5D> <16>/<2F> <16><17>  <16>
<11>  r'r)<0E> LoopContext<78>TemplateReference<63>Macrorr rr<00> markup_join<69>str_join<69>identityr r<00> Undefinedr)<03>AsyncLoopContextr
r <00>xr c<00><00>|S)zLReturns its argument. Useful for certain things in the
environment.
r#)r7s r%r4r4Fs <00><00> <0A>Hr'<00>seqc<00><><00>g}tt|<00>}|D]E}|j|<03>t|d<01>s<01>!t d<02>j t ||<02><00>cSt|<01>S)z?Concatenation that escapes if necessary and converts to string.<2E>__html__<5F>)<08>mapr<00>append<6E>hasattrr<00>joinrr)r9<00>buf<75>iterator<6F>args r%r2r2MsX<00><00>
<0C>C<EFBFBD><12>8<EFBFBD>S<EFBFBD>!<21>H<EFBFBD><17><03> <0B>
<EFBFBD>
<EFBFBD>3<EFBFBD><0F> <12>3<EFBFBD>
<EFBFBD> #<23><19>"<22>:<3A>?<3F>?<3F>5<EFBFBD><13>h<EFBFBD>#7<>8<> 8<><18> <12>#<23>;<3B>r'c<00>4<00>ttt|<00><00>S)z3Simple args to string conversion and concatenation.)rr=r.)r9s r%r3r3Xs<00><00> <11>#<23>c<EFBFBD>3<EFBFBD>-<2D> <20> r'<00> environmentr<00> template_name<6D>blocks<6B>Context<78>vars<72>shared<65>globals<6C>localsc<00><><00>|<03>i}|r|}nt|xsdfi|<03><01>}|r3|r t|<07>}|j<00>D]\}} | tus<01>| ||<<00>|j|||||<05><02>S)z%Internal helper for context creation.r#)rK)<04>dict<63>itemsr<00> context_class)
rErFrGrIrJrKrL<00>parent<6E>key<65>values
r%<00> new_contextrT]s<><00><00> <0C>|<7C><11><04> <0A><15><06><15>g<EFBFBD>m<EFBFBD><12>,<2C>t<EFBFBD>,<2C><06> <0A> <12><19>&<26>\<5C>F<EFBFBD> <20>,<2C>,<2C>.<2E>J<EFBFBD>C<EFBFBD><15><14>G<EFBFBD>#<23>#<23><06>s<EFBFBD> <0B>)<29> <17> $<24> $<24><13>V<EFBFBD>]<5D>F<EFBFBD>G<EFBFBD> %<25> <06>r'c<00>H<00>eZdZdZdd<04>Zdedejfd<06>Zdefd<07>Z y) r0zThe `self` in templates.r Nc<00><00>||_yr")<01>_TemplateReference__context)r$<00>contexts r%<00>__init__zTemplateReference.__init__}s <00><00> <20><04>r'<00>namec<00>d<00>|jj|}t||j|d<01>S<00>Nr)rWrG<00>BlockReference)r$rZrGs r%<00> __getitem__zTemplateReference.__getitem__<5F>s+<00><00><15><1E><1E>&<26>&<26>t<EFBFBD>,<2C><06><1D>d<EFBFBD>D<EFBFBD>N<EFBFBD>N<EFBFBD>F<EFBFBD>A<EFBFBD>><3E>>r'c<00>b<00>dt|<00>j<00>d|jj<00>d<03>S)N<><<3C> <20>>)<04>typer(rWrZ<00>r$s r%<00>__repr__zTemplateReference.__repr__<5F>s-<00><00><12>4<EFBFBD><04>:<3A>&<26>&<26>'<27>q<EFBFBD><14><1E><1E>)<<3C>)<<3C>(?<3F>q<EFBFBD>A<>Ar')rXrHr N)
r(r)r*<00>__doc__rYr.r+<00>Anyr^rer#r'r%r0r0zs/<00><00>"<22>!<21>?<3F><03>?<3F><01><05><05>?<3F>B<01>#<23>Br'r0<00> dict_methodc<00><><00><00>tj<00><00>dddtjf<04>fd<04> <0C>}tjt
|<01>S)Nr$rHr c<00>0<00><01><00>|j<00><00>Sr")<01>get_all)r$rhs <20>r%<00>f_allz_dict_method_all.<locals>.f_all<6C>s<00><><00><1A>4<EFBFBD><<3C><<3C>><3E>*<2A>*r')<06> functools<6C>wrapsr+rg<00>castr)rhrls` r%<00>_dict_method_allrp<00>sC<00><><00><0E>_<EFBFBD>_<EFBFBD>[<5B>!<21>+<2B>I<EFBFBD>+<2B>!<21>%<25>%<25>+<2B>"<22>+<2B> <0A>6<EFBFBD>6<EFBFBD>!<21>U<EFBFBD> <1B>r'c<00>`<00>eZdZdZ d dddej
eejfdejedej
eejdgejeffdejejeejff
d <09>Z ded
ejdgejefd ejd fd <0A>Zd dedejd ejfd<10>Zded ejejdffd<12>Zded ejfd<13>Zd ej
eejffd<14>Zd ej
eejffd<15>Zedejdejfdejdejd ejejdffd<1A><04>Zd dejej
eejfd dfd<1C>Zeej2<00>Zeej4<00>Zeej6<00>Zded efd<1D>Zded ejfd<1E>Zd efd<1F>Zy)!rHa<>The 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.
NrErrQrZrGrKc<00>(<00>||_i|_||_t|j|<03>|_t <00>|_||_|<05>
t <00>n
t |<05>|_|j<00>D<00><06>cic] \}}||g<01><02> c}}|_
ycc}}wr") rQrIrEr<00>eval_ctx<74>set<65> exported_varsrZ<00> globals_keysrOrG)r$rErQrZrGrK<00>k<>vs r%rYzContext.__init__<5F>s~<00><00><1D><04> <0B>(*<2A><04> <09>(3<><04><18>#<23>D<EFBFBD>$4<>$4<>d<EFBFBD>;<3B><04> <0A>),<2C><15><04><1A><18><04> <09>%,<2C>_<EFBFBD>C<EFBFBD>E<EFBFBD>#<23>g<EFBFBD>,<2C><04><19>
+1<>,<2C>,<2C>.<2E>9<>.<2E>$<24>!<21>Q<EFBFBD>q<EFBFBD>1<EFBFBD>#<23>v<EFBFBD>.<2E>9<><04> <0B><>9s<00>6B<06>currentr <00>r]r5c<00><><00> |j|}|j|<02>dz}||t ||||<04>S#t$r$|jj d|<01>d<03>d<04><05>cYSwxYw)zRender a parent block.r<00> there is no parent block called <20>.<2E>super<65>rZ)rG<00>index<65> LookupErrorrE<00> undefinedr])r$rZryrGr<>s r%r~z Context.super<65>s<00><00> <0E><19>[<5B>[<5B><14>&<26>F<EFBFBD><1A>L<EFBFBD>L<EFBFBD><17>)<29>A<EFBFBD>-<2D>E<EFBFBD> <12>5<EFBFBD>M<EFBFBD>
<1E>d<EFBFBD>D<EFBFBD>&<26>%<25>8<>8<><38> <1B> <0E><17>#<23>#<23>-<2D>-<2D>2<>4<EFBFBD>(<28>!<21><<3C>7<EFBFBD>.<2E><0E> <0E> <0E>s<00>(8<00>*A%<03>$A%rR<00>defaultc<00>0<00> ||S#t$r|cYSwxYw)z<>Look 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.
)<01>KeyError)r$rRr<>s r%<00>getz Context.get<65>s%<00><00> <1B><17><03>9<EFBFBD> <1C><><17> <1B><1A>N<EFBFBD> <1B>s <00><00> <03>r5c<00>p<00>|j|<01>}|tur|jj|<01><01>S|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.
r)<04>resolve_or_missingrrEr<>)r$rR<00>rvs r%<00>resolvezContext.resolve<76>s:<00><00><12> $<24> $<24>S<EFBFBD> )<29><02> <0A><17>=<3D><17>#<23>#<23>-<2D>-<2D>3<EFBFBD>-<2D>7<> 7<><11> r'c<00><><00>||jvr|j|S||jvr|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.
)rIrQr)r$rRs r%r<>zContext.resolve_or_missing<6E>s><00><00> <0F>$<24>)<29>)<29> <1B><17>9<EFBFBD>9<EFBFBD>S<EFBFBD>><3E> !<21> <0E>$<24>+<2B>+<2B> <1D><17>;<3B>;<3B>s<EFBFBD>#<23> #<23><16>r'c<00>\<00>|jD<00>cic]}||j|<00><02>c}Scc}w)z+Get a new dict with the exported variables.)rurI)r$rws r%<00> get_exportedzContext.get_exported<65>s.<00><00>)-<2D>);<3B>);<3B><<3C>);<3B>A<EFBFBD><01>4<EFBFBD>9<EFBFBD>9<EFBFBD>Q<EFBFBD><<3C><0F>);<3B><<3C><<3C><><s<00>)c<00><><00>|js |jS|js |jSt|jfi|j<00><01>S)z<>Return 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.
)rIrQrNrds r%rkzContext.get_all<6C>s><00><00>
<14>y<EFBFBD>y<EFBFBD><17>;<3B>;<3B> <1E><13>{<7B>{<7B><17>9<EFBFBD>9<EFBFBD> <1C><13>D<EFBFBD>K<EFBFBD>K<EFBFBD>-<2D>4<EFBFBD>9<EFBFBD>9<EFBFBD>-<2D>-r'<00> _Context__obj.<2E>args<67>kwargsc<00><><00> d}t|d<02>r+tj|j<00><00> |j}tj|<01>}|tjurQ|j d<04>r|j |d<00>}|j d<05>r|j |d<00>}|f|z}nE|tjur|jf|z}n"|tjur|jf|z}|jdd<03>|jdd<03> ||i|<03><01>S#t$r|jjd<06>cYSwxYw)z<>Call 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&N<>
_loop_vars<EFBFBD> _block_varszGvalue was undefined because a callable raised a StopIteration exception) r?r<00>from_objr&rXr<><00>derived<65> eval_contextrsrE<00>pop<6F> StopIterationr<6E>)<06>_Context__selfr<66>r<>r<><00>__traceback_hide__<5F>pass_args r%<00>callz Context.calls?<00><00> <15>!%<25> <1E> <14>E<EFBFBD>:<3A> &<26><18>!<21>!<21>%<25>.<2E>.<2E>1<>=<3D><19>N<EFBFBD>N<EFBFBD>E<EFBFBD><1B>$<24>$<24>U<EFBFBD>+<2B><08> <13>x<EFBFBD>'<27>'<27> '<27><16>z<EFBFBD>z<EFBFBD>,<2C>'<27><1F><1E><1E><06>|<7C>(<<3C>=<3D><06><15>z<EFBFBD>z<EFBFBD>-<2D>(<28><1F><1E><1E><06>}<7D>(=<3D>><3E><06><1A>9<EFBFBD>t<EFBFBD>#<23>D<EFBFBD> <15><18>.<2E>.<2E> .<2E><1A>O<EFBFBD>O<EFBFBD>%<25><04>,<2C>D<EFBFBD> <15><18>-<2D>-<2D> -<2D><1A>&<26>&<26>(<28>4<EFBFBD>/<2F>D<EFBFBD><0E>
<EFBFBD>
<EFBFBD>=<3D>$<24>'<27><0E>
<EFBFBD>
<EFBFBD><<3C><14>&<26> <0E><18>$<24>)<29>&<26>)<29> )<29><><1C> <0E><19>%<25>%<25>/<2F>/<2F>+<2B><0E> <0E> <0E>s<00>D%<00>%$E <03> E rLc <00><00>t|j|ji|j<00>dd|<01>}|j|_|j
j d<03>|j
j<00>D<00><00>|S)z<>Internal 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.
TNc3<00><K<00>|]\}}|t|<02>f<02><01><00>y<00>wr")<01>list)<03>.0rwrxs r%<00> <genexpr>z"Context.derived.<locals>.<genexpr>?s<00><00><><00>K<>7J<37>t<EFBFBD>q<EFBFBD>!<21>q<EFBFBD>$<24>q<EFBFBD>'<27>l<EFBFBD>7J<37>s<00>)rTrErZrkrsrG<00>updaterO)r$rLrXs r%r<>zContext.derived6se<00><00>
<1E> <10> <1C> <1C>d<EFBFBD>i<EFBFBD>i<EFBFBD><12>T<EFBFBD>\<5C>\<5C>^<5E>T<EFBFBD>4<EFBFBD><16>
<EFBFBD><07> <20>=<3D>=<3D><07><18><0F><0E><0E><1D><1D>K<>t<EFBFBD>{<7B>{<7B>7H<37>7H<37>7J<37>K<>K<><16>r'c<00>><00>||jvxs||jvSr")rIrQ<00>r$rZs r%<00> __contains__zContext.__contains__Fs<00><00><13>t<EFBFBD>y<EFBFBD>y<EFBFBD> <20>7<>D<EFBFBD>D<EFBFBD>K<EFBFBD>K<EFBFBD>$7<>7r'c<00>N<00>|j|<01>}|tur t|<01><00>|S)zpLook up a variable by name with ``[]`` syntax, or raise a
``KeyError`` if the key is not found.
)r<>rr<>)r$rR<00>items r%r^zContext.__getitem__Is*<00><00><14>&<26>&<26>s<EFBFBD>+<2B><04> <0F>7<EFBFBD>?<3F><1A>3<EFBFBD>-<2D> <1F><13> r'c<00>p<00>dt|<00>j<00>d|j<00><00>d|j<00>d<04>S)Nr`raz of rb)rcr(rkrZrds r%rezContext.__repr__Ts3<00><00><12>4<EFBFBD><04>:<3A>&<26>&<26>'<27>q<EFBFBD><14><1C><1C><1E>(:<3A>$<24>t<EFBFBD>y<EFBFBD>y<EFBFBD>m<EFBFBD>1<EFBFBD>M<>Mr'r") r(r)r*rfr+<00>Dictr.rg<00>Optional<61>Callable<6C>Iterator<6F>MutableMappingrY<00>Unionr~r<>r<>r<>r<>rkrr<>r<>rprN<00>keys<79>valuesrO<00>boolr<6C>r^rer#r'r%rHrH<00>sk<00><00><08>2=A<01> :<3A>"<22>:<3A><12><06><06>s<EFBFBD>A<EFBFBD>E<EFBFBD>E<EFBFBD>z<EFBFBD>"<22>:<3A><10>j<EFBFBD>j<EFBFBD><13>o<EFBFBD> :<3A>
<12><06><06>s<EFBFBD>A<EFBFBD>J<EFBFBD>J<EFBFBD> <09>{<7B>A<EFBFBD>J<EFBFBD>J<EFBFBD>s<EFBFBD>O<EFBFBD>'C<>D<>D<>E<> :<3A> <13><1A><1A>A<EFBFBD>,<2C>,<2C>S<EFBFBD>!<21>%<25>%<25>Z<EFBFBD>8<>9<> :<3A>* 9<><17> 9<>"#<23>*<2A>*<2A>i<EFBFBD>[<5B>!<21>*<2A>*<2A>S<EFBFBD>/<2F>-I<>"J<> 9<>
<EFBFBD><17><17>.<2E> /<2F> 9<>
<1B>s<EFBFBD>
<1B>Q<EFBFBD>U<EFBFBD>U<EFBFBD>
<1B>a<EFBFBD>e<EFBFBD>e<EFBFBD>
<1B><12>3<EFBFBD><12>1<EFBFBD>7<EFBFBD>7<EFBFBD>1<EFBFBD>5<EFBFBD>5<EFBFBD>+<2B>+=<3D>#><3E><12>"<17>c<EFBFBD><17>a<EFBFBD>e<EFBFBD>e<EFBFBD><17>$=<3D>a<EFBFBD>f<EFBFBD>f<EFBFBD>S<EFBFBD>!<21>%<25>%<25>Z<EFBFBD>0<>=<3D> .<2E><11><16><16><03>Q<EFBFBD>U<EFBFBD>U<EFBFBD>
<EFBFBD>+<2B> .<2E><12>-<0E><10>z<EFBFBD>z<EFBFBD>#<23>q<EFBFBD>u<EFBFBD>u<EFBFBD>*<2A>%<25>-<0E><11>u<EFBFBD>u<EFBFBD>-<0E><14>%<25>%<25> -<0E>
<0B><17><17><11><15><15> <0B>#<23> $<24> -<0E><12>-<0E>^
<17>a<EFBFBD>j<EFBFBD>j<EFBFBD><11><16><16><03>Q<EFBFBD>U<EFBFBD>U<EFBFBD>
<EFBFBD>);<3B><<3C>
<17> <09>
<17> <1C>D<EFBFBD>I<EFBFBD>I<EFBFBD> &<26>D<EFBFBD> <1D>d<EFBFBD>k<EFBFBD>k<EFBFBD> *<2A>F<EFBFBD> <1C>T<EFBFBD>Z<EFBFBD>Z<EFBFBD> (<28>E<EFBFBD>8<><13>8<><14>8<> <14>s<EFBFBD> <14>q<EFBFBD>u<EFBFBD>u<EFBFBD> <14>N<01>#<23>Nr'c
<00><><00>eZdZdZdedddej ejdgejefde ddf
d <09>Z
e dejd
fd <0B><04>Z edefd <0C><04>Zedefd <0A><04>Zy)r]z"One block on a template reference.rZrXrH<00>stackrr Nc<00><<00>||_||_||_||_yr")rZ<00>_context<78>_stack<63>_depth)r$rZrXr<>rs r%rYzBlockReference.__init__[s <00><00><19><04> <09><1F><04> <0A><1B><04> <0B><1B><04> r'rzc<00>(<00>|jdzt|j<00>k\r5|jjj d|j <00>d<03>d<04><05>St|j |j|j|jdz<00>S)zSuper the block.rr|r}r~r)r<><00>lenr<6E>r<>rEr<>rZr]rds r%r~zBlockReference.supergsy<00><00> <10>;<3B>;<3B><11>?<3F>c<EFBFBD>$<24>+<2B>+<2B>.<2E> .<2E><17>=<3D>=<3D>,<2C>,<2C>6<>6<>2<>4<EFBFBD>9<EFBFBD>9<EFBFBD>-<2D>q<EFBFBD>A<><07>7<><0E> <0E><1E>d<EFBFBD>i<EFBFBD>i<EFBFBD><14><1D><1D><04> <0B> <0B>T<EFBFBD>[<5B>[<5B>ST<53>_<EFBFBD>U<>Ur'c<00><00>4K<00>|jjj|j|j|j<00>2<00>cgc3d{<00><04><03>}|<01><02> 7<00>6ncc}wc}<01>}|jj
j r t|<02>S|S<00>wr")r<>rErr<>r<>rs<00>
autoescaper)r$r7r<>s r%<00> _async_callzBlockReference._async_callpst<00><00><><00> <11>]<5D>]<5D> &<26> &<26> -<2D> -<2D>6<>d<EFBFBD>k<EFBFBD>k<EFBFBD>$<24>+<2B>+<2B>6<>t<EFBFBD>}<7D>}<7D>E<> F<> F<><11>Q<EFBFBD> F<><46> F<><46> F<>
<EFBFBD><02> <10>=<3D>=<3D> !<21> !<21> ,<2C> ,<2C><19>"<22>:<3A> <1D><11> <09>s6<00>A B<01> A<08>A
<EFBFBD>A<0E>A
<EFBFBD>A<08>A
<EFBFBD>A<08>:Bc<00>T<00>|jjjr|j<00>S|jjj |j
|j |j<00><00>}|jjjr t|<01>S|Sr")
r<EFBFBD>rE<00>is_asyncr<63>rr<>r<>rsr<>r<00>r$r<>s r%r&zBlockReference.__call__{s}<00><00> <0F>=<3D>=<3D> $<24> $<24> -<2D> -<2D><17>#<23>#<23>%<25> %<25> <11>]<5D>]<5D> &<26> &<26> -<2D> -<2D> $<24>D<EFBFBD>K<EFBFBD>K<EFBFBD><04> <0B> <0B> $<24>T<EFBFBD>]<5D>]<5D> 3<>
<EFBFBD><02> <10>=<3D>=<3D> !<21> !<21> ,<2C> ,<2C><19>"<22>:<3A> <1D><11> r')r(r)r*rfr.r+<00>Listr<74>r<>r-rY<00>propertyr<79>r~rr<>r&r#r'r%r]r]Xs<><00><00>,<2C>
<1C><11>
<1C><1B>
<1C><11>v<EFBFBD>v<EFBFBD>a<EFBFBD>j<EFBFBD>j<EFBFBD>)<29><1B>a<EFBFBD>j<EFBFBD>j<EFBFBD><13>o<EFBFBD>!=<3D>><3E>?<3F>
<1C>
<13>
<1C>
<0E>
<1C><0E>V<01>q<EFBFBD>w<EFBFBD>w<EFBFBD><<3C>=<3D>V<01><0E>V<01><12><12>3<EFBFBD><12><12><12><12> <12>#<23> <12><12> r'r]c <00><><00>eZdZUdZdZdZejee d<e
Z eje d<e
Z eje d<e
Zeje d<e
Zeje d< d%d ej ed
ej$d d ejd deddf
d<10>Zed ej edej*efd<11><04>Zedefd<12><04>Zdefd<13>Zedefd<14><04>Zedefd<15><04>Zedefd<16><04>Zedefd<17><04>Zedefd<18><04>Zdejfd<19>Z edefd<1A><04>Z!edejDejd ffd<1B><04>Z#edejDejd ffd<1C><04>Z$dedefd<1E>Z%dejdefd <20>Z&d&d!<21>Z'dejPejdffd"<22>Z)e*d ej ede+fd#<23><04>Z,de+fd$<24>Z-y)'r/zeA wrapper iterable for dynamic ``for`` loops, with information
about the loop and iteration.
<20><><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD>_length<74>_after<65>_current<6E>_before<72>_last_changed_value<75>iterabler<65>r5<00>recurser<00>depth0r c<00>h<00>||_|j|<01>|_||_||_||_y)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)<06> _iterable<6C> _to_iterator<6F> _iterator<6F>
_undefined<EFBFBD>_recurser<65>)r$r<>r<>r<>r<>s r%rYzLoopContext.__init__<5F>s2<00><00>"<22><04><0E><1D>*<2A>*<2A>8<EFBFBD>4<><04><0E>#<23><04><0F><1F><04> <0A><1C><04> r'c<00><00>t|<00>Sr")<01>iter<65>r<>s r%r<>zLoopContext._to_iterator<6F>s <00><00><13>H<EFBFBD>~<7E>r'c<00>j<00>|j<00> |jS t|j<00>|_|jS#t$rit |j
<00>}|j |<01>|_t|<01>|jz|jtuz|_Y|jSwxYw)z<>Length of the iterable.
If the iterable is a generator or otherwise does not have a
size, it is eagerly evaluated to get a size.
)
r<EFBFBD>r<>r<><00> TypeErrorr<72>r<>r<>r<>r<>r<00>r$r<>s r%<00>lengthzLoopContext.length<74>s<><00><00> <10><<3C><<3C> #<23><17><<3C><<3C> <1F> U<01><1E>t<EFBFBD>~<7E>~<7E>.<2E>D<EFBFBD>L<EFBFBD> <14>|<7C>|<7C><1B><> <19> U<01><1B>D<EFBFBD>N<EFBFBD>N<EFBFBD>+<2B>H<EFBFBD>!<21>.<2E>.<2E>x<EFBFBD>8<>D<EFBFBD>N<EFBFBD><1E>x<EFBFBD>=<3D>4<EFBFBD>:<3A>:<3A>5<><14><1B><1B>G<EFBFBD>9S<39>T<>D<EFBFBD>L<EFBFBD><13>|<7C>|<7C><1B>  U<01>s<00>A<00>A$B2<03>1B2c<00><00>|jSr")r<>rds r%<00>__len__zLoopContext.__len__<5F>s <00><00><13>{<7B>{<7B>r'c<00> <00>|jdzS)zBHow many levels deep a recursive loop currently is, starting at 1.r)r<>rds r%rzLoopContext.depth<74><00><00><00><14>{<7B>{<7B>Q<EFBFBD><EFBFBD>r'c<00> <00>|jdzS)z-Current iteration of the loop, starting at 1.r<00><01>index0rds r%r<>zLoopContext.index<65>r<>r'c<00>4<00>|j|jz
S)zrNumber of iterations from the end of the loop, ending at 0.
Requires calculating :attr:`length`.
<20>r<>r<>rds r%<00> revindex0zLoopContext.revindex0<78>s<00><00> <14>{<7B>{<7B>T<EFBFBD>Z<EFBFBD>Z<EFBFBD>'<27>'r'c<00>4<00>|j|jz
S)zrNumber of iterations from the end of the loop, ending at 1.
Requires calculating :attr:`length`.
<20>r<>r<>rds r%<00>revindexzLoopContext.revindex<65>s<00><00> <14>{<7B>{<7B>T<EFBFBD>[<5B>[<5B>(<28>(r'c<00> <00>|jdk(S)z0Whether this is the first iteration of the loop.rr<>rds r%<00>firstzLoopContext.first<73>s<00><00><14>{<7B>{<7B>a<EFBFBD><1F>r'c<00><><00>|jtur |jSt|jt<00>|_|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.
)r<>r<00>nextr<74>rds r%<00>
_peek_nextzLoopContext._peek_next<78>s6<00><00> <10>;<3B>;<3B>g<EFBFBD> %<25><17>;<3B>;<3B> <1E><1A>4<EFBFBD>><3E>><3E>7<EFBFBD>3<><04> <0B><13>{<7B>{<7B>r'c<00>.<00>|j<00>tuS)z<>Whether 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.
<20>r<>rrds r%<00>lastzLoopContext.last<73>s<00><00><14><EFBFBD><EFBFBD> <20>G<EFBFBD>+<2B>+r'c<00>T<00>|jr|jd<01>S|jS)zZThe item in the previous iteration. Undefined during the
first iteration.
zthere is no previous item)r<>r<>r<>rds r%<00>previtemzLoopContext.previtem<65>s%<00><00>
<10>:<3A>:<3A><17>?<3F>?<3F>#><3E>?<3F> ?<3F><13>|<7C>|<7C>r'c<00>X<00>|j<00>}|tur|jd<01>S|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.
<20>there is no next item<65>r<>rr<>r<>s r%<00>nextitemzLoopContext.nextitems,<00><00><12>_<EFBFBD>_<EFBFBD> <1E><02> <0A><17>=<3D><17>?<3F>?<3F>#:<3A>;<3B> ;<3B><11> r'r<>c<00>R<00>|s td<01><00>||jt|<01>zS)z<>Return 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)r<>r<>r<>)r$r<>s r%<00>cyclezLoopContext.cycles+<00><00> <14><1B>8<>9<> 9<><13>D<EFBFBD>K<EFBFBD>K<EFBFBD>#<23>d<EFBFBD>)<29>+<2B>,<2C>,r'rSc<00>2<00>|j|k7r||_yy)z<>Return ``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)r<>)r$rSs r%<00>changedzLoopContext.changed"s <00><00> <10> #<23> #<23>u<EFBFBD> ,<2C>',<2C>D<EFBFBD> $<24><17>r'c<00><00>|Sr"r#rds r%<00>__iter__zLoopContext.__iter__.<00><00><00><13> r'c<00><><00>|jtur|j}t|_nt|j<00>}|xjdz c_|j
|_||_||fS<00>Nr)r<>rr<>r<>r<>r<>r<>r<>s r%<00>__next__zLoopContext.__next__1sU<00><00> <0F>;<3B>;<3B>g<EFBFBD> %<25><15><1B><1B>B<EFBFBD>!<21>D<EFBFBD>K<EFBFBD><15>d<EFBFBD>n<EFBFBD>n<EFBFBD>%<25>B<EFBFBD> <0C> <0B> <0B>q<EFBFBD><18> <0B><1B>}<7D>}<7D><04> <0C><1A><04> <0A><11>4<EFBFBD>x<EFBFBD>r'c<00><><00>|j<00> td<01><00>|j||j|j<00><02>S)z<>When 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.
zCThe loop must have the 'recursive' marker to be called recursively.)r)r<>r<>rr<>s r%r&zLoopContext.__call__=s=<00><00> <10>=<3D>=<3D> <20><1B>U<><0E> <0E><14>}<7D>}<7D>X<EFBFBD>t<EFBFBD>}<7D>}<7D>D<EFBFBD>J<EFBFBD>J<EFBFBD>}<7D>G<>Gr'c<00>h<00>dt|<00>j<00>d|j<00>d|j<00>d<04>S)Nr`ra<00>/rb)rcr(r<>r<>rds r%rezLoopContext.__repr__Ks0<00><00><12>4<EFBFBD><04>:<3A>&<26>&<26>'<27>q<EFBFBD><14><1A><1A> <0C>A<EFBFBD>d<EFBFBD>k<EFBFBD>k<EFBFBD>]<5D>!<21>D<>Dr'r\)r r/).r(r)r*rfr<>r<>r+r<>r-<00>__annotations__rr<>rgr<>r<>r<>r,r<00>TyperY<00> staticmethodr<64>r<>r<>r<>r<>rr<>r<>r<>r<>r<>r<>r<>r<>r<>r<>r<>r<>r<><00>Tupler<65>rr.r&rer#r'r%r/r/<00>s<><00><00><08>
<10>F<EFBFBD>#<23>G<EFBFBD>Q<EFBFBD>Z<EFBFBD>Z<EFBFBD><03>_<EFBFBD>#<23><1B>F<EFBFBD>A<EFBFBD>E<EFBFBD>E<EFBFBD><1B><1D>H<EFBFBD>a<EFBFBD>e<EFBFBD>e<EFBFBD><1D><1C>G<EFBFBD>Q<EFBFBD>U<EFBFBD>U<EFBFBD><1C>!(<28><17><11><15><15>(<28> 15<31><17> <1D><13>*<2A>*<2A>Q<EFBFBD>-<2D><1D><15>6<EFBFBD>6<EFBFBD>+<2B>&<26><1D><13><1A><1A>,<2C>-<2D> <1D>
<14> <1D>
<0E> <1D>,<12><1E>q<EFBFBD>z<EFBFBD>z<EFBFBD>!<21>}<7D><1E><11><1A><1A>A<EFBFBD><1D><1E><12><1E><0E><1C><03><1C><0E><1C>$<1B><13><1B><0E><1F>s<EFBFBD><1F><0E><1F><0E><1F>s<EFBFBD><1F><0E><1F><0E>(<28>3<EFBFBD>(<28><0E>(<28><0E>)<29>#<23>)<29><0E>)<29><0E> <20>t<EFBFBD> <20><0E> <20>
<1B>A<EFBFBD>E<EFBFBD>E<EFBFBD>
<1B><0E>,<2C>d<EFBFBD>,<2C><0E>,<2C><0E><1C>!<21>'<27>'<27>!<21>%<25>%<25><1B>"4<>5<><1C><0E><1C><0E> <12>!<21>'<27>'<27>!<21>%<25>%<25><1B>"4<>5<> <12><0E> <12> -<2D>1<EFBFBD> -<2D><11> -<2D>
<15>a<EFBFBD>e<EFBFBD>e<EFBFBD>
<15><04>
<15><14>
<18>!<21>'<27>'<27>!<21>%<25>%<25><1D>"6<>7<>
<18><12> H<01><11><1A><1A>A<EFBFBD><1D> H<01>3<EFBFBD> H<01><12> H<01>E<01>#<23>Er'r/c<00><><00>eZdZUejej
ed<edejeje
eje
fdeje
fd<04><04>Z e defd<05><04>Ze defd<06><04>Ze defd<07><04>Zdej
fd<08>Ze defd <09><04>Ze dejej
d
ffd <0B><04>Zdd <0C>Zdej.ej
dffd <0A>Zy)r6r<>r<>r c<00><00>t|<00>Sr"r r<>s r%r<>zAsyncLoopContext._to_iteratorRs<00><00><1A>(<28>#<23>#r'c<00><00><>K<00>|j<00> |jS t|j<00>|_|jS#t$rz|j2<00>cgc3d{<00><05><03>7}|<01><02> 6ncc}w}}|j |<02>|_t|<02>|j z|jtuz|_Y|jSwxYw<01>wr") r<>r<>r<>r<>r<>r<>r<>r<>r)r$r7r<>s r%r<>zAsyncLoopContext.lengthXs<><00><00><><00> <0F><<3C><<3C> #<23><17><<3C><<3C> <1F> U<01><1E>t<EFBFBD>~<7E>~<7E>.<2E>D<EFBFBD>L<EFBFBD> <14>|<7C>|<7C><1B><> <19> U<01>)-<2D><1E><1E>8<>8<>A<EFBFBD><01>8<><38>8<>H<EFBFBD>8<>!<21>.<2E>.<2E>x<EFBFBD>8<>D<EFBFBD>N<EFBFBD><1E>x<EFBFBD>=<3D>4<EFBFBD>:<3A>:<3A>5<><14><1B><1B>G<EFBFBD>9S<39>T<>D<EFBFBD>L<EFBFBD><13>|<7C>|<7C><1B>  U<01>sL<00>C<01>A<00> C<01>C<03>A*<06>A(<08>A" <0C> A(<08>$A*<06>)AC<03>7 C<01>C<03>Cc<00><00>PK<00>|j<00>d{<00><02><03>|jz
S7<00><11>wr"r<>rds r%r<>zAsyncLoopContext.revindex0fs<00><00><><00><19>[<5B>[<5B> <20>4<EFBFBD>:<3A>:<3A>-<2D>-<2D> <20><> <00>&<01>$<04>&c<00><00>PK<00>|j<00>d{<00><02><03>|jz
S7<00><11>wr"r<>rds r%r<>zAsyncLoopContext.revindexjs<00><00><><00><19>[<5B>[<5B> <20>4<EFBFBD>;<3B>;<3B>.<2E>.<2E> <20>r
c<00><00><>K<00>|jtur |jS |jj<00><00>d{<00><03><03>|_|jS7<00>#t$rt|_Y|jSwxYw<01>wr")r<>rr<><00> __anext__<5F>StopAsyncIterationrds r%r<>zAsyncLoopContext._peek_nextnsh<00><00><><00> <0F>;<3B>;<3B>g<EFBFBD> %<25><17>;<3B>;<3B> <1E> "<22> $<24><0E><0E> 8<> 8<> :<3A>:<3A>D<EFBFBD>K<EFBFBD><14>{<7B>{<7B><1A> ;<3B><>!<21> "<22>!<21>D<EFBFBD>K<EFBFBD><13>{<7B>{<7B><1A> "<22>s9<00>A<<01>A<00>A<04> A<00> A<<01>A<00>A9<03>+ A<<01>8A9<03>9A<c<00><00>JK<00>|j<00><00>d{<00><02><03>tuS7<00>
<EFBFBD>wr"r<>rds r%r<>zAsyncLoopContext.lastys<00><00><><00><19>_<EFBFBD>_<EFBFBD>&<26>&<26>'<27>1<>1<>&<26>s <00>#<01>!<04> #r5c<00><00>tK<00>|j<00><00>d{<00><02><03>}|tur|jd<01>S|S7<00><1F>w)Nr<4E>r<>r<>s r%r<>zAsyncLoopContext.nextitem}s6<00><00><><00><17>?<3F>?<3F>$<24> $<24><02> <0A><17>=<3D><17>?<3F>?<3F>#:<3A>;<3B> ;<3B><11> <09> %<25>s <00>8<01>6<04> 8c<00><00>|Sr"r#rds r%<00> __aiter__zAsyncLoopContext.__aiter__<5F>r<>r'c<00><00>K<00>|jtur|j}t|_n"|jj<00><00>d{<00><02><03>}|xjdz c_|j
|_||_||fS7<00>5<EFBFBD>wr<>)r<>rr<>r r<>r<>r<>r<>s r%r zAsyncLoopContext.__anext__<5F>se<00><00><><00> <0F>;<3B>;<3B>g<EFBFBD> %<25><15><1B><1B>B<EFBFBD>!<21>D<EFBFBD>K<EFBFBD><1B>~<7E>~<7E>/<2F>/<2F>1<>1<>B<EFBFBD> <0C> <0B> <0B>q<EFBFBD><18> <0B><1B>}<7D>}<7D><04> <0C><1A><04> <0A><11>4<EFBFBD>x<EFBFBD><0F> 2<>s<00>AB<01>
B<04> 6BN)r r6)r(r)r*r+<00> AsyncIteratorrgrrr<>r,r<00> AsyncIterabler<65>r<>r-r<>r<>r<>r<>r<>r<>r<>rrr r#r'r%r6r6Os,<00><00><10><EFBFBD><EFBFBD>q<EFBFBD>u<EFBFBD>u<EFBFBD>%<25>%<25><11>$<24><13>'<27>'<27>!<21>*<2A>*<2A>Q<EFBFBD>-<2D><11><1F><1F><11>);<3B>;<3B><<3C>$<24>
<EFBFBD><1F><1F><11> <1B>$<24><12>$<24>
<0E> <1C>c<EFBFBD> <1C><0E> <1C><0E>.<2E><13>.<2E><0E>.<2E><0E>/<2F><03>/<2F><0E>/<2F> <1B>!<21>%<25>%<25> <1B><0E>2<>D<EFBFBD>2<><0E>2<><0E><12><01><07><07><01><05><05>{<7B>(:<3A> ;<3B><12><0E><12><14>
<18><11><17><17><11><15><15>0B<30>)B<>!C<>
r'r6c<00>n<00>eZdZdZ ddddej
defdedejed ed
ed ed ejefd <0A>Z
e e dejdejdefd<11><04><00>Zdejejdedefd<13>Zdejejdedefd<14>Zdefd<15>Zy)r1zWraps a macro function.NrEr<00>func.rZ<00> arguments<74> catch_kwargs<67> catch_varargs<67>caller<65>default_autoescapec <00><00>||_||_t|<04>|_||_||_||_||_||_d|v|_ |<08>:t|j<00>r|jd<00>}||_ y|j}||_ y)Nr) <0A> _environment<6E>_funcr<63><00>_argument_countrZrrrr<00>explicit_caller<65>callabler<65><00>_default_autoescape) r$rErrZrrrrrs r%rYzMacro.__init__<5F>s<><00><00>(<28><04><19><19><04>
<EFBFBD>"<22>9<EFBFBD>~<7E><04><1C><18><04> <09>"<22><04><0E>(<28><04><19>*<2A><04><1A><1C><04> <0B>'<27>9<EFBFBD>4<><04><1C> <1D> %<25><17> <0B>.<2E>.<2E>/<2F>%0<>%;<3B>%;<3B>D<EFBFBD>%A<>"<22>$6<><04> <20>&1<>%;<3B>%;<3B>"<22>#5<><04> r'r<>r<>r c
<00>&<00>|r(t|dt<00>r|dj}|dd}n |j}t |d|j
<00>}t |<04>}d}||j
k7rH|jt |<04>dD],} |j|<07>}|dk(rd}|j|<08><00>.n |j}|jrD|sB|jdd<00>} | <09>|jjdd<04><07>} |j| <09>|j r|j|<02>nL|rJd|vrt#d|j$<00>d <09><03><00>t#d|j$<00>d
t't)|<02><00><00><02><04><00>|j*r|j||j
d<00>nGt |<01>|j
kDr/t#d|j$<00>d t |j<00><00>d <0C><05><00>|j-||<03>S#t$r
t}Y<00><01>wwxYw) NrrFrTzNo caller definedrzmacro 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))<17>
isinstancerr<>r#r<>r r<>rr<>r<>rr>r!rrr<>rr<>rZr<>r<>r<00>_invoke)
r$r<>r<>r<>r<00>off<66> found_callerrZrSrs
r%r&zMacro.__call__<5F>s<00><00>& <10>J<EFBFBD>t<EFBFBD>A<EFBFBD>w<EFBFBD> <0B>4<><1D>a<EFBFBD><17>+<2B>+<2B>J<EFBFBD><17><01><02>8<EFBFBD>D<EFBFBD><1D>1<>1<>J<EFBFBD><19><14>4<><04> 4<> 4<>5<>6<> <09><11>)<29>n<EFBFBD><03><1D> <0C>
<0F>$<24>&<26>&<26> &<26><1C><0E><0E>s<EFBFBD>9<EFBFBD>~<7E>'7<>8<><04>$<24>"<22>J<EFBFBD>J<EFBFBD>t<EFBFBD>,<2C>E<EFBFBD><18>8<EFBFBD>#<23>#'<27>L<EFBFBD><19> <20> <20><15>'<27>9<> <20>/<2F>/<2F>L<EFBFBD>
<10>;<3B>;<3B>|<7C><1B>Z<EFBFBD>Z<EFBFBD><08>$<24>/<2F>F<EFBFBD><15>~<7E><1D>*<2A>*<2A>4<>4<>5H<35>x<EFBFBD>4<>X<><06> <15> <1C> <1C>V<EFBFBD> $<24> <0F> <1C> <1C> <15> <1C> <1C>V<EFBFBD> $<24> <13><17>6<EFBFBD>!<21><1F><1C>T<EFBFBD>Y<EFBFBD>Y<EFBFBD>M<EFBFBD>*C<01>C<01><12><12><1C><18><14><19><19> <0A>%@<40><14>d<EFBFBD>6<EFBFBD>l<EFBFBD>AS<41>@V<>W<><0E> <0E> <10> <1D> <1D> <15> <1C> <1C>T<EFBFBD>$<24>"6<>"6<>"8<>9<> :<3A> <10><14>Y<EFBFBD><14>-<2D>-<2D> -<2D><1B><18><14><19><19> <0A>&<14><17><04><0E><0E>'<27>(<28> <0C>6<><0E> <0E>
<14>|<7C>|<7C>I<EFBFBD>z<EFBFBD>2<>2<><32>I <20>$<24>#<23>E<EFBFBD>$<24>s<00>G=<02>=H<05>Hr<>c<00><00>ZK<00>|j|<01><00>d{<00><02><03>}|r t|<03>S|S7<00><13>wr")rr<00>r$rr<>r<>s r%<00> _async_invokezMacro._async_invokes0<00><00><><00><1D>4<EFBFBD>:<3A>:<3A>y<EFBFBD>)<29> )<29><02> <15><19>"<22>:<3A> <1D><11> <09> *<2A>s <00>+<01>)<04>+c<00><><00>|jjr|j||<02>S|j|<01>}|r t |<03>}|Sr")rr<>r+rrr*s r%r&z Macro._invoke sE<00><00> <0F> <1C> <1C> %<25> %<25><17>%<25>%<25>i<EFBFBD><1A><<3C> <<3C> <17>T<EFBFBD>Z<EFBFBD>Z<EFBFBD><19> #<23><02> <15><17><02><1A>B<EFBFBD><11> r'c<00><><00>|j<00>dnt|j<00>}dt|<00>j<00>d|<01>d<04>S)N<> anonymousr`rarb)rZ<00>reprrcr(r<>s r%rezMacro.__repr__s:<00><00>"<22>i<EFBFBD>i<EFBFBD>/<2F>{<7B>T<EFBFBD>$<24>)<29>)<29>_<EFBFBD><04><12>4<EFBFBD><04>:<3A>&<26>&<26>'<27>q<EFBFBD><14><06>a<EFBFBD>0<>0r'r")r(r)r*rfr+r<>r.r<>r<>r<>rYrrrgr&r+r&rer#r'r%r1r1<00>s<00><00>!<21>04<30>6<>"<22>6<><10>j<EFBFBD>j<EFBFBD><13>c<EFBFBD><18>"<22>6<><12> 6<>
<15>6<EFBFBD>6<EFBFBD>#<23>;<3B> 6<> <1B> 6<><1C>6<><15>6<><1E>J<EFBFBD>J<EFBFBD>t<EFBFBD>,<2C>6<>:<12><16>J3<>a<EFBFBD>e<EFBFBD>e<EFBFBD>J3<>q<EFBFBD>u<EFBFBD>u<EFBFBD>J3<><13>J3<><17><12>J3<>X<12>Q<EFBFBD>V<EFBFBD>V<EFBFBD>A<EFBFBD>E<EFBFBD>E<EFBFBD>]<5D><12><04><12>QT<51><12> <12><11><16><16><01><05><05><1D> <12>D<EFBFBD> <12>S<EFBFBD> <12>1<>#<23>1r'r1c <00><><00>eZdZdZdZdedefdeje dejdeje deje ddf
d <09>Z ede fd
<EFBFBD><04>Zed ejd ejdd fd<0E><04>Zede dejfd<0F><04>ZexZxZxZZexZxZxZZexZZexZZexZZ exZ!Z"exZ#Z$exZ%xZ&xZ'Z(exZ)xZ*Z+exZ,Z-dejde.fd<11>Z/dejde.fd<12>Z0de1fd<13>Z2de fd<14>Z3de1fd<15>Z4dejjejfd<16>Z6dejnejfd<17>Z8de.fd<18>Z9de fd<19>Z:y)r5agThe default undefined type. This can be printed, iterated, and treated as
a boolean. Any other operation 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
<20><04>_undefined_hint<6E>_undefined_obj<62>_undefined_name<6D>_undefined_exceptionN<6E>hint<6E>objrZ<00>excr c<00><<00>||_||_||_||_yr"r1)r$r6r7rZr8s r%rYzUndefined.__init__2s$<00><00> $<24><04><1C>!<21><04><1B>#<23><04><1C>$'<27><04>!r'c<00>8<00>|jr |jS|jtur|j<00>d<01>St |jt
<00>s$t |j<00><00>d|j<00><02>St |j<00><00>d|j<00><02>S)zXBuild a message about the undefined value based on how it was
accessed.
z is undefinedz has no element z has no attribute )r2r3rr4r%r.rrds r%<00>_undefined_messagezUndefined._undefined_message>s<><00><00>
<10> <1F> <1F><17>'<27>'<27> '<27> <0F> <1E> <1E>'<27> )<29><1A>*<2A>*<2A>-<2D>]<5D>;<3B> ;<3B><19>$<24>.<2E>.<2E><03>4<>#<23>D<EFBFBD>$7<>$7<>8<>9<>:<1C> <20>0<>0<>3<>5<> <0E>  <20><04> 3<> 3<>4<>7<>8<1A><1E>.<2E>.<2E>1<> 3<>
r'r<>r<><00> te.NoReturnc<00>8<00>|j|j<00><00>)zeRaise an :exc:`UndefinedError` when operations are performed
on the undefined value.
)r5r;)r$r<>r<>s r%<00>_fail_with_undefined_errorz$Undefined._fail_with_undefined_errorTs<00><00><13>'<27>'<27><04>(?<3F>(?<3F>@<40>@r'c<00>X<00>|dddk(r|dddk(r t|<01><00>|j<00>S<00>N<><00>__<5F><5F><EFBFBD><EFBFBD><EFBFBD>)<02>AttributeErrorr>r<>s r%<00> __getattr__zUndefined.__getattr__]s9<00><00> <10><02><11>8<EFBFBD>t<EFBFBD> <1B><04>R<EFBFBD>S<EFBFBD> <09>T<EFBFBD> 1<> <20><14>&<26> &<26><13>.<2E>.<2E>0<>0r'<00>otherc<00>.<00>t|<00>t|<01>uSr")rc<00>r$rFs r%<00>__eq__zUndefined.__eq__ss<00><00><13>D<EFBFBD>z<EFBFBD>T<EFBFBD>%<25>[<5B>(<28>(r'c<00>&<00>|j|<01> Sr")rIrHs r%<00>__ne__zUndefined.__ne__vs<00><00><17>;<3B>;<3B>u<EFBFBD>%<25>%<25>%r'c<00>*<00>tt|<00><00>Sr")<02>idrcrds r%<00>__hash__zUndefined.__hash__ys<00><00><11>$<24>t<EFBFBD>*<2A>~<7E>r'c<00><00>y)Nr<r#rds r%<00>__str__zUndefined.__str__|s<00><00>r'c<00><00>yr\r#rds r%r<>zUndefined.__len__s<00><00>r'c#<00>$K<00>dEd{<00><02><02>y7<00><05>w<01>Nr#r#rds r%r<>zUndefined.__iter__<5F>s <00><00><><00><15> <0A> <0A>s <00><01><04>c<00>$K<00>dD]}d<00><04><01><00> y<00>wrSr#)r$<00>_s r%rzUndefined.__aiter__<5F>s<00><00><><00><13>A<EFBFBD> <11><14>s<00>c<00><00>y)NFr#rds r%<00>__bool__zUndefined.__bool__<5F>s<00><00>r'c<00><00>y)Nr5r#rds r%rezUndefined.__repr__<5F>s<00><00>r');r(r)r*rf<00> __slots__rrr+r<>r.rgrr rYr<>r;rr>rE<00>__add__<5F>__radd__<5F>__sub__<5F>__rsub__<5F>__mul__<5F>__rmul__<5F>__div__<5F>__rdiv__<5F> __truediv__<5F> __rtruediv__<5F> __floordiv__<5F> __rfloordiv__<5F>__mod__<5F>__rmod__<5F>__pos__<5F>__neg__r&r^<00>__lt__<5F>__le__<5F>__gt__<5F>__ge__<5F>__int__<5F> __float__<5F> __complex__<5F>__pow__<5F>__rpow__r<5F>rIrKr-rNrPr<>r<>r<>rrrWrer#r'r%r5r5s<00><00> <08><06>I<EFBFBD>!%<25><1C> $<24>,:<3A>
(<28><0F>j<EFBFBD>j<EFBFBD><13>o<EFBFBD>
(<28><0F>U<EFBFBD>U<EFBFBD>
(<28><10>j<EFBFBD>j<EFBFBD><13>o<EFBFBD>
(<28>
<0F>V<EFBFBD>V<EFBFBD>(<28> )<29>
(<28>
<0E>
(<28><0E>
<EFBFBD>C<EFBFBD>
<EFBFBD><0E>
<EFBFBD>*<12>A<01><16>U<EFBFBD>U<EFBFBD>A<01>&'<27>e<EFBFBD>e<EFBFBD>A<01> <16>A<01><12>A<01><12>1<><03>1<><01><05><05>1<><12>1<>/I<01>H<>G<EFBFBD>H<>h<EFBFBD>H<><17>8<EFBFBD>.H<>H<>G<EFBFBD>H<>h<EFBFBD>H<><17>8<EFBFBD>!;<3B>;<3B>K<EFBFBD>,<2C>#=<3D>=<3D>L<EFBFBD>=<3D>3<>3<>G<EFBFBD>h<EFBFBD>2<>2<>G<EFBFBD>g<EFBFBD>7<>7<>H<EFBFBD>{<7B>(B<>B<>F<EFBFBD>B<>V<EFBFBD>B<>f<EFBFBD>v<EFBFBD>(B<>B<>G<EFBFBD>B<>i<EFBFBD>+<2B>3<>3<>G<EFBFBD>h<EFBFBD>)<29>A<EFBFBD>E<EFBFBD>E<EFBFBD>)<29>d<EFBFBD>)<29>&<26>A<EFBFBD>E<EFBFBD>E<EFBFBD>&<26>d<EFBFBD>&<26><1E>#<23><1E><12><13><12><11><13><11><16>!<21>*<2A>*<2A>Q<EFBFBD>U<EFBFBD>U<EFBFBD>+<2B><16><12><11><1F><1F><11><15><15>!7<><12><15>$<24><15><1B>#<23>r'r5<00>loggerzlogging.Logger<65>basec<00><><00><00><04><00><00>Iddl}|jt<00><00><00>j|jt
j <00><00>dtddf<04>fd<05> <0C>G<00><04>fd<06>d|<01>}|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<00>undefr c<00>><00><01><00>jd|j<00>y)NzTemplate variable warning: %s)<02>warningr;)rvrss <20>r%<00> _log_messagez,make_logging_undefined.<locals>._log_message<67>s<00><><00><0E><0E><0E>6<><05>8P<38>8P<38>Qr'c<00><><00><02><00>eZdZdZdej
dej
ddf<06><00>fd<06> Zdef<02><00>fd<07> Zdejej
f<02><00>fd<08> Z
de f<02><00>fd <09> Z <0C>xZ S)
<EFBFBD>0make_logging_undefined.<locals>.LoggingUndefinedr#r<>r<>r r<c<00>|<00><02> t<00>|<00>|i|<02><01>y#|j$r}<03>jd|<03>|<03>d}~wwxYw)NzTemplate variable error: %s)r~r>r5<00>error)r$r<>r<><00>e<> __class__rss <20><>r%r>zKmake_logging_undefined.<locals>.LoggingUndefined._fail_with_undefined_error<6F>sD<00><><00> <18><15><07>2<>D<EFBFBD>C<>F<EFBFBD>C<><43><17>,<2C>,<2C> <18><16> <0C> <0C>:<3A>A<EFBFBD>><3E><17><07><> <18>s<00><00>;<03>6<03>;c<00>0<00><02><00>|<00>t<00>|<00><00>Sr")r~rP<00>r$rrys <20><>r%rPz8make_logging_undefined.<locals>.LoggingUndefined.__str__<5F>s<00><><00> <18><14> <1E><18>7<EFBFBD>?<3F>$<24> $r'c<00>0<00><02><00>|<00>t<00>|<00><00>Sr")r~r<>r<>s <20><>r%r<>z9make_logging_undefined.<locals>.LoggingUndefined.__iter__<5F><00><00><><00> <18><14> <1E><18>7<EFBFBD>#<23>%<25> %r'c<00>0<00><02><00>|<00>t<00>|<00><00>Sr")r~rWr<>s <20><>r%rWz9make_logging_undefined.<locals>.LoggingUndefined.__bool__<5F>r<>r')r(r)r*rYr+rgr>r.rPr<>r<>r<>rW<00> __classcell__)rryrss@<40><>r%<00>LoggingUndefinedr{<00>sc<00><><00><16> <09> <18><1A><15><15> <18>*+<2B>%<25>%<25> <18> <1A> <18> %<25>S<EFBFBD> %<25> &<26>a<EFBFBD>j<EFBFBD>j<EFBFBD><11><15><15>/<2F> &<26> &<26>d<EFBFBD> &<26> &r'r<>)<08>logging<6E> getLoggerr(<00>
addHandler<EFBFBD> StreamHandler<65>sys<79>stderrr5)rsrtr<>r<>rys` @r%<00>make_logging_undefinedr<64><00>si<00><><00>,<0E>~<7E><16>"<22><17>"<22>"<22>8<EFBFBD>,<2C><06><0E><19><19>/<2F>'<27>/<2F>/<2F><03>
<EFBFBD>
<EFBFBD>;<3B><<3C>R<01>I<EFBFBD>R<01>$<24>R<01>&<26>4<EFBFBD>&<26>0 <1C>r'c<00>@<00>eZdZdZdZdefd<04>Zdeddfd<06>Zdeddfd<08>Zy )
<EFBFBD>ChainableUndefineda<64>An 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
r#r c<00><00>t|<00>Sr")r.rds r%r;zChainableUndefined.__html__<5F>s <00><00><12>4<EFBFBD>y<EFBFBD>r'rZc<00><<00>|dddk(r|dddk(r t|<01><00>|Sr@)rDr<>s r%rEzChainableUndefined.__getattr__<5F>s/<00><00> <10><02><11>8<EFBFBD>t<EFBFBD> <1B><04>R<EFBFBD>S<EFBFBD> <09>T<EFBFBD> 1<> <20><14>&<26> &<26><13> r'<00>_namec<00><00>|Sr"r#)r$r<>s r%r^zChainableUndefined.__getitem__<5F>r<>r'N) r(r)r*rfrYr.r;rEr^r#r'r%r<>r<><00>sB<00><00> <08><13>I<EFBFBD><19>#<23><19>
<14><03>
<14>(<<3C>
<14><14><13><14>)=<3D>r'r<>c<00> <00>eZdZdZdZdefd<04>Zy)<06>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
r#r c<00><><00>|jrd|j<00><00>}nE|jtur |j}n&dt |j<00><00>d|j<00>d<04>}d|<01>d<06>S)Nzundefined value printed: zno such element: <20>[<5B>]z{{ z }})r2r3rr4r)r$<00>messages r%rPzDebugUndefined.__str__<5F>sx<00><00> <0F> <1F> <1F>1<>$<24>2F<32>2F<32>1G<31>H<>G<EFBFBD> <11> <20> <20>G<EFBFBD> +<2B><1A>*<2A>*<2A>G<EFBFBD>$<24>$4<>T<EFBFBD>5H<35>5H<35>$I<>#J<><13>D<EFBFBD>(<28>(<28>+<2B>1<EFBFBD>.<2E> <14>
<17>w<EFBFBD>i<EFBFBD>u<EFBFBD>%<25>%r'N)r(r)r*rfrYr.rPr#r'r%r<>r<><00>s<00><00> <08><13>I<EFBFBD> &<26><13> &r'r<>c<00>p<00>eZdZdZdZej xZxZZ ej xZ
xZ xZ Z ej Zy)<04>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
r#N)r(r)r*rfrYr5r>r<>rPr<>rIrKrWrNr<>r#r'r%r<>r<>sH<00><00><08>&<13>I<EFBFBD>#,<2C>#G<>#G<>G<>H<EFBFBD>G<>w<EFBFBD><17>,5<>,P<>,P<>P<>F<EFBFBD>P<>V<EFBFBD>P<>h<EFBFBD><18><1C>7<>7<>Lr'r<>)NFNN)Grfrmr<><00>typingr+<00> collectionsr<00> itertoolsr<00>
markupsaferrr<00> async_utilsr
r <00>
exceptionsr r r<00>nodesr<00>utilsrrrrrrr<00>TypeVarrr<>rgr<00> TYPE_CHECKINGr<47><00>typing_extensions<6E>terEr<00>Protocolr<00>exported<65>async_exportedr4r,r.r2r3r<>r<>r<>r<>r<><00>MappingrTr0rp<00>registerrHr]r/r6r1r5rr<>r<>r<>r<>r#r'r%<00><module>r<>s<><00><01>A<><10>
<EFBFBD><12><1B><1B><1D><1D><1F>#<23>#<23>(<28>,<2C>&<26><1E><1B><19><1F><1A><1C>#<23>$<24> <0A>A<EFBFBD>I<EFBFBD>I<EFBFBD>c<EFBFBD>N<EFBFBD><01> <0A>A<EFBFBD>I<EFBFBD>I<EFBFBD>c<EFBFBD><11><1A><1A>C<EFBFBD><11><15><15>J<EFBFBD>/<2F>0<><01><04>?<3F>?<3F><12>"<22>(<28><16><12><1B><1B><16> <02><08> <02><0E> <0A><01> <0A>a<EFBFBD> <0A><17>Q<EFBFBD>Z<EFBFBD>Z<EFBFBD><01><05><05>&<26><17>3<EFBFBD><17>!<21>!<21>*<2A>*<2A>Q<EFBFBD>U<EFBFBD>U<EFBFBD>#<23>!<21><03>!<21>,0<><18>8<<3C>04<30><06><1E><06><14>:<3A>:<3A>c<EFBFBD>?<3F><06> <0E>F<EFBFBD>F<EFBFBD>3<EFBFBD><01>
<EFBFBD>
<EFBFBD>I<EFBFBD>;<3B><01>
<EFBFBD>
<EFBFBD>3<EFBFBD><0F>#?<3F>@<40>@<40> A<><06> <0C>*<2A>*<2A>Q<EFBFBD>V<EFBFBD>V<EFBFBD>C<EFBFBD><11><15><15>J<EFBFBD>'<27>
(<28> <06>
<11> <06> <0F>Z<EFBFBD>Z<EFBFBD><01>(<28>(<28><13>a<EFBFBD>e<EFBFBD>e<EFBFBD><1A>4<> 5<> <06> <0E>J<EFBFBD>J<EFBFBD>q<EFBFBD>y<EFBFBD>y<EFBFBD><13>a<EFBFBD>e<EFBFBD>e<EFBFBD><1A>,<2C> -<2D><06><0F><06>: B<01> B<01><1C>!<21><1C><01><1C><05><1B><1B><15><15>DN<01>DN<01><16>DN<01>N/<12>/<12>dBE<01>BE<01>JD<18>{<7B>D<18>NC1<>C1<>Lq<1B>q<1B>j,0<>9<EFBFBD>7<1C> <0A>J<EFBFBD>J<EFBFBD>'<27> (<28>7<1C>78<37>v<EFBFBD>v<EFBFBD>i<EFBFBD>7H<37>7<1C><06>V<EFBFBD>V<EFBFBD>I<EFBFBD><16>7<1C>t"<14><19>"<14>J&<26>Y<EFBFBD>&<26>@8<>i<EFBFBD>8r'