The src error to `_raise_from_no_key_in_msg()` is always an attr-error now!

runtime_to_msgspec
Tyler Goodlet 2024-04-17 23:19:31 -04:00
parent a73b24cf4a
commit d0e7610073
1 changed files with 2 additions and 2 deletions

View File

@ -935,7 +935,7 @@ def is_multi_cancelled(exc: BaseException) -> bool:
def _raise_from_no_key_in_msg( def _raise_from_no_key_in_msg(
ctx: Context, ctx: Context,
msg: MsgType, msg: MsgType,
src_err: KeyError, src_err: AttributeError,
log: StackLevelAdapter, # caller specific `log` obj log: StackLevelAdapter, # caller specific `log` obj
expect_msg: str = Yield, expect_msg: str = Yield,
@ -994,7 +994,7 @@ def _raise_from_no_key_in_msg(
ctx.chan, ctx.chan,
hide_tb=hide_tb, hide_tb=hide_tb,
) from None ) from src_err
# `MsgStream` termination msg. # `MsgStream` termination msg.
# TODO: does it make more sense to pack # TODO: does it make more sense to pack