[Zope-dev] ERROR(200) ZODB Couldn't load state for... Memory problem?

Tim Peters tim.peters at gmail.com
Fri Jul 23 16:21:19 EDT 2004


[Chris McDonough]
> ...
>          self._f[current] = open(self._p[current],'w+b')
> 
> .... will be likely to fail at the last line if you're using
> nonpersistent cache files, because self._p[current] is (bogus)
> '1-None-0' (relative bogus filename).

Is it really *likely* to fail?  It's just a name, and it's opened in
'w' ('+b') mode, not 'r' mode.  That is, it creates the file -- no
file of that name need already exist (and if one does, it tries to
overrwrite it).  Running on Windows most days, I'm not usually aware
of all the permission bugs Linuxheads delight in torturing themselves
with <wink>.

> There should probably be a _using_persistent_cache flag attr rather than
> trying to inspect self._p to find out if we're using persistent caches.

+1.  As you later discovered, this "hmm, let's try to guess what we're
doing based on obscure droppings" business is a continuing bug
factory.

> I may try to work up a patch + test for this later.

I'm neutral on whether you try, but +1 on you actually doing it <wink>.


More information about the Zope-Dev mailing list