On Jan 19, 2011, at 10:32 AM, Anthony wrote:
> So, I guess the question is, what should the book (and the 'call' function in 
> the scaffolding app) be recommending, session.forget() or 
> session.forget(response)? At the very least, the difference between the two 
> should be explained in the book. 

I can't think of a good use case for session.forget() (as opposed to 
session.forget(response)). Ron is right that it would eliminate the session 
file write, but that's pretty negligible in the overall scheme of things; I 
doubt it's worth supporting, let alone documenting. 

> 
> On Wednesday, January 19, 2011 1:26:06 PM UTC-5, ron_m wrote:
> If the response is left off the session.forget() parameter list it defaults 
> to None. The end result then is the session._forget state variable is set 
> True but the session file is not unlocked in the _unlock function. This would 
> enhance performance by bypassing the writing of the session file at the end 
> of the request-response cycle when the session state is unchanged but won't 
> release the lock to let other requests proceed on that session. I could see 
> this as a possible use of session.forget(..) so it looks like a documentation 
> issue.
> 


Reply via email to