Opened 8 years ago

Closed 8 years ago

Last modified 3 years ago

#10199 closed (fixed)

aggregate method on queryset shouldn't alter the state of the queryset

Reported by: Alex Owned by: Alex
Component: Database layer (models, ORM) Version: master
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


basically it should clone the query so as not to affect the queryset for future usage, I'll post a testcase shortly.

Attachments (1)

aggregation-clone.diff (1.9 KB) - added by Alex 8 years ago.

Download all attachments as: .zip

Change History (4)

Changed 8 years ago by Alex

comment:1 Changed 8 years ago by Alex

  • Has patch set
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Status changed from new to assigned
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 8 years ago by russellm

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [9819]) Fixed #10199 -- Modified aggregate() calls to clone the base query so that the base query can be reused. Thanks to Alex Gaynor for the report and patch.

comment:3 Changed 3 years ago by akaariai

  • Component changed from ORM aggregation to Database layer (models, ORM)
Note: See TracTickets for help on using tickets.
Back to Top