Form subclass trying to override parent form field
|Reported by:||nwp||Owned by:||nobody|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
If a form subclass tries to override a parent form's field definition, the definition is overridden but the field is repeated.
class FormA(forms.Form): somefield = forms.AnyField(anyargs) class FormB(FormA): somefield = forms.OtherField(otherargs)
FormB ends up with *two* somefields, both forms.Otherfield. This seems to me to be a bug in DeclarativeFieldsMetaclass's
__new__ method - I think it should do some checking for duplicates round about as it adds fields to base_fields.
This is svn r6471.