These are chat archives for Nethereum/Nethereum

27th
Dec 2018
ameerkahiri
@ameerkahiri
Dec 27 2018 03:56
Hi.
Have anyone came across with this error?
"{"jsonrpc":"2.0","id":1,"error":{"code":-32602,"message":"invalid argument 0: json: cannot unmarshal non-string into Go struct field CallArgs.value of type *hexutil.Big"}}"
ameerkahiri
@ameerkahiri
Dec 27 2018 04:13
This is on Rinkeby testnet when I want to poll EthEstimateGas:
"{"jsonrpc":"2.0","id":1,"error":{"code":-32602,"message":"invalid argument 0: json: cannot unmarshal non-string into Go struct field CallArgs.value of type *hexutil.Big"}}"
ameerkahiri
@ameerkahiri
Dec 27 2018 04:48
It works fine on Kovan testnet.
fruor
@fruor
Dec 27 2018 11:16
Could it be that call arguments are missing in the function you are trying to estimate? I would assume Nethereum fails to guess some value, could you add some dummy values for everything (fromAddress, Gas etc.) and try again?
Oh wait, why CallArgs and not SendTxArgs? Are you calling the right function - as in something that even needs gas?
ameerkahiri
@ameerkahiri
Dec 27 2018 12:01

TransactionInput transactionInput = contractService.createInputFunction ("0x...(myaddress)", "0x...(myinput)", new HexBigInteger (5000000), new HexBigInteger (1000000000), new HexBigInteger (null));

var test = new EthEstimateGasUnityRequest ("https://rinkeby.infura.io/");
yield return test.SendRequest(transactionInput);

My code looks like that. I dont know why I get that error on Rinkeby and not on Kovan.
btw I'm using Unity3D
Enigmatic
@EnigmaticUnreal_twitter
Dec 27 2018 12:16
Hmmmmmmmmmm. I wonder - Would it be possible to try new HexBigInteger(0) instead for your last parameter?
I suspect - Maybe the Kovan (Parity) clients handled the case where the parameter hexvalue is null. Whereas the geth clients wouldn't like it.
ameerkahiri
@ameerkahiri
Dec 27 2018 12:22
hmmmmmmmmm... Maybe. I should give it a try.
ameerkahiri
@ameerkahiri
Dec 27 2018 12:30
@EnigmaticUnreal_twitter Whattt. You're right. Thank you!! Dang it "null" value.
Enigmatic
@EnigmaticUnreal_twitter
Dec 27 2018 12:31
Coooool! Good to know. =D