#26664: Support of model_object.delete(cascade=True)
-------------------------------------+-------------------------------------
Reporter: srkunze | Owner: nobody
Type: New feature | Status: closed
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: wontfix
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by srkunze):
Hi Tim. I know that it might be dangerous. However, the reason why I
suggest this feature is that we needed it in a backwards migration. I.e.
it removes some data that has been created by its corresponding forward
migration. In this case, we are 110% sure that it does not delete anything
more than necessary.
Overriding ```Model.delete()``` does not help in this case as it is NOT
the original Model but a fake migration model.
We already have a helper function that carries out this deletion manually
but we thought that a Django-provided way would be much cleaner.
--
Ticket URL: <https://code.djangoproject.com/ticket/26664#comment:2>
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/065.1b2320e151be1f85c6785956aae57e08%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.