Opened 10 years ago

Closed 10 years ago

#24211 closed Cleanup/optimization (fixed)

Remove ValuesQuerySet() and ValuesListQuerySet().

Reported by: Loic Bistuer Owned by: Loic Bistuer
Component: Database layer (models, ORM) Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Some QuerySet methods rely on specialized querysets, namely: ValuesQuerySet(), and ValuesListQuerySet() (and previously DateQuerySet, and DateTimeQuerySet).

When we made custom QuerySet a public API these were a major pain point and required a clunky system with dynamically generated classes and pickle magic.

We already got rid of DateQuerySet and DateTimeQuerySet and now is time to remove the remaining two.

The iteration logic can be cleanly implemented through composition (ModelIterator, ValuesIterator, etc.) and the rest can be moved onto the main QuerySet class.

Change History (4)

comment:1 by Loic Bistuer, 10 years ago

Has patch: set
Status: newassigned

comment:2 by Tim Graham, 10 years ago

Triage Stage: UnreviewedAccepted

comment:3 by Tim Graham, 10 years ago

Triage Stage: AcceptedReady for checkin

comment:4 by Loic Bistuer <loic.bistuer@…>, 10 years ago

Resolution: fixed
Status: assignedclosed

In 4c3bfe9053766d378999d06ec34ee5fd4e39f511:

Fixed #24211 -- Removed ValuesQuerySet() and ValuesListQuerySet().

Thanks Anssi Kääriäinen, Marc Tamlyn, and Tim Graham for the reviews.

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