#23656: FormMixin.get_form's form_class argument should be optional --------------------------------------+------------------------------------ Reporter: charettes | Owner: nobody Type: Cleanup/optimization | Status: new Component: Generic views | Version: master Severity: Normal | Resolution: Keywords: | Triage Stage: Accepted Has patch: 1 | Needs documentation: 0 Needs tests: 0 | Patch needs improvement: 0 Easy pickings: 0 | UI/UX: 0 --------------------------------------+------------------------------------ Changes (by charettes):
* needs_better_patch: 1 => 0 Comment: I think I came up with a decent solution. If someone overrides `get_form` without defining a default value for `form_class` a deprecation warning is raised and the unbound method is wrapped in order to make sure `form_class` defaults to `get_form_class()` if not provided. I updated the PR with the POC. I guess we should we also mention this change in the deprecated section of the release notes? -- Ticket URL: <https://code.djangoproject.com/ticket/23656#comment:4> 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/067.b80e45ff01d5181ba653761f6277925d%40djangoproject.com. For more options, visit https://groups.google.com/d/optout.