I\'m trying to store the user\'s ID in the session using django.contrib.auth.login . But it is not working not as expected.
I\'m getting error login() takes exac
Another way:
from django.contrib.auth import login as auth_login
then call auth_login(request, user) instead of login(request, user).
auth_login(request, user)
login(request, user)