I'm trying to integrate django-registration with django-math-captcha, but I'm running into troubles. I followed the examples math captcha's github. If I subclass registration.forms.RegistrationForm with MathCaptchaModelForm or MathCaptchaForm I get different errors
My code and respective errors
class RegistrationForm(forms.Form, MathCaptchaModelForm)
Error: Error when calling the metaclass bases metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases
or
class RegistrationForm(forms.Form, MathCaptchaForm) Error:Error when calling the metaclass bases. Cannot create a
consistent开发者_开发问答 method resolution order (MRO) for bases Form, MathCaptchaForm
Thanks for your help!
Just extend MatchCaptchaModelForm as it already extends forms.ModelForm.
精彩评论