Hi pyguy, welcome to the forum, be sure to read this thread
Regarding your problem, i don't know how .Net or Java handles sessions but i believe Flask handles that client-side, meaning your session is stored in your browser (it's an implementation on top of cookies i think -could be wrong-)
I've never used Flask before so i just grabbed the code from the quickstart and tested what you said and in fact the session didn't expire. I checked the API docs and found this:
Registers a function to be run before the first request to this instance of the application.
I just used that decorator on my logout view, so that if it's the first request to the server from my client it'll try to log me out.
- Code: Select all
# remove the username from the session if it's there
Hope that helps, let us know if that worked out for you.