Reputation: 191
I need my (python) google app to perform an action (submit a form) if the user logs out. This is simple enough to do if they use the logout links in my app, but if they log out from a gmail page or something, I don't know how to handle it.
Another possible source of error would be if the user closed the browser window, shut down their computer, etc. resulting in a log-off. Is this scenario is equivalent to what I describe in the previous paragraph, or are they different somehow?
To expand this question since it seems the above is not at all trivial: if I set a cleanup function on a timeout, will the python session in fact continue to run in the GAE cloud after the cookie expires, and actually execute the timeout function?
Upvotes: 2
Views: 206
Reputation: 6627
Close browser window and shut down computer result log out because of session expired (cookie). It is slightly different from user click log out manually. In both case, I don't think GAE can track these behaviors.
The best thing that I can think about is to develop a browser extension. Or just don't design the service based on detecting user's log out.
Upvotes: 2