bump `nim-web3` to `747001250a27278e0f0f1706fe1dec88ad3ede8d` (#6020)

- Remove error field from AccessListResult
- Add optional yParity field to TransactionObject
This commit is contained in:
Etan Kissling 2024-03-03 17:17:06 +01:00 committed by GitHub
parent 649f0165b8
commit bb8c6cda18
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 4 deletions

View File

@ -1459,12 +1459,12 @@ proc ETHTransactionsCreateFromJson(
return nil
# Check fork consistency
static: doAssert totalSerializedFields(TransactionObject) == 21,
static: doAssert totalSerializedFields(TransactionObject) == 22,
"Only update this number once code is adjusted to check new fields!"
let txType =
case data.`type`.get(0.Quantity):
of 0.Quantity:
if data.accessList.isSome or
if data.yParity.isSome or data.accessList.isSome or
data.maxFeePerGas.isSome or data.maxPriorityFeePerGas.isSome or
data.maxFeePerBlobGas.isSome or data.blobVersionedHashes.isSome:
return nil
@ -1512,8 +1512,15 @@ proc ETHTransactionsCreateFromJson(
return nil
if distinctBase(data.gas) > int64.high.uint64:
return nil
if data.v.uint64 > int64.high.uint64:
if distinctBase(data.v) > int64.high.uint64:
return nil
if data.yParity.isSome:
# This is not always included, but if it is, make sure it's correct
let yParity = data.yParity.get
if distinctBase(yParity) > 1:
return nil
if yParity != data.v:
return nil
let
tx = ExecutionTransaction(
txType: txType,

2
vendor/nim-web3 vendored

@ -1 +1 @@
Subproject commit 15325bd844a38234e4f705b3399d0bbfa3b63a12
Subproject commit 747001250a27278e0f0f1706fe1dec88ad3ede8d