see this post
...
if istaskdone(tsk1)
sol = fetch(tsk1)
else
schedule(tsk1, ErrorException("stop"), error=true)
sol = nothing
end
will make your example work, but personally I would avoid such a hack
see this post
...
if istaskdone(tsk1)
sol = fetch(tsk1)
else
schedule(tsk1, ErrorException("stop"), error=true)
sol = nothing
end
will make your example work, but personally I would avoid such a hack