#26225: Coalesce Multiple Calls to order_by with Same Arguments
-------------------------------------+-------------------------------------
Reporter: cancan101 | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: Database layer | Version: 1.9
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):
* cc: akaariai, mjtamlyn, jarshwah (added)
* needs_better_patch: => 0
* component: Uncategorized => Database layer (models, ORM)
* needs_tests: => 0
* needs_docs: => 0
* type: Uncategorized => Cleanup/optimization
Comment:
I'm a bit nervous this change might cause subtle backwards
incompatibilities in case someone is relying on a redundant `order_by()`
to reevaluate the queryset. I wonder if you can make your reasoning any
more persuasive than "I see no reason against it." The reasons against it
I see:
1. additional complexity
2. inconsistency with other queyset methods (e.g. should any of them also
try to detect if they are applied redundantly?)
I'll leave it open for opinions from ORM experts.
--
Ticket URL: <https://code.djangoproject.com/ticket/26225#comment:1>
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/067.652a0b9a2ae5edcc7b5fba104d18c0b2%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.