Quantcast
Channel: Mako: Ticket Query
Viewing all articles
Browse latest Browse all 38

#184: Template.render_context(context) (re)sets context['self']

$
0
0

I'm not quite positive that this is a bug, but I’m pretty sure it is.

When Template.render_context() is called, it sets contextself?. So, if one renders another template like this:

subtemplate.render_context(context)

After the call to render_context(), contextself? no longer contains the correct namespace. This (at least) causes problems for any <%block>s in the calling template.

I've attached a short test script which demonstrates the problem.


Viewing all articles
Browse latest Browse all 38

Trending Articles