ZODB leaves Tempfiles while testing

8 views
Skip to first unread message

Gerhard Schmidt

unread,
Nov 12, 2018, 3:45:05 AM11/12/18
to pylons-discuss
Hi,

i am writing a pyramid application that uses ZODB for persistence. I'm
doing some testing right now an run my testsuite quite often right now.

Today all of my tests suddenly failing. Investigating i found that my
/tmp was full with thousands of BUCxxxxxx files. I've deleted these
files and rerun my tests an there are again about 40 BUCxxxxxx files.

So investigating what generates these files and don't clean them up
afterward, i found that when creating a Blob Object and not committing
it to the ZODB the file is created and not deleted.

ZODB uses _p_blob_ref = weakref.ref(self, cleanup) to register a cleanup
function but it seams that this is never called in the testing env as
all other _p* attributes and methods do nothing while testing.

In the running system the cleanup seams to work. As there are no such
files in my test instance

Any hint how i can fix this.

Regards
Estartu

estartu.vcf
signature.asc
Reply all
Reply to author
Forward
0 new messages