[issue3551] multiprocessing.Pipe terminates with ERROR_NO_SYSTEM_RESOURCES if large data is sent (win2000)
report at bugs.python.org
Tue Mar 31 20:53:59 CEST 2009
John Ehresman <jpe at wingware.com> added the comment:
Attached is a patch, though I have mixed feelings about it. The OS
error can still occur even if a smaller amount is written in each
WriteFile call; I think an internal OS buffer fills up and the error is
returned if that buffer is full because the other process hasn't read
yet. The patch just ignores ERROR_NO_SYSTEM_RESOURCES and writes again.
I don't know though if ERROR_NO_SYSTEM_RESOURCES can mean something
else is wrong and the write will never succeed. The message is also
broken up into 32K parts and a recv_bytes on the other end must be
called multiple times to read it all.
The patch is one option. Another might be to let the application decide
to continue or not and essentially treat the pipes as nonblocking.
Added file: http://bugs.python.org/file13518/win32_pipe.diff
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list