forked from goodboy/tractor
Log the exception when unable to ship back rpc errors
parent
7a2b7d9d14
commit
0a240187c6
|
@ -125,8 +125,11 @@ async def _invoke(
|
||||||
log.exception("Actor errored:")
|
log.exception("Actor errored:")
|
||||||
err_msg = pack_error(err)
|
err_msg = pack_error(err)
|
||||||
err_msg['cid'] = cid
|
err_msg['cid'] = cid
|
||||||
|
try:
|
||||||
await chan.send(err_msg)
|
await chan.send(err_msg)
|
||||||
|
except trio.ClosedResourceError:
|
||||||
|
log.exception(
|
||||||
|
f"Failed to ship error to caller @ {chan.uid}")
|
||||||
if cs is None:
|
if cs is None:
|
||||||
# error is from above code not from rpc invocation
|
# error is from above code not from rpc invocation
|
||||||
task_status.started(err)
|
task_status.started(err)
|
||||||
|
|
Loading…
Reference in New Issue