Closed knocte closed 2 weeks ago
I've digged a little bit in our Nethereum fork (https://github.com/nblockchain/Nethereum) and so far I think I found that the culprit is actually in JsonRpcSharp, in particular here:
Seems that in order to understand the problem better, we would need to first change returnDefaultIfNull param to default to false, and test again to see if we get the exception "Unable to convert the result (null) to type ...". If that is the case, then it means that somehow response.Result
property was null, and so the next step is to figure out why.
Indeed response.Result
is null
in our case, although returnDefaultIfNull
does nothing in this case since default of Nethereum.Hex.HexTypes.HexBigInteger
is null also.
Enabling debug output showed that response json was:
{"jsonrpc":"2.0","id":1,"result":null}
In other responses, result
field contains string with number in hex notation.
So I think this should be handled on geewallet side. But I don't know which exception type to use here to signal invalid response from serever.
CI of today started failing with:
https://github.com/nblockchain/geewallet/actions/runs/9815030138
Quoting error:
When running geewallet locally, I got the same problem but with slightly different stacktrace:
Both problems seem to be caused by a
null
value being returned fromweb3.Eth.GetBalance.SendRequestAsync()
method.