-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Open
Description
A deadlock can happen if you use Threads.@spawn to create two or more tasks inside a @sync block and an error happens inside a task that is crucial for all tasks to complete. It seems that the error is suppressed and the error task never completes, which as expected causes the other task(s) to not complete. I would expect the error task to not suppress the error and instead fail.
Example to cause a deadlock:
@sync begin
c = Channel{Int}()
Threads.@spawn take!(c) # will block until an int is put! on the channel
Threads.@spawn put!(c, "wrong") # will block until a take! on the channel
endReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels