From 192d978feb564738823a6a494db530088254de7c Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Wed, 13 Mar 2024 12:25:12 +0100 Subject: [PATCH 1/5] Upgrade geth in the sim tests --- packages/cli/test/scripts/e2e_test_env.ts | 2 +- packages/cli/test/sim/multi_fork.test.ts | 6 +++--- .../cli/test/utils/simulation/execution_clients/geth.ts | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/cli/test/scripts/e2e_test_env.ts b/packages/cli/test/scripts/e2e_test_env.ts index b5fa48260194..9884a5a83374 100644 --- a/packages/cli/test/scripts/e2e_test_env.ts +++ b/packages/cli/test/scripts/e2e_test_env.ts @@ -25,7 +25,7 @@ const env = await SimulationEnvironment.initWithDefaults( }, [ {id: "node-1", beacon: BeaconClient.Lodestar, execution: ExecutionClient.Geth, keysCount: 32, mining: true}, - {id: "node-2", beacon: BeaconClient.Lodestar, execution: ExecutionClient.Nethermind, keysCount: 32}, + {id: "node-2", beacon: BeaconClient.Lodestar, execution: ExecutionClient.Geth, keysCount: 32}, ] ); diff --git a/packages/cli/test/sim/multi_fork.test.ts b/packages/cli/test/sim/multi_fork.test.ts index d816e0ddae54..f57d3a397955 100644 --- a/packages/cli/test/sim/multi_fork.test.ts +++ b/packages/cli/test/sim/multi_fork.test.ts @@ -76,7 +76,7 @@ const env = await SimulationEnvironment.initWithDefaults( }, }, }, - execution: ExecutionClient.Nethermind, + execution: ExecutionClient.Geth, keysCount: 32, remote: true, }, @@ -93,7 +93,7 @@ const env = await SimulationEnvironment.initWithDefaults( }, }, }, - execution: ExecutionClient.Nethermind, + execution: ExecutionClient.Geth, keysCount: 32, }, { @@ -110,7 +110,7 @@ const env = await SimulationEnvironment.initWithDefaults( }, }, }, - execution: ExecutionClient.Nethermind, + execution: ExecutionClient.Geth, keysCount: 32, }, {id: "node-5", beacon: BeaconClient.Lighthouse, execution: ExecutionClient.Geth, keysCount: 32}, diff --git a/packages/cli/test/utils/simulation/execution_clients/geth.ts b/packages/cli/test/utils/simulation/execution_clients/geth.ts index 4c1b8196ab17..18e73ddba195 100644 --- a/packages/cli/test/utils/simulation/execution_clients/geth.ts +++ b/packages/cli/test/utils/simulation/execution_clients/geth.ts @@ -130,6 +130,7 @@ export const generateGethNode: ExecutionNodeGenerator = (o `extip:${address}`, "--authrpc.jwtsecret", jwtsecretFilePathMounted, + "--nodiscover", "--datadir", rootDirMounted, "--allow-insecure-unlock", From 4b3183f10f550427cc6abce1f330069cf30b191f Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Wed, 13 Mar 2024 12:27:42 +0100 Subject: [PATCH 2/5] Update env file --- .env.test | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.env.test b/.env.test index 31222f7549cb..0f20746793b7 100644 --- a/.env.test +++ b/.env.test @@ -1,13 +1,16 @@ # We use these images during sim and e2e tests -# TODO: Upgrade Geth once the Nethermind issue is resolved else it's causing following error -# Rejected peer id=134e2c1a76745626 addr=192.168.0.3:9052 conn=staticdial err="useless peer" -GETH_DOCKER_IMAGE=ethereum/client-go:v1.11.6 +# This is the last verion which supports pre/post merge chains in the same network +# All newer versions only work with post merge chains +GETH_DOCKER_IMAGE=ethereum/client-go:v1.13.14 # Use either image or local binary for the testing GETH_BINARY_DIR= LIGHTHOUSE_DOCKER_IMAGE=sigp/lighthouse:v4.6.0-amd64-modern-dev + # We can't upgrade nethermind further due to genesis hash mismatch with the geth # https://github.com/NethermindEth/nethermind/issues/6683 -NETHERMIND_DOCKER_IMAGE=nethermind/nethermind:1.18.2 +# Disabling Nethermind from sim tests untill the above issue is resolved +# NETHERMIND_DOCKER_IMAGE=nethermind/nethermind:1.18.2 + # We mostly use mainnet for unit testing # Changing this value may impact the tests which are written with mainnet in mind LODESTAR_PRESET=mainnet From 4081f91b6a0579ce3bddd9c4142dce188f8bc0db Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Wed, 13 Mar 2024 12:42:49 +0100 Subject: [PATCH 3/5] Apply suggestions from code review Co-authored-by: Julien --- .env.test | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.env.test b/.env.test index 0f20746793b7..b939e25af65f 100644 --- a/.env.test +++ b/.env.test @@ -1,5 +1,5 @@ # We use these images during sim and e2e tests -# This is the last verion which supports pre/post merge chains in the same network +# This is the last version which supports pre/post merge chains in the same network # All newer versions only work with post merge chains GETH_DOCKER_IMAGE=ethereum/client-go:v1.13.14 # Use either image or local binary for the testing @@ -8,7 +8,7 @@ LIGHTHOUSE_DOCKER_IMAGE=sigp/lighthouse:v4.6.0-amd64-modern-dev # We can't upgrade nethermind further due to genesis hash mismatch with the geth # https://github.com/NethermindEth/nethermind/issues/6683 -# Disabling Nethermind from sim tests untill the above issue is resolved +# Disabling Nethermind from sim tests until the above issue is resolved # NETHERMIND_DOCKER_IMAGE=nethermind/nethermind:1.18.2 # We mostly use mainnet for unit testing From 1899f8693c4e65be2f3e07d00d04b468a116b697 Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Wed, 13 Mar 2024 12:56:00 +0100 Subject: [PATCH 4/5] Remove nethermind image from download --- .github/workflows/test-sim.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/test-sim.yml b/.github/workflows/test-sim.yml index 6895c74c016e..4b3f0f2b38a8 100644 --- a/.github/workflows/test-sim.yml +++ b/.github/workflows/test-sim.yml @@ -165,7 +165,6 @@ jobs: run: | docker pull ${{env.GETH_DOCKER_IMAGE}} docker pull ${{env.LIGHTHOUSE_DOCKER_IMAGE}} - docker pull ${{env.NETHERMIND_DOCKER_IMAGE}} - name: Sim tests mixed client run: DEBUG='${{github.event.inputs.debug}}' yarn test:sim:mixedclient working-directory: packages/cli From 7cf700379c903b3c53adcd7125f2ad41e51f0ea4 Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Wed, 13 Mar 2024 12:57:11 +0100 Subject: [PATCH 5/5] Set a version for nethermind to avoid changes in CI --- .env.test | 2 +- .github/workflows/test-sim.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.env.test b/.env.test index b939e25af65f..6dd87a441199 100644 --- a/.env.test +++ b/.env.test @@ -9,7 +9,7 @@ LIGHTHOUSE_DOCKER_IMAGE=sigp/lighthouse:v4.6.0-amd64-modern-dev # We can't upgrade nethermind further due to genesis hash mismatch with the geth # https://github.com/NethermindEth/nethermind/issues/6683 # Disabling Nethermind from sim tests until the above issue is resolved -# NETHERMIND_DOCKER_IMAGE=nethermind/nethermind:1.18.2 +NETHERMIND_DOCKER_IMAGE=nethermind/nethermind:1.18.2 # We mostly use mainnet for unit testing # Changing this value may impact the tests which are written with mainnet in mind diff --git a/.github/workflows/test-sim.yml b/.github/workflows/test-sim.yml index 4b3f0f2b38a8..0a00777bfeca 100644 --- a/.github/workflows/test-sim.yml +++ b/.github/workflows/test-sim.yml @@ -165,6 +165,7 @@ jobs: run: | docker pull ${{env.GETH_DOCKER_IMAGE}} docker pull ${{env.LIGHTHOUSE_DOCKER_IMAGE}} + # docker pull ${{env.NETHERMIND_DOCKER_IMAGE}} - name: Sim tests mixed client run: DEBUG='${{github.event.inputs.debug}}' yarn test:sim:mixedclient working-directory: packages/cli