Re: [Zope] Can't pickle objects in acquisition wrappers

2005-12-19 Thread Gabriel Genellina

At Monday 19/12/2005 15:07, Keith Alperin wrote:


This is almost definitely my problem as my products keep direct
references to other persistent objects all of the time.

Out of curiosity, has this always been a poor practice or is it
something that changed recently?


Not sure when started to be checked, but has never been a good practice, at 
least because the memory leak it produces (circular references).



Gabriel Genellina
Softlab SRL 


___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Can't pickle objects in acquisition wrappers

2005-12-18 Thread Gabriel Genellina

At Monday 19/12/2005 00:53, Keith Alperin wrote:


I'm returning to Zope after about a year away and am working on a
project that i have pieced together over about 4 years.  I recently
deployed this project (a family history web site) under a zope 2.7.x
install (it used to run on a 2.4.x install) and now I can't seem to
update any of my objects.  when i try to save them, I get a
TypeError: Can't pickle objects in acquisition wrappers.  I was never


You should not store a persistent attribute that is an acquisition wrapper 
itself. (What is that... see the corresponing chapter in the Zope 
Developers Guide).
You are developing your own Product, I presume? Perhaps, you are keeping a 
direct reference to another persistent object? You should store its id 
instead, o use a container like ObjectManager.

Without more information that's all I can guess...


Gabriel Genellina
Softlab SRL 


___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope-dev )