From a921e425b47ba0a84bae4a8f701915e5095efc28 Mon Sep 17 00:00:00 2001 From: xermicus Date: Mon, 10 Feb 2025 17:39:44 +0100 Subject: [PATCH] CI: fix and pin geth (#206) --- .github/workflows/rust.yml | 9 ++++--- Cargo.lock | 43 +++++++++++++++++++++++++++----- Cargo.toml | 4 +-- crates/differential/genesis.json | 9 ++++++- crates/differential/src/lib.rs | 2 +- 5 files changed, 53 insertions(+), 14 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 5a7191fc..40a0fdf7 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -30,11 +30,12 @@ jobs: tar Jxf llvm.tar.xz -C llvm18/ echo "LLVM_SYS_181_PREFIX=$(pwd)/llvm18" >> $GITHUB_ENV - - name: Install apt dependencies + - name: Install geth run: | - sudo add-apt-repository -y ppa:ethereum/ethereum - sudo apt update - sudo apt install -y ethereum + git clone https://github.com/xermicus/go-ethereum --branch=cl/fix-runner-state-dump --depth=1 + cd go-ethereum + make all + echo "$(pwd)/build/bin/" >> $GITHUB_PATH - name: Machete uses: bnjbvr/cargo-machete@main diff --git a/Cargo.lock b/Cargo.lock index efef7438..eee21f0a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -129,6 +129,18 @@ dependencies = [ "winnow", ] +[[package]] +name = "alloy-eip2124" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "675264c957689f0fd75f5993a73123c2cc3b5c235a38f5b9037fe6c826bfb2c0" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "crc", + "thiserror 2.0.11", +] + [[package]] name = "alloy-eip2930" version = "0.1.0" @@ -154,25 +166,28 @@ dependencies = [ [[package]] name = "alloy-eips" -version = "0.9.2" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52dd5869ed09e399003e0e0ec6903d981b2a92e74c5d37e6b40890bad2517526" +checksum = "7149e011edbd588f6df6564b369c75f6b538d76db14053d95e0b43b2d92e4266" dependencies = [ + "alloy-eip2124", "alloy-eip2930", "alloy-eip7702", "alloy-primitives", "alloy-rlp", "alloy-serde", + "auto_impl", "c-kzg", "derive_more 1.0.0", + "once_cell", "serde", ] [[package]] name = "alloy-genesis" -version = "0.9.2" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7d2a7fe5c1a9bd6793829ea21a636f30fc2b3f5d2e7418ba86d96e41dd1f460" +checksum = "acaec0cc4c1489d61d6f33d0c3dd522c750025f4b5c8f59cd546221e4df660e5" dependencies = [ "alloy-eips", "alloy-primitives", @@ -244,9 +259,9 @@ dependencies = [ [[package]] name = "alloy-serde" -version = "0.9.2" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae0465c71d4dced7525f408d84873aeebb71faf807d22d74c4a426430ccd9b55" +checksum = "86aa42c36e3c0db5bd9a7314e98aa261a61d5e3d6a0bd7e51fb8b0a3d6438481" dependencies = [ "alloy-primitives", "serde", @@ -1609,6 +1624,7 @@ dependencies = [ "glob", "hex", "libc", + "once_cell", "serde", ] @@ -1994,6 +2010,21 @@ dependencies = [ "wasmtime-types", ] +[[package]] +name = "crc" +version = "3.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69e6e4d7b33a94f0991c26729976b10ebde1d34c3ee82408fb536164fa10d636" +dependencies = [ + "crc-catalog", +] + +[[package]] +name = "crc-catalog" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" + [[package]] name = "crc32fast" version = "1.4.2" diff --git a/Cargo.toml b/Cargo.toml index ed6fc9f7..30d6148f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -53,8 +53,8 @@ polkavm-disassembler = "0.19.0" polkavm = "0.19.0" alloy-primitives = { version = "0.8.19", features = ["serde"] } alloy-sol-types = "0.8.19" -alloy-genesis = "0.9.2" -alloy-serde = "0.9.2" +alloy-genesis = "0.11.0" +alloy-serde = "0.11.0" env_logger = { version = "0.11.6", default-features = false } serde_stacker = "0.1.11" criterion = { version = "0.5.1", features = ["html_reports"] } diff --git a/crates/differential/genesis.json b/crates/differential/genesis.json index 49f3431c..6a91218b 100644 --- a/crates/differential/genesis.json +++ b/crates/differential/genesis.json @@ -16,7 +16,14 @@ "shanghaiTime": 0, "cancunTime": 0, "terminalTotalDifficulty": 0, - "terminalTotalDifficultyPassed": true + "terminalTotalDifficultyPassed": true, + "blobSchedule": { + "cancun": { + "target": 3, + "max": 6, + "baseFeeUpdateFraction": 3338477 + } + } }, "coinbase": "0xffffffffffffffffffffffffffffffffffffffff", "difficulty": "0x20000", diff --git a/crates/differential/src/lib.rs b/crates/differential/src/lib.rs index 2462b847..6be5bdb1 100644 --- a/crates/differential/src/lib.rs +++ b/crates/differential/src/lib.rs @@ -413,7 +413,7 @@ impl Evm { let stderr = str::from_utf8(output.stderr.as_slice()) .unwrap_or_else(|err| panic!("{EXECUTABLE_NAME} stderr failed to parse: {err}")); - let mut log: EvmLog = stdout.into(); + let mut log: EvmLog = format!("{stdout}{stderr}").as_str().into(); log.stderr = stderr.into(); if self.bench { log.parse_gas_used_from_bench();