From 925d5318844876983cfc1b6e748423e47c4a085e Mon Sep 17 00:00:00 2001 From: tersec Date: Sun, 26 Nov 2023 14:38:19 +0000 Subject: [PATCH] test deneb in Jenkins finalization CI (#5627) * Revert "Revert "test deneb in Jenkins finalization CI (#5625)" (#5626)" This reverts commit bbf4551ff9ad3bccc98534b94e892b764da093cc. * always use current Geth stable --- Makefile | 3 ++- scripts/execution_genesis.json.template | 4 ++-- scripts/geth_binaries.sh | 4 ++-- scripts/launch_local_testnet.sh | 14 ++++---------- 4 files changed, 10 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index cae878854..848e252df 100644 --- a/Makefile +++ b/Makefile @@ -240,7 +240,7 @@ local-testnet-minimal: --remote-validators-count 512 \ --signer-type $(SIGNER_TYPE) \ --capella-fork-epoch 0 \ - --deneb-fork-epoch 20 \ + --deneb-fork-epoch 2 \ --stop-at-epoch 6 \ --disable-htop \ --enable-payload-builder \ @@ -270,6 +270,7 @@ local-testnet-mainnet: --data-dir $@ \ --nodes 2 \ --capella-fork-epoch 0 \ + --deneb-fork-epoch 2 \ --stop-at-epoch 6 \ --disable-htop \ --enable-logtrace \ diff --git a/scripts/execution_genesis.json.template b/scripts/execution_genesis.json.template index 574c36392..dc8812733 100644 --- a/scripts/execution_genesis.json.template +++ b/scripts/execution_genesis.json.template @@ -12,8 +12,8 @@ "muirGlacierBlock":0, "berlinBlock":0, "londonBlock":0, - "shanghaiTime": 0, - "shardingForkTime": 0, + "shanghaiTime":SHANGHAI_FORK_TIME, + "cancunTime":CANCUN_FORK_TIME, "mergeForkBlock":0, "mergeNetsplitBlock":0, "terminalTotalDifficulty":0, diff --git a/scripts/geth_binaries.sh b/scripts/geth_binaries.sh index 629e99cf3..cdb00ac3e 100644 --- a/scripts/geth_binaries.sh +++ b/scripts/geth_binaries.sh @@ -17,7 +17,7 @@ source "${SCRIPTS_DIR}/bash_utils.sh" : ${CURL_BINARY:="curl"} : ${STABLE_GETH_BINARY:="${BUILD_DIR}/downloads/geth$EXE_EXTENSION"} : ${GETH_CAPELLA_BINARY:="$STABLE_GETH_BINARY"} -: ${GETH_DENEB_BINARY:="${BUILD_DIR}/downloads/geth_deneb$EXE_EXTENSION"} +: ${GETH_DENEB_BINARY:="$STABLE_GETH_BINARY"} download_geth_stable() { if [[ ! -e "${STABLE_GETH_BINARY}" ]]; then @@ -111,7 +111,7 @@ download_geth_capella() { } download_geth_deneb() { - download_status_geth_binary deneb "$GETH_DENEB_BINARY" + download_geth_stable } fi diff --git a/scripts/launch_local_testnet.sh b/scripts/launch_local_testnet.sh index 53eb5f1cb..f09e52059 100755 --- a/scripts/launch_local_testnet.sh +++ b/scripts/launch_local_testnet.sh @@ -48,7 +48,7 @@ if [[ ${PIPESTATUS[0]} != 4 ]]; then fi CURL_BINARY="$(command -v curl)" || { echo "Curl not installed. Aborting."; exit 1; } -JQ_BINARY="$(command -v jq)" || { echo "Jq not installed. Aborting."; exit 1; } +JQ_BINARY="$(command -v jq)" || { echo "jq not installed. Aborting."; exit 1; } OPTS="ht:n:d:g" LONGOPTS="help,preset:,nodes:,data-dir:,remote-validators-count:,threshold:,signer-nodes:,signer-type:,with-ganache,stop-at-epoch:,disable-htop,use-vc:,disable-vc,enable-payload-builder,enable-logtrace,log-level:,base-port:,base-rest-port:,base-metrics-port:,base-vc-metrics-port:,base-vc-keymanager-port:,base-remote-signer-port:,base-remote-signer-metrics-port:,base-el-net-port:,base-el-rpc-port:,base-el-ws-port:,base-el-auth-rpc-port:,el-port-offset:,reuse-existing-data-dir,reuse-binaries,timeout:,kill-old-processes,eth2-docker-image:,lighthouse-vc-nodes:,run-geth,dl-geth,dl-nimbus-eth1,dl-nimbus-eth2,light-clients:,run-nimbus-eth1,verbose,altair-fork-epoch:,bellatrix-fork-epoch:,capella-fork-epoch:,deneb-fork-epoch:" @@ -453,13 +453,7 @@ if [[ "${RUN_GETH}" == "1" ]]; then if [[ $DENEB_FORK_EPOCH -lt $STOP_AT_EPOCH ]]; then download_geth_deneb GETH_BINARY="$GETH_DENEB_BINARY" - elif [[ $CAPELLA_FORK_EPOCH -lt $STOP_AT_EPOCH ]]; then - download_geth_capella - GETH_BINARY="$GETH_CAPELLA_BINARY" else - # TODO We should run Geth stable here, but it lacks an ARM build for macOS, - # so we will run our own Geth capella build until we add some Geth stable - # binaries to our nimbus-simulation-binaries project: download_geth_capella GETH_BINARY="$GETH_CAPELLA_BINARY" fi @@ -702,7 +696,7 @@ fi BINARIES_MISSING="0" for BINARY in ${BINARIES}; do if [[ ! -e "build/${BINARY}" ]]; then - log "Missing binay build/${BINARY}" + log "Missing binary build/${BINARY}" BINARIES_MISSING="1" break fi @@ -831,7 +825,7 @@ GENESIS_OFFSET=60 # See `Scheduling first slot action` > `startTime` NOW_UNIX_TIMESTAMP=$(date +%s) GENESIS_TIME=$((NOW_UNIX_TIMESTAMP + GENESIS_OFFSET)) SHANGHAI_FORK_TIME=$((GENESIS_TIME + SECONDS_PER_SLOT * SLOTS_PER_EPOCH * CAPELLA_FORK_EPOCH)) -SHARDING_FORK_TIME=$((GENESIS_TIME + SECONDS_PER_SLOT * SLOTS_PER_EPOCH * DENEB_FORK_EPOCH)) +CANCUN_FORK_TIME=$((GENESIS_TIME + SECONDS_PER_SLOT * SLOTS_PER_EPOCH * DENEB_FORK_EPOCH)) EXECUTION_GENESIS_JSON="${DATA_DIR}/execution_genesis.json" EXECUTION_GENESIS_BLOCK_JSON="${DATA_DIR}/execution_genesis_block.json" @@ -840,7 +834,7 @@ EXECUTION_GENESIS_BLOCK_JSON="${DATA_DIR}/execution_genesis_block.json" # currently hard-codes some merkle branches that won't match the random deposits generated # by this simulation. This doesn't happen to produce problems only by accident. If we enable # the `deposit_root` safety-checks in the deposit downloader, it will detect the discrepancy. -sed "s/SHANGHAI_FORK_TIME/${SHANGHAI_FORK_TIME}/g; s/SHARDING_FORK_TIME/${SHARDING_FORK_TIME}/g" \ +sed "s/SHANGHAI_FORK_TIME/${SHANGHAI_FORK_TIME}/g; s/CANCUN_FORK_TIME/${CANCUN_FORK_TIME}/g" \ "${SCRIPTS_DIR}/execution_genesis.json.template" > "$EXECUTION_GENESIS_JSON" DEPOSIT_CONTRACT_ADDRESS="0x4242424242424242424242424242424242424242"