#11302 closed (fixed)
Generic Formset executes unnescesary SQL queries
Reported by: | Alex Gaynor | Owned by: | Brian Rosner |
---|---|---|---|
Component: | Contrib apps | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
In cases where it's passed a new, but unsaved object it still queries the DB for records, which by definition can't exist.
Attachments (1)
Change History (4)
by , 15 years ago
Attachment: | generic-formset-optimization.diff added |
---|
comment:1 by , 15 years ago
Owner: | changed from | to
---|
comment:2 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:3 by , 15 years ago
(In [10982]) [1.0.X] Fixed #11302 -- Avoid unnesscary (and possibly unintentional) queries/results from generic inline formsets.
When an instance with no primary key value is passed in to a generic inline
formset we ensure no queries/results occur. Thanks Alex Gaynor.
Backport of [10981] from trunk.
Note:
See TracTickets
for help on using tickets.
(In [10981]) Fixed #11302 -- Avoid unnesscary (and possibly unintentional) queries/results from generic inline formsets.
When an instance with no primary key value is passed in to a generic inline
formset we ensure no queries/results occur. Thanks Alex Gaynor.