From c1543b9c0e7ccb394f3bd83ea890cdb6af6f90eb Mon Sep 17 00:00:00 2001 From: BobTheBuidler <70677534+BobTheBuidler@users.noreply.github.com> Date: Sun, 22 Sep 2024 18:51:57 -0400 Subject: [PATCH] feat: add exc detail (#256) --- dank_mids/types.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dank_mids/types.py b/dank_mids/types.py index c9b91ad3..4f005572 100644 --- a/dank_mids/types.py +++ b/dank_mids/types.py @@ -349,7 +349,7 @@ def decode_result(self, method: Optional[RPCEndpoint] = None, _caller = None) -> if method in ["eth_call", "eth_blockNumber", "eth_getCode", "eth_getBlockByNumber", "eth_getTransactionReceipt", "eth_getTransactionCount", "eth_getBalance", "eth_chainId", "erigon_getHeaderByNumber"]: try: return msgspec.json.decode(self.result, type=typ) - except msgspec.ValidationError as e: + except (msgspec.ValidationError, TypeError) as e: raise ValueError( e, f'method: {method} result: {msgspec.json.decode(self.result)}',