Re: [Django] #5865: cycle template tag should accept a single argument

35 views
Skip to first unread message

Django

unread,
Sep 10, 2011, 7:39:29 PM9/10/11
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
---------------------------------------+---------------------------------
Reporter: gwilson | Owner: munhitsu
Type: New feature | Status: reopened
Milestone: | Component: Template system
Version: SVN | Severity: Normal
Resolution: | Keywords:
Triage Stage: Accepted | Has patch: 1
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
---------------------------------------+---------------------------------
Changes (by Alex):

* ui_ux: => 0
* stage: Design decision needed => Accepted


Comment:

Discussion with Carl: this new syntax would be ambiguous with the current
syntax, however this is a good feature, and the current API is kind of
silly. This is accepted, provisional on creating a new, more sane and
consistent syntax, to be placed in the future module.

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

Django

unread,
Sep 15, 2011, 2:54:19 PM9/15/11
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
---------------------------------------+---------------------------------
Reporter: gwilson | Owner: munhitsu
Type: New feature | Status: reopened
Milestone: | Component: Template system
Version: SVN | Severity: Normal
Resolution: | Keywords:
Triage Stage: Accepted | Has patch: 1
Needs documentation: 1 | Needs tests: 1
Patch needs improvement: 1 | Easy pickings: 0
UI/UX: 0 |
---------------------------------------+---------------------------------
Changes (by ptone):

* needs_docs: 0 => 1
* needs_tests: 0 => 1
* needs_better_patch: 0 => 1


--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:15>

Django

unread,
Jan 9, 2024, 2:54:35 AM1/9/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
---------------------------------+------------------------------------
Reporter: Gary Wilson | Owner: munhitsu
Type: New feature | Status: new
Component: Template system | Version: dev

Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 1
Needs tests: 1 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
---------------------------------+------------------------------------

Comment (by Alexander Lazarević):

Is this still considered a desirable feature?

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:17>

Django

unread,
Jan 9, 2024, 3:01:24 AM1/9/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
---------------------------------+------------------------------------
Reporter: Gary Wilson | Owner: munhitsu
Type: New feature | Status: new
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 1
Needs tests: 1 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
---------------------------------+------------------------------------

Comment (by Mariusz Felisiak):

Replying to [comment:17 Alexander Lazarević]:


> Is this still considered a desirable feature?

Yes, IMO nothing has changed.

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:18>

Django

unread,
Jan 9, 2024, 9:11:18 PM1/9/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned

Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 1
Needs tests: 1 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Alexander Lazarević):

* owner: munhitsu => Alexander Lazarević
* status: new => assigned


--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:19>

Django

unread,
Jan 9, 2024, 11:47:47 PM1/9/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 1
Needs tests: 1 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Alexander Lazarević):

I created a PR https://github.com/django/django/pull/17716

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:20>

Django

unread,
Jan 10, 2024, 3:17:40 AM1/10/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Alexander Lazarević):

* needs_better_patch: 1 => 0
* needs_tests: 1 => 0
* needs_docs: 1 => 0


Comment:

For the new PR I'm going to remove "Needs documentation", "Needs tests"
and "Patch needs improvement". Please set these flags again if required
(or I should have left them set in the first place).

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:21>

Django

unread,
Jan 16, 2024, 8:39:33 AM1/16/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Alexander Lazarević):

I just put something together at https://sandbox.e11bits.com/ to showcase
the feature more broadly. Maybe people can judge by that, if the feature
is desirable and help with the code review? It's just a quick hack, so
don't expect too much. The examples are more or less the ones found as
testcases in the PR. (crossposted to discord)

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:22>

Django

unread,
Jan 16, 2024, 11:44:29 AM1/16/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Natalia Bidart):

Replying to [comment:22 Alexander Lazarević]:


> I just put something together at https://sandbox.e11bits.com/ to
showcase the feature more broadly. Maybe people can judge by that, if the
feature is desirable and help with the code review? It's just a quick
hack, so don't expect too much. The examples are more or less the ones
found as testcases in the PR. (crossposted to discord)

Thank you Alexander for your work on this. In order to unify the
conversation in a single place, I will reply to the forum thread with my
view, hopefully we can agree on an implementation design there and then
come back to the ticket.

As a reference, [https://forum.djangoproject.com/t/cycle-template-tag-
should-accept-a-single-argument/27010 this is the forum post].

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:23>

Django

unread,
Jan 17, 2024, 6:52:41 AM1/17/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Alexander Lazarević):

After the discussion in https://forum.djangoproject.com/t/cycle-template-
tag-should-accept-a-single-argument/27010/3 I'm withdrawing the PR.

My implementation would have introduced an ambiguity that would have had
it made it harder for users to use the `cycle` tag.

In the discussion @carlton mentioned that it could be worth "... to
investigate [is] whether we could add * and ** list and dictionary
expansion to the DTL. cycle could benefit from list expansion.".

So I'm trying to come up with something in that direction instead.

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:24>

Django

unread,
Jan 19, 2024, 7:07:47 AM1/19/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Alexander
| Lazarević
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* has_patch: 1 => 0


Comment:

There is nothing to review, at least for now.

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:25>

Django

unread,
Jan 28, 2024, 5:51:00 AM1/28/24
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
---------------------------------+------------------------------------
Reporter: Gary Wilson | Owner: (none)

Type: New feature | Status: new
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
---------------------------------+------------------------------------
Changes (by Alexander Lazarević):

* owner: Alexander Lazarević => (none)
* status: assigned => new

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:26>

Django

unread,
Apr 27, 2025, 5:24:51 AM4/27/25
to django-...@googlegroups.com
#5865: cycle template tag should accept a single argument
-------------------------------------+-------------------------------------
Reporter: Gary Wilson | Owner: Giannis
| Terzopoulos
Type: New feature | Status: assigned
Component: Template system | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Giannis Terzopoulos):

* owner: (none) => Giannis Terzopoulos
* status: new => assigned

--
Ticket URL: <https://code.djangoproject.com/ticket/5865#comment:27>
Reply all
Reply to author
Forward
0 new messages