os.spawnve and threads
Anthony Roach
aroach at electriceyeball.com
Tue Dec 4 21:00:35 EST 2001
Anthony Roach wrote:
[snip]
> The problem with
> os.spawnve() is that it seems to block the interpreter so no other threads
> can run, thus destroying our parallelism. I took a look at posixmodule.c
> (where spawnve is implemented for Windows) and the problem appears to be
> that Py_BEGIN_ALLOW_THREADS/Py_END_ALLOW_THREADS is not being used around
> the call to _spawnve().
>
> Is this a known bug? Any chance of getting it fixed for Python 2.2? Should
I
> submit a patch?
This bug IS present in the current CVS version of Python, and doesn't appear
to be a known bug (well, you and I know about it, but no one else seems to).
I went ahead and submitted a patch that fixes it like you suggested. I even
fixed the the doc strings! To top it all off I ran the scons option-j.py
test, and it now passes.
I'm not a registered Python developer, so it's anyone's guess whether or not
this fix will make it into Python 2.2. Cross your fingers...
-Anthony
More information about the Python-list
mailing list