title: Django, can't log in after creating user
body: <p>I created user in the Django shell and tried to authenticate it, but can't. That returns <code>NoneType</code>. Also, I check that is_superuser, is_stuff, is_active is True</p>
  
  <pre><code>&gt;&gt;&gt; from django.contrib.auth.models import User
  &gt;&gt;&gt; from django.contrib.auth import authenticate
  &gt;&gt;&gt; User.objects.create(username='user', password='password', email='someemail')
  &gt;&gt;&gt; User.objects.all()
  &gt;&gt;&gt; &lt;QuerySet [&lt;User: admin&gt;, &lt;User: user&gt;]&gt;
  &gt;&gt;&gt; admin
  &gt;&gt;&gt; user = authenticate(username='user', password='password')
  &gt;&gt;&gt; user
  &gt;&gt;&gt; user.is_active
  Traceback (most recent call last):
  File "&lt;console&gt;", line 1, in &lt;module&gt;
  AttributeError: 'NoneType' object has no attribute 'is_active'
  &gt;&gt;&gt; type(user)
  &lt;class 'NoneType'&gt;
  &gt;&gt;&gt; admin = authenticate(username='admin', password='wa23sd54fg')
  &gt;&gt;&gt; admin
  &lt;User: admin&gt;
  &gt;&gt;&gt; admin.is_active()
  Traceback (most recent call last):
  File "&lt;console&gt;", line 1, in &lt;module&gt;
  TypeError: 'bool' object is not callable
  &gt;&gt;&gt; admin.is_active
  True
  
  &gt;&gt;&gt; user = User.objects.get(pk=2)
  &gt;&gt;&gt; user
  &lt;User: user&gt; 
  &gt;&gt;&gt; user.is_active
  True
  &gt;&gt;&gt; user.is_superuser
  True
  &gt;&gt;&gt; user.is_staff
  True
  </code></pre>
  
  <p>When tried log in with use in admin panel, it shows the error:</p>
  
  <blockquote>
    <p>Please enter the correct username and password for a staff account. Note that both fields may be case-sensitive.</p>
  </blockquote>