Skip to content

Commit 2515c36

Browse files
committed
cancellation: Wrap InterruptException in DTaskFailedException
1 parent 6da10fa commit 2515c36

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cancellation.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ function _cancel!(state, tid, force, graceful, halt_sch)
9898
for task in state.ready
9999
tid !== nothing && task.id != tid && continue
100100
@dagdebug tid :cancel "Cancelling ready task"
101-
state.cache[task] = InterruptException()
101+
state.cache[task] = DTaskFailedException(task, task, InterruptException())
102102
state.errored[task] = true
103103
Sch.set_failed!(state, task)
104104
end
@@ -108,7 +108,7 @@ function _cancel!(state, tid, force, graceful, halt_sch)
108108
for task in keys(state.waiting)
109109
tid !== nothing && task.id != tid && continue
110110
@dagdebug tid :cancel "Cancelling waiting task"
111-
state.cache[task] = InterruptException()
111+
state.cache[task] = DTaskFailedException(task, task, InterruptException())
112112
state.errored[task] = true
113113
Sch.set_failed!(state, task)
114114
end

0 commit comments

Comments
 (0)