[spambayes-dev] A new and altogether different bsddb breakage
Tim Peters
tim.one at comcast.net
Thu Dec 25 17:10:23 EST 2003
[Kenny Pitt]
> ...
> I suspect some timing issue with the Windows disk cache not
> immediately flushing stuff to disk. That's just idle speculation, of
> course, but I have seen similar things in other development projects.
It's true that doing fileobject.flush() on Windows doesn't make any
guarantee about writing anything to disk. Python 2.3 grew an os.fsync
implementation for Windows, and os.fsync(fileobject.fileno()) does write to
disk on Windows (and sometimes takes a veeeeery long time to do so!). That
calls the MS C _commit() function under the covers, which in turn calls the
Win32 FlushFileBuffers().
> ...
> I can't think of a good reason that we should need to close and then
> immediately reopen the same database.
Me neither, but I bet we can find a way if we need to. In particular, you
pointed to Sleepycat docs before containing cautions about how things need
to be set up under Windows, and I'm almost certain the test suite doesn't do
that.
More information about the spambayes-dev
mailing list