I use htmldoc to create pdf docs out of Zope. Basically I construct the html page I want to print, and use popen3() to write the html to the htmldoc program and fetch the pdf file and error file (if any). Most of the time it works fine. But occasionally the pdf is produced, no error message produced, and a Zombie process hanging around. There seems to be some correlation with the first print operation for a session creating a zombie. The python collector has several bugs related to the interaction of threads and popenN(), but it's unclear if they apply or how one might work around the problem? or even localize the problem? I suppose the simplest workaround would be to manage the pipes and htmldoc process myself rather than delegating it to popenN().