Distributed.jl icon indicating copy to clipboard operation
Distributed.jl copied to clipboard

propagate Ctrl-C on a `put!`, `take!`, etc to the remote process

Open amitmurthy opened this issue 10 years ago • 0 comments

julia> rr=RemoteRef(2)
RemoteRef(2,1,1)

julia> take!(rr)
^CERROR: InterruptException:
 in process_events at ./stream.jl:642
 in wait at ./task.jl:302
 in wait at ./task.jl:228
 in wait_full at ./multi.jl:631
 in remotecall_fetch at multi.jl:731
 in call_on_owner at ./multi.jl:778
 in take! at ./multi.jl:811

julia> put!(rr, 1)
RemoteRef(2,1,1)

julia> take!(rr)

The second take! does not get the data from the put! since Ctrl-C does not actually kill the spawned first take! task on the remote worker.

Interrupting the parallel API calls should interrupt the waiting tasks on the remote process too.

amitmurthy avatar Jul 30 '15 17:07 amitmurthy