#22374: Suggest to validate unique before running clean in models full_clean etc.. -------------------------------------+------------------------------------- Reporter: dspjmt@… | Owner: nobody Type: Bug | Status: closed Component: Database layer | Version: 1.6 (models, ORM) | Resolution: wontfix Severity: Normal | Triage Stage: Keywords: | Unreviewed Has patch: 0 | Needs documentation: 0 Needs tests: 0 | Patch needs improvement: 0 Easy pickings: 0 | UI/UX: 0 -------------------------------------+------------------------------------- Changes (by timo):
* resolution: needsinfo => wontfix Comment: I don't think it's a good idea. In particular, there is no guarantee that `validate_unique()` will be called. Note this comment in `django.forms.models`: {{{ # self._validate_unique will be set to True by BaseModelForm.clean(). # It is False by default so overriding self.clean() and failing to call # super will stop validate_unique from being called. }}} -- Ticket URL: <https://code.djangoproject.com/ticket/22374#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/074.d0635672f99d746b054efeebade2a750%40djangoproject.com. For more options, visit https://groups.google.com/d/optout.