I have the session engine settings as follows:
SESSION_ENGINE = 'django.contrib.sessions.backends.cached_db'
SESSION_SAVE_EVERY_REQUEST = True
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': '127.0.0.1:11211',
'TIMEOUT': 60*60,
}
}
I go to 127.0.0.1:8000 with Browser 1 and can successfully log in.
Then I go to 127.0.0.1:8000 with Browser 2 and can also successfully log in.
Now I go to 127.0.0.1:8000 with Browser 1 and get the following error message:
SuspiciousOperation at /
The request's session was deleted before the request completed.
The user may have logged out in a concurrent request, for example.
How can this error be avoided? The user should be able to log in with as many browsers as he likes. I don't mind if he gets logged out from the non-active browsers, but an error is not acceptable.