Opened 6 years ago

Last modified 5 years ago

#14688 new Bug

BaseInlineFormSet does not support "auto_id"

Reported by: vicvicvic Owned by: nobody
Component: Forms Version: master
Severity: Normal Keywords: formsets
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: yes
Easy pickings: no UI/UX: no


BaseInlineFormSet.__init__ does not accept the auto_id argument, unlike its ancestors. Furthmore, its parent BaseModelFormSet takes **kwargs and passes them along.

I can't think of a good reason for this omission/difference. I've attached a small patch to "match" BaseInlineFormSet.__init__ with BaseModelFormSet.__init__. The patch puts the "new" auto_id argument last in order to maximize backwards compatibility (the order is different for BaseModelFormSet).

Arguably, both prefix and auto_id could be removed from the explicit arg list since they're just passed along (in both BaseModelFormSet and BaseInlineFormSet).

Attachments (1)

BaseInlineFormset-auto_id.patch (1.3 KB) - added by vicvicvic 6 years ago.
Adds auto_id to BaseInlineFormSet

Download all attachments as: .zip

Change History (5)

Changed 6 years ago by vicvicvic

Adds auto_id to BaseInlineFormSet

comment:1 Changed 6 years ago by russellm

  • Needs documentation unset
  • Needs tests set
  • Patch needs improvement set
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 5 years ago by jaddison

  • Severity set to Normal
  • Type set to Bug

comment:3 Changed 4 years ago by aaugustin

  • UI/UX unset

Change UI/UX from NULL to False.

comment:4 Changed 4 years ago by aaugustin

  • Easy pickings unset

Change Easy pickings from NULL to False.

Note: See TracTickets for help on using tickets.
Back to Top