#25009: create_user(..., is_staff=True) raises TypeError multiple values for
keyword argument 'is_staff'
------------------------------+--------------------
     Reporter:  allcaps       |      Owner:  nobody
         Type:  Bug           |     Status:  new
    Component:  contrib.auth  |    Version:  1.8
     Severity:  Normal        |   Keywords:
 Triage Stage:  Unreviewed    |  Has patch:  0
Easy pickings:  1             |      UI/UX:  0
------------------------------+--------------------
 When I do:

 {{{
 >>> from django.contrib.auth.models import User
 >>> user = User.objects.create_user('test', email='[email protected]',
 password='password', is_staff=True)
 Traceback (most recent call last):
   File "<console>", line 1, in <module>
   File "/Users/coen/git/prive/tvdordrecht.nl/env/lib/python2.7/site-
 packages/django/contrib/auth/models.py", line 183, in create_user
     **extra_fields)
 TypeError: _create_user() got multiple values for keyword argument
 'is_staff'
 }}}

 Expected:

 {{{
 >>> user.is_staff
 True
 }}}

 From StackOverflow:
 http://stackoverflow.com/questions/30711544/create-staff-user-in-
 django/30946633#30946633


 Related
 
https://github.com/bak1an/django/commit/dc2f67679712412e2f8bdfbecc340f796d6dbc24
 https://code.djangoproject.com/ticket/20541

--
Ticket URL: <https://code.djangoproject.com/ticket/25009>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/050.16a4d4fbf3c56ab70fcdd51a186005e9%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to