How to know if a module is thread-safe

Michael Torrie torriem at gmail.com
Thu Apr 17 13:00:35 EDT 2008


Jérémy Wagner wrote:
> Hi, I recently tried to use the subprocess module
> within a threading.Thread class, but it appears the module
> is not thread-safe.

http://bugs.python.org/issue1731717

Pretty bad bug, really, since subprocess is supposed to be the
replacement for all the other mechanisms like popen2 and os.popen*

> 
> What is the policy of python regarding thread-safety of a module ?

I personally don't know. But any module that's not thread safe would be
a bug in my mind.



More information about the Python-list mailing list