#5874: Template variables inside filters are not parsed correctly
------------------------------+---------------------------------------------
Reporter:  Thejaswi Puthraya  |       Owner:  nobody         
  Status:  new                |   Component:  Template system
 Version:  SVN                |    Keywords:                 
   Stage:  Unreviewed         |   Has_patch:  0              
------------------------------+---------------------------------------------
 Whenever a variable is used in a filter's (have checked for slice
 only...might be applicable for other filters also) arguments it is wrongly
 parsed and we get a TemplateSyntaxError which says "slice requires 1
 arguments, 0 provided".
 From the traceback here is what I received on the output:
 The token being
 {{{
 u'some_item.var2|slice:":{{ forloop.counter0'
 }}}
 Notice the missing "}}"

 Here is the test code:
 {{{
 {% for some_item in many_items %}
   {{ some_item.var1 }} {{ some_item.var2|slice:":{{ forloop.counter0 }}"
 }}
 {% endfor %}
 }}}

-- 
Ticket URL: <http://code.djangoproject.com/ticket/5874>
Django Code <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to