Skip to content

Commit

Permalink
fix : TestWelcome genesis bug
Browse files Browse the repository at this point in the history
  • Loading branch information
0xsharma committed Jan 11, 2024
1 parent c0bf289 commit c816d0f
Show file tree
Hide file tree
Showing 14 changed files with 28 additions and 37 deletions.
4 changes: 2 additions & 2 deletions core/genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -492,11 +492,11 @@ func (g *Genesis) ToBlock() *types.Block {
if conf := g.Config; conf != nil {
num := big.NewInt(int64(g.Number))
if conf.IsShanghai(num) {
head.WithdrawalsHash = &types.EmptyWithdrawalsHash
head.WithdrawalsHash = nil
withdrawals = nil
}
if conf.IsCancun(num) {
head.ParentBeaconRoot = new(common.Hash)
head.ParentBeaconRoot = nil
head.ExcessBlobGas = nil
head.BlobGasUsed = nil
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
{
"blobGasPrice": null,
"blobGasUsed": "0x20000",
"blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a",
"blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b",
"blockNumber": "0x6",
"contractAddress": null,
"cumulativeGasUsed": "0x5208",
"effectiveGasPrice": "0x1b09d63b",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x5208",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x1",
"to": "0x0d3ab14bbad3d99f4203bd7a11acb94882050e7e",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[
{
"blockHash": "0x9a39dcd6e4cd5ac58ec2f77057d8570cb349202b1ce103a14d7730cb2916467d",
"blockHash": "0xc594f1b119b071d288cd11371da2de73d67986a717974a85cac4ce634eba3015",
"blockNumber": "0x2",
"contractAddress": "0xae9bea628c4ce503dcfd7e305cab4e29e7476592",
"cumulativeGasUsed": "0xcf50",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[
{
"blockHash": "0x6ebc52b22ea8ab32139653a8733bc4506e1fa86f946a72f770c4d2f68dab73d6",
"blockHash": "0x15158c4fb0661a38967dbf81b1592c54999b44a4580153b3469b29724903fc95",
"blockNumber": "0x4",
"contractAddress": null,
"cumulativeGasUsed": "0x538d",
"effectiveGasPrice": "0x2325c42f",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x538d",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x6ebc52b22ea8ab32139653a8733bc4506e1fa86f946a72f770c4d2f68dab73d6", "blockNumber": "0x4", "data": "0x0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de0723c13bc370000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000de0723c1319079c0000000000000000000000000000000000000000000000000000000000a32f64", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xdcde2574628c9d7dff22b9afa19f235959a924ceec65a9df903a517ae91f5c84", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x15158c4fb0661a38967dbf81b1592c54999b44a4580153b3469b29724903fc95", "blockNumber": "0x4", "data": "0x0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de0723c13bc370000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000de0723c1319079c0000000000000000000000000000000000000000000000000000000000a32f64", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xdcde2574628c9d7dff22b9afa19f235959a924ceec65a9df903a517ae91f5c84", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x0",
"to": "0x0000000000000000000000000000000000031ec7",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[
{
"blockHash": "0x54849dd50b9454cedb15a5ea0bea568d7e97b35ae44bcd9b619ca114d1ac51e5",
"blockHash": "0x12db9de067ca71d47e360ab4eb9bf7bc80824f5edd39c7576e253f37a1a22782",
"blockNumber": "0x3",
"contractAddress": null,
"cumulativeGasUsed": "0x5e28",
Expand All @@ -19,7 +19,7 @@
"blockNumber": "0x3",
"transactionHash": "0xeaf3921cbf03ba45bad4e6ab807b196ce3b2a0b5bacc355b6272fa96b11b4287",
"transactionIndex": "0x0",
"blockHash": "0x54849dd50b9454cedb15a5ea0bea568d7e97b35ae44bcd9b619ca114d1ac51e5",
"blockHash": "0x12db9de067ca71d47e360ab4eb9bf7bc80824f5edd39c7576e253f37a1a22782",
"logIndex": "0x0",
"removed": false
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[
{
"blockHash": "0xbb36e7fadfa2fc391701247b182e7b9451c6ef3cf17c5b72930bcb0fa11ea0d0",
"blockHash": "0xfddc403b2acdace77774a35cbad7b68d50ce258fafaac399e21533a3b77ad94a",
"blockNumber": "0x1",
"contractAddress": null,
"cumulativeGasUsed": "0x5208",
"effectiveGasPrice": "0x342770c0",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x5208",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0xbb36e7fadfa2fc391701247b182e7b9451c6ef3cf17c5b72930bcb0fa11ea0d0", "blockNumber": "0x1", "data": "0x00000000000000000000000000000000000000000000000000000000000003e80000000000000000000000000000000000000000000000000de0a5fd640afa000000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0a5fd640af6180000000000000000000000000000000000000000000000000de0b6b3a76403e8", "logIndex": "0x0", "removed": false, "topics": ["0xe6497e3ee548a3372136af2fcb0696db31fc6cf20260707645068bd3fe97f3c4", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000d3ab14bbad3d99f4203bd7a11acb94882050e7e"], "transactionHash": "0x644a31c354391520d00e95b9affbbb010fc79ac268144ab8e28207f4cf51097e", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0xfddc403b2acdace77774a35cbad7b68d50ce258fafaac399e21533a3b77ad94a", "blockNumber": "0x1", "data": "0x00000000000000000000000000000000000000000000000000000000000003e80000000000000000000000000000000000000000000000000de0a5fd640afa000000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0a5fd640af6180000000000000000000000000000000000000000000000000de0b6b3a76403e8", "logIndex": "0x0", "removed": false, "topics": ["0xe6497e3ee548a3372136af2fcb0696db31fc6cf20260707645068bd3fe97f3c4", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000d3ab14bbad3d99f4203bd7a11acb94882050e7e"], "transactionHash": "0x644a31c354391520d00e95b9affbbb010fc79ac268144ab8e28207f4cf51097e", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x1",
"to": "0x0d3ab14bbad3d99f4203bd7a11acb94882050e7e",
Expand Down
4 changes: 2 additions & 2 deletions internal/ethapi/testdata/eth_getBlockReceipts-tag-latest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
{
"blobGasPrice": null,
"blobGasUsed": "0x20000",
"blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a",
"blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b",
"blockNumber": "0x6",
"contractAddress": null,
"cumulativeGasUsed": "0x5208",
"effectiveGasPrice": "0x1b09d63b",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x5208",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x1",
"to": "0x0d3ab14bbad3d99f4203bd7a11acb94882050e7e",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"blobGasPrice": null,
"blobGasUsed": "0x20000",
"blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a",
"blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b",
"blockNumber": "0x6",
"contractAddress": null,
"cumulativeGasUsed": "0x5208",
"effectiveGasPrice": "0x1b09d63b",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x5208",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0xec0ed7963ba5ad220a637efaf671622e985e62c967febe2beb694bd12f64592a", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x4446b1498499cab37cfec330097fadf285c703444d431756940528d32fe0e97b", "blockNumber": "0x6", "data": "0x00000000000000000000000000000000000000000000000000000000000052080000000000000000000000000000000000000000000000000de04bce435b746d0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de04bce435b22650000000000000000000000000000000000000000000000000000000000a3816c", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xb51ee3d2a89ba5d5623c73133c8d7a6ba9fb41194c17f4302c21b30994a1180f", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x1",
"to": "0x0d3ab14bbad3d99f4203bd7a11acb94882050e7e",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"blockHash": "0x9a39dcd6e4cd5ac58ec2f77057d8570cb349202b1ce103a14d7730cb2916467d",
"blockHash": "0xc594f1b119b071d288cd11371da2de73d67986a717974a85cac4ce634eba3015",
"blockNumber": "0x2",
"contractAddress": "0xae9bea628c4ce503dcfd7e305cab4e29e7476592",
"cumulativeGasUsed": "0xcf50",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"blockHash": "0xfb278012fb863c9256925b2e62d260fdf06a4ffc11f564c42fde70b903a28592",
"blockHash": "0x4d780246cde52e535f40603d47af8fa1aea807dd3065e1acd97127bea0922b3e",
"blockNumber": "0x5",
"contractAddress": "0xfdaa97661a584d977b4d3abb5370766ff5b86a18",
"cumulativeGasUsed": "0xe01c",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"blockHash": "0x6ebc52b22ea8ab32139653a8733bc4506e1fa86f946a72f770c4d2f68dab73d6",
"blockHash": "0x15158c4fb0661a38967dbf81b1592c54999b44a4580153b3469b29724903fc95",
"blockNumber": "0x4",
"contractAddress": null,
"cumulativeGasUsed": "0x538d",
"effectiveGasPrice": "0x2325c42f",
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
"gasUsed": "0x538d",
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x6ebc52b22ea8ab32139653a8733bc4506e1fa86f946a72f770c4d2f68dab73d6", "blockNumber": "0x4", "data": "0x0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de0723c13bc370000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000de0723c1319079c0000000000000000000000000000000000000000000000000000000000a32f64", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xdcde2574628c9d7dff22b9afa19f235959a924ceec65a9df903a517ae91f5c84", "transactionIndex": "0x0"}],
"logs": [{"address": "0x0000000000000000000000000000000000001010", "blockHash": "0x15158c4fb0661a38967dbf81b1592c54999b44a4580153b3469b29724903fc95", "blockNumber": "0x4", "data": "0x0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de0723c13bc370000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000de0723c1319079c0000000000000000000000000000000000000000000000000000000000a32f64", "logIndex": "0x0", "removed": false, "topics": ["0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63", "0x0000000000000000000000000000000000000000000000000000000000001010", "0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7", "0x0000000000000000000000000000000000000000000000000000000000000000"], "transactionHash": "0xdcde2574628c9d7dff22b9afa19f235959a924ceec65a9df903a517ae91f5c84", "transactionIndex": "0x0"}],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
"status": "0x0",
"to": "0x0000000000000000000000000000000000031ec7",
Expand Down
Loading

0 comments on commit c816d0f

Please sign in to comment.