Ben Last (ZODBDev) wrote:
And does this provoke your leak?
That I don't know, that's why I'm trying to track instance creation :)
Why are you bothering to do that? This goes back to my original
debugging suggestion: you're aiming to get the simplest possible test
case which ALWAYS shows a leak...
Are any arguments passed which aren't simple strings?
Yes. The environment, for instance, is a "dictish object" which means
that one can access the members as attributes as well as using dict
Why are you bothering with this? And what does the code being this
object look like? Funny business like this is often the source of leaks...
if flash is None:
flash = getattr(environment,'flash',False)
b) a boolean (strictly, something that evaluates True/False in Python)
Okay, so when is it not either the True or False singleton?
This is used in many places, and there appear to be no leaks of them at
That's like saying "guns are used in many places, and no-one has shot
themselves in the foot". It doesn't mean there's nto blood pouring out
of your foot ;-)
We use the dictish objects because otherwise, when writing Python
in the context of ZPT, one needs always to be aware of when one's
dealing with an object (most cases) or a dict (edge cases)
number of times that caused problems was growing. We adopted an idiom
by which multiple-value results are always returned as objects.
I'd suggest that is "wrong". The most common way to do this is to store
things in a simple python dictionary and return that.
What's "doTag" ?
A method of what? Where's the code?
that takes the parameters (all are simple except img) and
And what is img?
Why pass? might be interesting to see what throws attribute errors and
It would be on the test site. In the production environment, problems
like this would get reported via Zope error pages to customers, who
aren't interested in them!
Jeez, talk about sweeping crap under the carpet... if you're getting
attributeerrors, find the source, don't just ignore them...
graphic = flashOverride(here,swftarget,graphic)
What does this do?
Looks to see if there's a flash file that can be used to replace the
graphic. In the current test version of the site, all the Flash files
have been removed whilst we've been tracking the leak, so in effect it's
Then take it out, see if the leak goes away... There's always Undo to
bring it back later...
Simplistix - Content Management, Zope & Python Consulting
For more information about ZODB, see the ZODB Wiki:
ZODB-Dev mailing list - ZODB-Dev@xxxxxxxx