[Zope] memory leak in a very simple product. Way?

Thomas B. Passin tpassin@mitretek.org
Wed, 16 Jan 2002 10:40:48 -0500


[Christoph Wierling]

[me]
> > I think you really want to do this:
> >
> >          tree = []
> >          for i in xrange(200):
> >              n = item(str(i),i)
> >              tree.append(n)
> >          self._tree = tree
> >
>
> Thanks for the suggestion. Your code does about the same as my did -
> it also reproduces the 20000 references to objects of the item-class.
> And I also don't get rid of the 20000 references. I tried it!  :-(
>

I was about to ask if your item() objects are persistent, when I read Chris
McDonough's post.  If you are storing al 20,000 items, no wonder you see
memory uasge increasing.

Cheers,

Tom P