I'm using beakers WSGI SessionMiddleware
to manage a session between browser and application.
I am trying to differentiate between when a session is first accessed against any further requests.
Fom the docs it appears there are two useful values made available in the WSGI environment,
["beaker.session"].last_accessed
and ["beaker.session"]["_accessed_time"]
However, on repeated requests ["beaker.session"].last_accessed
is always returning None
, while the timestamp value in ["beaker.session"]["_accessed_time"]
can be seen to be increasing with each request.
Each request performs a ["beaker.session"].save()
- I have tried various combinations of setting auto=True
in the session, and using .save() / .persist()
, but no joy : .last_accessed
is always None
.
I am not using the session to actually persist any data, only to manage the creation of and pass through the session.id
. ( I am using a session type of 'cookie' )