-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mika, David P (GE, Research) wrote:

>> Can someone explain why the test below  (test_persistence) is failing?
>> I am adding an attribute after object creation with __setstate__, but
>> I can't get the new attribute to persist.

You are mutating the object *inside* your __setstate__:  the ZODB
persistence machinery clears the '_p_changed' flag after you *exit* from
'__setstate__':  the protocol is not intended to support a persistent
"write-on-read".


Tres.
- --
===================================================================
Tres Seaver          +1 540-429-0999          [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHjvYH+gerLs4ltQ4RAl59AJ0f808PqemiqOyOp+jaNVUvIbkvVQCfcpxw
KnvNkdn/+nD5N14iadB9PUo=
=cm0X
-----END PGP SIGNATURE-----

_______________________________________________
For more information about ZODB, see the ZODB Wiki:
http://www.zope.org/Wikis/ZODB/

ZODB-Dev mailing list  -  ZODB-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zodb-dev

Reply via email to