[Zope] Testing for and/or avoiding acquisition
Dieter Maurer
dieter@handshake.de
Wed, 9 Jul 2003 20:26:58 +0200
Samir Mishra wrote at 2003-7-9 13:38 +0400:
> look at context.aq_explicit. I had a similar problem a short while ago, got
> help on this list. So you could search for emails in this list with keyword
> 'aq_explicit'. And in case I'm wrong about this, someone pls let me know.
You can use "aq_explicit" but it is not completely safe (although
it will work in most cases).
The best way would be to apply the patch "hasattr_unacquired"
you find in the Zope collector (hopefully, it will be included
in Zope 2.7). Of course, this requires full control over the
Zope installation.
Finally, you can implement the "hasattr_unacquired" in an External
Method and use this.
Dieter