[Zope-dev] misterious btree issue

Jacob Holm jh at improva.dk
Thu Nov 6 08:14:30 EST 2008


Hi Adam

Adam GROSZER wrote:
> Hello,
>
> I've run into a misterious issue while evolving generations from an
> old DB.
>
> Quick fact is that it seems like a BTree kept an object reference to
> an object which was deleted from it. 
[snip]

Yes, the BTree implementations we use may keep a reference to a deleted 
key. I think I have seen this documented somewhere but don't have the 
time to look it up now. It saves some bookkeeping to do it that way, and 
I think it also reduces the risk of conflict errors.

> What helped was to recreate both IntId BTrees from scratch, like at
> #recreate intid trees. That and packing made the utility finally go
> away.
>
> Anybody noticed something like this
Yes, I ran into this a few weeks ago when I needed to delete the code 
for an obsolete content type. IIRC you only really need to recreate the 
mapping from keyreferences to intids (the ids attribute of the default 
IIntIds utility).


Hope this helps

- Jacob


More information about the Zope-Dev mailing list