[Django] #25031: unordered_list template filter fails for certain sequences

12 views
Skip to first unread message

Django

unread,
Jun 26, 2015, 2:08:33 PM6/26/15
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
------------------------------+--------------------------------------------
Reporter: noamkush | Owner: nobody
Type: Bug | Status: new
Component: Template | Version: 1.8
system |
Severity: Normal | Keywords: unordered_list template filter
Triage Stage: Unreviewed | Has patch: 1
Easy pickings: 0 | UI/UX: 0
------------------------------+--------------------------------------------
unordered_list consumes it's input by pairs. When given a sequence that
contains at an even position two strings and then a list (such as {{{['a',
'a', ['b']]}}}), it will consume both strings and treat the list as an
item on it's own, and not as a sublist of the second string.

The result:
{{{
>>> from django.template import defaultfilters
>>> print str(defaultfilters.unordered_list(['a', 'a', ['b']]))
<li>a</li>
<li>a</li>
<li>[&#39;b&#39;]</li>
}}}

See pull request with a test and a fix:
https://github.com/django/django/pull/4917

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

Django

unread,
Jun 27, 2015, 9:20:47 AM6/27/15
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
-------------------------------------+-------------------------------------

Reporter: noamkush | Owner: nobody
Type: Bug | Status: new
Component: Template system | Version: 1.8
Severity: Release blocker | Resolution:
Keywords: unordered_list | Triage Stage: Accepted
template filter |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* needs_better_patch: => 0
* needs_docs: => 0
* severity: Normal => Release blocker
* needs_tests: => 0
* stage: Unreviewed => Accepted


Comment:

Regression in b3660d28f3422a33a84de7a7ccad404b3135a1a8

--
Ticket URL: <https://code.djangoproject.com/ticket/25031#comment:1>

Django

unread,
Jun 27, 2015, 9:39:32 AM6/27/15
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
-------------------------------------+-------------------------------------
Reporter: noamkush | Owner: nobody
Type: Bug | Status: closed

Component: Template system | Version: 1.8
Severity: Release blocker | Resolution: fixed

Keywords: unordered_list | Triage Stage: Accepted
template filter |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham <timograham@…>):

* status: new => closed
* resolution: => fixed


Comment:

In [changeset:"e291fc4757e952fd4f663d88adca416b016db13e" e291fc4]:
{{{
#!CommitTicketReference repository=""
revision="e291fc4757e952fd4f663d88adca416b016db13e"
Fixed #25031 -- Fixed a regression in the unordered_list template filter.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/25031#comment:2>

Django

unread,
Jun 27, 2015, 9:46:47 AM6/27/15
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
-------------------------------------+-------------------------------------
Reporter: noamkush | Owner: nobody

Type: Bug | Status: closed
Component: Template system | Version: 1.8
Severity: Release blocker | Resolution: fixed
Keywords: unordered_list | Triage Stage: Accepted
template filter |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"fd61ce3817251c487fd98c3ed178a8258775329e" fd61ce38]:
{{{
#!CommitTicketReference repository=""
revision="fd61ce3817251c487fd98c3ed178a8258775329e"
[1.8.x] Fixed #25031 -- Fixed a regression in the unordered_list template
filter.

Backport of e291fc4757e952fd4f663d88adca416b016db13e from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/25031#comment:3>

Django

unread,
Jun 14, 2017, 2:31:28 PM6/14/17
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
-------------------------------------+-------------------------------------
Reporter: Noam | Owner: nobody
Type: Bug | Status: new

Component: Template system | Version: 1.8
Severity: Release blocker | Resolution:
Keywords: unordered_list | Triage Stage: Accepted
template filter |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by msimonds):

* status: closed => new
* resolution: fixed =>


Comment:

This is still causing me trouble.

--
Ticket URL: <https://code.djangoproject.com/ticket/25031#comment:4>

Django

unread,
Jun 14, 2017, 3:00:10 PM6/14/17
to django-...@googlegroups.com
#25031: unordered_list template filter fails for certain sequences
-------------------------------------+-------------------------------------
Reporter: Noam | Owner: nobody
Type: Bug | Status: closed

Component: Template system | Version: 1.8
Severity: Release blocker | Resolution: fixed

Keywords: unordered_list | Triage Stage: Accepted
template filter |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham):

* status: new => closed
* resolution: => fixed


Comment:

Please open a new ticket with steps to reproduce the issue, thanks.

--
Ticket URL: <https://code.djangoproject.com/ticket/25031#comment:5>

Reply all
Reply to author
Forward
0 new messages