[Zope] Value of a Session Variable

Dieter Maurer dieter at handshake.de
Fri Sep 3 14:09:40 EDT 2004


Asad Habib wrote at 2004-9-2 13:28 -0400:
>I have a variable which I have placed in the SESSION attribute of the
>REQUEST object. This variable is being initialized to a value of None by a
>DTML method. If an error occurs after a form is submitted, the value of
>this variable is set to the type of error that occurs. In the event that
>an error does occur, the user is redirected to an error page. From the
>error page, the user has the opportunity to return to the form via a
>hyperlink. I need to use the value of this variable in this form but
>it exists sometimes and other times it doesn't. The suprising part is that
>it always exists on the error page. Simply by clicking on the link on the
>error page, the value of this variable is sometimes lost. I am using
>Safari as my browser. Has anyone else experienced the same problem? Any
>help would be greatly appreciated. Thanks.

You must be aware that sessions are tight into Zope's transaction
system. When a Zope error happens, changes to the session
are discarded as part of the transaction abort.

-- 
Dieter


More information about the Zope mailing list