Opened 12 years ago
Closed 12 years ago
#19033 closed Uncategorized (fixed)
avoid unnecessary queries on ForeignKey(on_delete=models.DO_NOTHING)
Reported by: | Collin Anderson | Owned by: | nobody |
---|---|---|---|
Component: | Uncategorized | Version: | 1.4 |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
When deleting objects in the admin, there is no need to run queries on related ForeignKey(on_delete=models.DO_NOTHING).
The query happens when viewing the delete page in the admin. I'm doing some tricky model stuff and would prefer if my model wasn't queried at all.
I propose this change:
https://github.com/django/django/pull/299/files
Change History (2)
comment:1 by , 12 years ago
Triage Stage: | Unreviewed → Accepted |
---|
comment:2 by , 12 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
This should be fixed by #18676 / 1cd6e04cd4f768bcd4385b75de433d497d938f82
Note:
See TracTickets
for help on using tickets.
This should get fixed by #18676 / https://github.com/akaariai/django/tree/fast_delete
I hope to get the branch merged in for 1.5.