On Tue, Oct 21, 2008 at 06:30:27AM -0700, Istvan Albert wrote: -> -> On Oct 21, 9:05?am, "C. Titus Brown" <[EMAIL PROTECTED]> wrote: -> > -> > It's a BsdDBShelf problem, not a bsddb issue -- see attached script. -> > The 'iter' call seems to be what's loading the index. -> -> oy, indeed. I think I know what is going on, -> -> the BsdDBShelf class does not have a __iter__method, and it inherits -> from the Shelf -> UserDict.DictMixin. And it looks like that class -> unwinds the keys into a list when creating the iterator. -> -> I noticed how iterating on the database itself is still very fast. So -> I think there might be an easy fix here, replacing the iter(db) call -> with iterating on the database directly.
Yes, that's the solution I came up with in my own scripts; I just never tracked down the problem! Hmm, this might be worth a note to Python-dev... Istvan, do you want to put together a patch, or shall I stack it on top of my own workload? :) --titus -- C. Titus Brown, [EMAIL PROTECTED] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pygr-dev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/pygr-dev?hl=en -~----------~----~----~----~------~----~------~--~---
