Opened 2 years ago

Last modified 2 years ago

#25236 new Cleanup/optimization

Remove ifequal from the template language

Reported by: Daniel Greenfeld Owned by: nobody
Component: Template system Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Someday/Maybe
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

No modern project uses ifequal. No one recommends it. I argue it is taking up valuable bytes in the project. Let's remove it.

Change History (7)

comment:1 Changed 2 years ago by Tim Graham

Seems like a good idea, although I am afraid we may get more pushback regarding "needless deprecations" from old, large Django projects that use it. A middle ground could be to remove it from the documentation. Would you like to write to the DevelopersMailingList to see what others think?

comment:2 Changed 2 years ago by Marc Tamlyn

Triage Stage: UnreviewedAccepted

The smart if tag which made ifequal redundant was introduced in Django 1.2. Really, ifequal should have been deprecated then. I agree this is a good candidate for deprecation, and I'd rather take a bit of flak for "needless" deprecations than keep tested (?) but undocumented code around forever.

comment:3 Changed 2 years ago by Daniel Greenfeld

Last edited 2 years ago by Tim Graham (previous) (diff)

comment:4 Changed 2 years ago by Tim Graham <timograham@…>

In a3830f6:

Refs #25236 -- Removed ifequal/ifnotequal usage.

comment:5 Changed 2 years ago by Tim Graham <timograham@…>

In 787cc7a:

Refs #25236 -- Discouraged use of ifequal/ifnotequal template tags.

comment:6 Changed 2 years ago by Tim Graham

Triage Stage: AcceptedSomeday/Maybe

Moving to "Someday/Maybe" as we have multiple complaints on the mailing list that updating projects for this removal will be too onerous to justify the cleanup.

comment:7 Changed 2 years ago by Tim Graham <timograham@…>

In 21128793:

[1.8.x] Refs #25236 -- Discouraged use of ifequal/ifnotequal template tags.

Backport of 787cc7aa843d5c0834f56b5f8ae03b86ce553c51 from master

Note: See TracTickets for help on using tickets.
Back to Top