#26366: Implicitly save related models as needed instead of raising "unsaved related objects error" on Model.save() -------------------------------------+------------------------------------- Reporter: aki33524 | Owner: nobody Type: New feature | Status: closed Component: Database layer | Version: 1.9 (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 aki33524): Replying to [comment:4 timgraham]: > I don't think there's much justification for making a change in Django here. As noted [https://code.djangoproject.com/ticket/10811#comment:5 in a related ticket], "Automatically saving related objects is too magic; I'm sure it would be considered unexpected and undesirable in some circumstances." > > An alternate solution in your own code is: > {{{ > bar.foo.save() > bar.save() > }}} It doesn't work. -- Ticket URL: <https://code.djangoproject.com/ticket/26366#comment:5> 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 django-updates+unsubscr...@googlegroups.com. To post to this group, send email to django-updates@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-updates/066.ae669931d94df159c63c4a7e23249ae2%40djangoproject.com. For more options, visit https://groups.google.com/d/optout.