Commit 86fa8efc authored by Barnabas Busa's avatar Barnabas Busa Committed by GitHub

fix: path based storage disable for elecra (#316)

parent 6e8e290a
......@@ -282,6 +282,12 @@ jobs:
- <<: *setup_kurtosis
- checkout
- run: kurtosis run ${PWD} "$(cat ./.circleci/tests/disable-peer-scoring.json)"
petra:
executor: ubuntu_vm
steps:
- <<: *setup_kurtosis
- checkout
- run: kurtosis run ${PWD} "$(cat ./.circleci/tests/petra.json)"
workflows:
check_latest_version:
......@@ -389,3 +395,9 @@ workflows:
branches:
ignore:
- main
- petra:
filters:
branches:
ignore:
- main
{
"participants": [
{
"el_client_type": "geth",
"el_client_image": "ethpandaops/geth:gballet-kaustinen-with-shapella-a45a9f2",
"cl_client_type": "lodestar",
"cl_client_image": "ethpandaops/lodestar:g11tech-verge",
"count": 2
}
],
"network_params": {
"electra_fork_epoch": 0,
"deneb_fork_epoch": 1000
},
"additional_services": []
}
......@@ -107,6 +107,7 @@ def launch(
extra_params,
extra_env_vars,
launcher.electra_fork_epoch,
launcher.final_genesis_timestamp,
)
service = plan.add_service(service_name, config)
......@@ -146,16 +147,30 @@ def get_config(
extra_params,
extra_env_vars,
electra_fork_epoch,
final_genesis_timestamp,
):
init_datadir_cmd_str = "geth init {0} --state.scheme=path --datadir={1} {2}".format(
"--cache.preimages" if electra_fork_epoch != None else "",
EXECUTION_DATA_DIRPATH_ON_CLIENT_CONTAINER,
constants.GENESIS_CONFIG_MOUNT_PATH_ON_CONTAINER + "/genesis.json",
)
# TODO: Remove this once electra fork has path based storage scheme implemented
if electra_fork_epoch != None:
init_datadir_cmd_str = "geth init --cache.preimages --datadir={0} {1}".format(
EXECUTION_DATA_DIRPATH_ON_CLIENT_CONTAINER,
constants.GENESIS_CONFIG_MOUNT_PATH_ON_CONTAINER + "/genesis.json",
)
else:
init_datadir_cmd_str = "geth init --state.scheme=path --datadir={0} {1}".format(
EXECUTION_DATA_DIRPATH_ON_CLIENT_CONTAINER,
constants.GENESIS_CONFIG_MOUNT_PATH_ON_CONTAINER + "/genesis.json",
)
cmd = [
"geth",
"--state.scheme=path",
# Disable path based storage scheme for electra fork
"{0}".format("--state.scheme=path" if electra_fork_epoch == None else ""),
# Override prague fork timestamp for electra fork
"{0}".format(
"--override.prague=" + final_genesis_timestamp
if electra_fork_epoch != None
else ""
),
"--verbosity=" + verbosity_level,
"--datadir=" + EXECUTION_DATA_DIRPATH_ON_CLIENT_CONTAINER,
"--networkid=" + network_id,
......@@ -232,10 +247,12 @@ def get_config(
def new_geth_launcher(
network_id,
el_cl_genesis_data,
final_genesis_timestamp,
electra_fork_epoch=None,
):
return struct(
network_id=network_id,
el_cl_genesis_data=el_cl_genesis_data,
final_genesis_timestamp=final_genesis_timestamp,
electra_fork_epoch=electra_fork_epoch,
)
......@@ -309,6 +309,9 @@ def parse_network_params(input_args):
if result["network_params"]["electra_fork_epoch"] != None:
# if electra is defined, then deneb needs to be set very high
result["network_params"]["deneb_fork_epoch"] = HIGH_DENEB_VALUE_FORK_VERKLE
# TODO: remove once transition is complete
if result["network_params"]["electra_fork_epoch"] != 0:
fail("electra_fork_epoch can only be 0 or None")
if (
result["network_params"]["capella_fork_epoch"] > 0
......
......@@ -98,7 +98,7 @@ def launch_participant_network(
# we are running electra - experimental
elif network_params.electra_fork_epoch != None:
ethereum_genesis_generator_image = (
"ethpandaops/ethereum-genesis-generator:3.0.0-rc.10"
"ethpandaops/ethereum-genesis-generator:3.0.0-rc.14"
)
else:
fail(
......@@ -132,6 +132,7 @@ def launch_participant_network(
"launcher": geth.new_geth_launcher(
network_params.network_id,
el_cl_data,
final_genesis_timestamp,
network_params.electra_fork_epoch,
),
"launch_method": geth.launch,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment