multiprocessing.Queue & vim python interpreter
cs at zip.com.au
Sat Jan 24 04:59:30 CET 2015
On 18Jan2015 16:20, unknown3000 at gmail.com <unknown3000 at gmail.com> wrote:
>I am experimenting on a fork of vim-plug for managing vim plugins. I wanted to add parallel update support for python since ruby isn't nearly as common. I've come across a weird bug that only seems to happen when I'm inside vim, I'm wondering if someone could tell me why.
>This problem can be reproduced by sourcing a vim file with the following snippet. Then execute the command PyCrash.
>command! -nargs=0 PyCrash call s:py_crash()
> python << EOF
>import multiprocessing as multi
>queue = multi.Queue()
>This prints to messages the following:
>Traceback (most recent call last):
> File "/usr/lib/python2.7/multiprocessing/queues.py", line 266, in _feed
>IOError: [Errno 32] Broken pipe
Please include the entire traceback in errors.
I would guess this is because you have made a Queue but have not got subprocess
to read from it. So when you .put onto it, you get a broken pipe.
Cameron Simpson <cs at zip.com.au>
Nothing is impossible for the man who doesn't have to do it.
More information about the Python-list