On 19-04-16 17:34:11, Will Gordon wrote: >In the same way that editable fields are forced to not be included in a >ModelForm ( >https://github.com/django/django/blob/master/django/forms/models.py#L146), >I would like to propose that "required" fields (`blank=False`) be forced to >be included in a ModelForm.
Is there anything missing in Django that would prevent you from doing this in a subclass of ModelForm? My projects tend to go with one or two common base classes in between actual forms/views and Django's forms/views, and I'd argue that this is not too much trouble for a feature like this. I'm also against adding a warning for this by default – I'd like to keep warnings reserved for issues with more of an impact. I think for every one of my larger projects, I'd have to silence this warning, which is annoying (and keeping it there introduces warning fatigue, which Django so far does a good job of avoiding). Tobias -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To post to this group, send email to django-developers@googlegroups.com. Visit this group at https://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/20190417080037.uu2ybg3etwespmen%40cordelia.localdomain. For more options, visit https://groups.google.com/d/optout.
signature.asc
Description: PGP signature