[Twisted-web] How to kill the session

Paul Reznicek maillists at ivsn.com
Wed Dec 7 09:12:23 MST 2005

Alberto Trujillo wrote:
> There is any way to kill all the session in Nevow? I mean, I'm loading a 
> lot of variables in the session, and some times I need to get the 
> session clear again, and it's very tedious set each variable to None. So 
> if I coud kill all the session just with one sentences, or get a new one 
> clean than replace the existing one, would be very helpfull for me.

Quite easy:
   session = inevow.ISession(ctx)
   return url.here.up()   # or anything else to switch to the login page

Good luck,

More information about the Twisted-web mailing list