title: Using a mixin with a Django form class
body: <p>I'm thinking about creating a mixin form class so that I can add a common set of fields to a variety of otherwise very different forms. Just using it as a base class won't work because I want to be able to use other forms as base classes like so:</p>
  
  <pre><code>class NoteFormMixin(object):
      note = forms.CharField()
  
  class MainForm(forms.Form):
      name = forms.CharField()
      age = forms.IntegerField()
  
  class SpecialForm(MainForm, NoteFormMixin):
      favorite_color = forms.CharField()
  </code></pre>
  
  <p>My only question is: how does this work? So far it looks like if I use a mixin, then it doesn't recognize the fields set from that mixin:</p>
  
  <pre><code>&gt;&gt;&gt; ff1 = SpecialForm()
  &gt;&gt;&gt; ff1.fields
  {'name': &lt;django.forms.fields.CharField object at 0x178d3110&gt;, 'age': &lt;django.forms.fields.IntegerField object at 0x178d3190&gt;, 'favorite_color': &lt;django.forms.fields.CharField object at 0x178d3210&gt;}
  </code></pre>
  
  <p>Is this just something that can't be done?</p>