#27722: if a template context is an instance of get_template(), it will raise
"TypeError: context must be a dict rather than RequestContext"
---------------------------------+------------------------------------
     Reporter:  Sayid Munawar    |                    Owner:  nobody
         Type:  Bug              |                   Status:  new
    Component:  Template system  |                  Version:  1.11
     Severity:  Release blocker  |               Resolution:
     Keywords:                   |             Triage Stage:  Accepted
    Has patch:  0                |      Needs documentation:  0
  Needs tests:  0                |  Patch needs improvement:  0
Easy pickings:  0                |                    UI/UX:  0
---------------------------------+------------------------------------

Comment (by Sayid Munawar):

 Quoting Mikhail Podgurskiy from the duplicated ticket:

 > As stated in the django docs, the `{% include %}` tag could accept a
 template instance to render -
 ​https://docs.djangoproject.com/en/1.10/ref/templates/builtins/#include
 >> == include
 >>
 >> Loads a template and renders it with the current context. This is a way
 of “including” other templates within a template.
 >>
 >> ...
 >>
 >> The variable may also be any object with a `render()` method that
 accepts a context. This allows you to reference a compiled Template in
 your context.
 > This leads to RequestContext from the main template been passed to the
 included template.render method and this became prohibited within
 https://code.djangoproject.com/ticket/27258 changeset

--
Ticket URL: <https://code.djangoproject.com/ticket/27722#comment:9>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.5b81110f6c87749aca23ec1a5491347a%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to