Well.. it turned out to be more subtle.
It goes back to the old problem that getPersistentItemIDs doesn't return
a real list, but rather a BTreeItems object. When you call manage_delete
on *one* item, it affects the BTreesItems object you are iterating over!
## Script (Python) "deleteAllTracks"
for id in trackMaster.defaultRack.getPersistentItemIDs():
for id in iList:
return ("OK! deleted %i elements" % len(iList)) + string.join(iList,',')
On Wednesday, May 23, 2001, at 10:59 AM, Steve Alexander wrote:
> Steve Spicklemire wrote:
>> Has anyone seen anything like this?
>> It works.. partially. For some reason it looks like
>> getPersistentItemIDs does not always return a *complete* list. I need
>> to run this method several times to completely exhaust the Rack's
> Yes, I've seen this. It's on my list of things to look into when I've
> got a certain large project out of the way :-/
> Well, getPersistentItemIDs() just returns the result of calling keys()
> on the Rack's BTree.
> I guess it is a problem with the BTree code.
> I doubt it'll be fixed though. Instead, we should update Rack to use
> the new BTrees module.
> Steve Alexander
> Software Engineer
> Cat-Box limited
> Zope-Dev maillist - [EMAIL PROTECTED]
> ** No cross posts or HTML encoding! **
> (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope )
Zope-Dev maillist - [EMAIL PROTECTED]
** No cross posts or HTML encoding! **
(Related lists -