Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: disable pbss when gcmode archive set #559

Merged
merged 2 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ snooper_enabled: true
| Teku BN | ✅ | ✅ | ✅ | ✅ | ✅
| Lodestar BN | ✅ | ❌ | ❌ | ✅ | ❌
| Nimbus BN | ✅ | ❌ | ✅ | ❌ | ✅
| Grandine BN | ✅ | ✅ | ✅ | | ✅
| Grandine BN | ✅ | ✅ | ✅ | | ✅

## Custom labels for Docker and Kubernetes

Expand Down
14 changes: 13 additions & 1 deletion src/el/geth/geth_launcher.star
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,14 @@ def get_config(
)
elif constants.NETWORK_NAME.shadowfork in network:
init_datadir_cmd_str = "echo shadowfork"

elif (
"--gcmode archive" in extra_params
): # Disable path based storage scheme archive mode
init_datadir_cmd_str = "geth init --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,
Expand All @@ -226,7 +234,11 @@ def get_config(
"geth",
# Disable path based storage scheme for electra fork and verkle
# TODO: REMOVE Once geth default db is path based, and builder rebased
"{0}".format("--state.scheme=path" if "verkle" not in network else ""),
"{0}".format(
"--state.scheme=path"
if "verkle" not in network and "--gcmode archive" not in extra_params
else ""
),
# Override prague fork timestamp for electra fork
"{0}".format("--cache.preimages" if "verkle" in network else ""),
# Override prague fork timestamp
Expand Down
5 changes: 3 additions & 2 deletions src/package_io/input_parser.star
Original file line number Diff line number Diff line change
Expand Up @@ -483,13 +483,14 @@ def parse_network_params(input_args):

total_participant_count += participant["count"]


if total_participant_count == 1:
for index, participant in enumerate(result["participants"]):
# If there is only one participant, we run lodestar as a single node mode
if participant["cl_type"] == constants.CL_TYPE.lodestar:
participant["cl_extra_params"].append("--sync.isSingleNode")
participant["cl_extra_params"].append("--network.allowPublishToZeroPeers")
participant["cl_extra_params"].append(
"--network.allowPublishToZeroPeers"
)

if result["network_params"]["network_id"].strip() == "":
fail("network_id is empty or spaces it needs to be of non zero length")
Expand Down