Hi,
I followed the instructions in the documentation for Authenticating
against Django's user database from Apache. But I cannot get it to work
correctly. This is the error message I am getting:
File "/usr/local/lib/python2.4/site-packages/mod_python/apache.py",
line 299, in HandlerDispatch
result = object(req)
File
"/home2/cwurld/lib/python2.4/django/contrib/auth/handlers/modpython.py",
line 33, in authenhandler
user = User.objects.get(**kwargs)
File "/home2/cwurld/lib/python2.4/django/db/models/manager.py", line
67, in get
return self.get_query_set().get(*args, **kwargs)
File "/home2/cwurld/lib/python2.4/django/db/models/query.py", line
214, in get
assert len(obj_list) == 1, "get() returned more than one %s -- it
returned %s! Lookup parameters were %s" %
(self.model._meta.object_name, len(obj_list), kwargs)
AssertionError: get() returned more than one User -- it returned 4!
Lookup parameters were {'username': None, 'is_staff': True,
'is_active': True}
It apears that the username of the person logged in is getting lost
somewhere. During the db lookup the username is None. I get 4 records
since there are 4 users.
Anyone have any ideas how to fix this?
Thanks,
Chuck
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Django
users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---