From c657134018761272434d244bfaf67de869d30418 Mon Sep 17 00:00:00 2001 From: Mark Spanbroek Date: Thu, 2 Dec 2021 14:38:43 +0100 Subject: [PATCH] Fix encoding of gas price in transaction Hardhat network doesn't support gas price that is not a QUANTITY. --- web3/conversions.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web3/conversions.nim b/web3/conversions.nim index ea7d78e..2e5a9d5 100644 --- a/web3/conversions.nim +++ b/web3/conversions.nim @@ -128,7 +128,7 @@ proc `%`*(x: EthSend): JsonNode = if x.gas.isSome: result["gas"] = %x.gas.unsafeGet if x.gasPrice.isSome: - result["gasPrice"] = %x.gasPrice.unsafeGet + result["gasPrice"] = %Quantity(x.gasPrice.unsafeGet) if x.value.isSome: result["value"] = %x.value.unsafeGet if x.data.len > 0: