Skip to content

Commit 567cc38

Browse files
authored
feat: enable legacy state root tree by default (#474)
* feat: enable legacy state root tree by default * remove unused code * fix: ci failure due to rust version * fix: ci * update makefile * rm rusttoolchain.toml
1 parent c00bd01 commit 567cc38

File tree

4 files changed

+21
-9
lines changed

4 files changed

+21
-9
lines changed

.github/workflows/lint.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
- uses: rui314/setup-mold@v1
2222
- uses: dtolnay/rust-toolchain@clippy
2323
with:
24+
toolchain: 'nightly-2026-01-05'
2425
components: clippy
2526
- uses: Swatinem/rust-cache@v2
2627
with:
@@ -38,6 +39,7 @@ jobs:
3839
- uses: rui314/setup-mold@v1
3940
- uses: dtolnay/rust-toolchain@nightly
4041
with:
42+
toolchain: 'nightly-2026-01-05'
4143
components: rustfmt
4244
- name: Run fmt
4345
run: cargo fmt --all --check
@@ -59,13 +61,15 @@ jobs:
5961
- uses: actions/checkout@v6
6062
- uses: rui314/setup-mold@v1
6163
- uses: dtolnay/rust-toolchain@nightly
64+
with:
65+
toolchain: 'nightly-2026-01-05'
6266
- uses: Swatinem/rust-cache@v2
6367
with:
6468
cache-on-failure: true
6569
- uses: taiki-e/install-action@cargo-udeps
6670
- name: Run udeps
6771
run: cargo udeps --workspace --lib --examples --tests --benches --all-features --locked
68-
72+
6973
zepter:
7074
runs-on: ubuntu-latest
7175
timeout-minutes: 10
@@ -88,6 +92,8 @@ jobs:
8892
- uses: actions/checkout@v6
8993
- uses: rui314/setup-mold@v1
9094
- uses: dtolnay/rust-toolchain@nightly
95+
with:
96+
toolchain: 'nightly-2026-01-05'
9197
- uses: Swatinem/rust-cache@v2
9298
with:
9399
cache-on-failure: true

.github/workflows/test.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
- uses: rui314/setup-mold@v1
2525
- uses: dtolnay/rust-toolchain@nightly
2626
with:
27-
toolchain: 'nightly'
27+
toolchain: 'nightly-2026-01-05'
2828
- uses: Swatinem/rust-cache@v2
2929
with:
3030
cache-on-failure: true
@@ -43,7 +43,7 @@ jobs:
4343
- uses: rui314/setup-mold@v1
4444
- uses: dtolnay/rust-toolchain@nightly
4545
with:
46-
toolchain: 'nightly'
46+
toolchain: 'nightly-2026-01-05'
4747
- uses: Swatinem/rust-cache@v2
4848
with:
4949
cache-on-failure: true

Makefile

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1+
NIGHTLY_TOOLCHAIN := nightly-2026-01-05
2+
13
.PHONY: fmt
24
fmt:
3-
cargo +nightly fmt
5+
cargo +$(NIGHTLY_TOOLCHAIN) fmt
46

57
.PHONY: lint-toml
68
lint-toml: ensure-dprint
@@ -14,7 +16,7 @@ ensure-dprint:
1416

1517
.PHONY: clippy
1618
clippy:
17-
cargo +nightly clippy \
19+
cargo +$(NIGHTLY_TOOLCHAIN) clippy \
1820
--workspace \
1921
--lib \
2022
--examples \
@@ -25,7 +27,7 @@ clippy:
2527

2628
.PHONY: clippy-fix
2729
clippy-fix:
28-
cargo +nightly clippy \
30+
cargo +$(NIGHTLY_TOOLCHAIN) clippy \
2931
--workspace \
3032
--lib \
3133
--examples \
@@ -37,7 +39,7 @@ clippy-fix:
3739

3840
.PHONY: udeps
3941
udeps:
40-
cargo +nightly udeps --workspace --lib --examples --tests --benches --all-features --locked
42+
cargo +$(NIGHTLY_TOOLCHAIN) udeps --workspace --lib --examples --tests --benches --all-features --locked
4143

4244
.PHONY: codespell
4345
codespell: ensure-codespell
@@ -64,7 +66,7 @@ lint: fmt lint-toml clippy udeps codespell zepter
6466

6567
.PHONY: test
6668
test:
67-
cargo nextest run \
69+
cargo +$(NIGHTLY_TOOLCHAIN) nextest run \
6870
--workspace \
6971
--locked \
7072
--all-features \

crates/node/src/main.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,11 @@ fn main() {
4545
.config()
4646
.engine
4747
.tree_config()
48-
.with_always_process_payload_attributes_on_canonical_head(true).with_persistence_threshold(0).with_unwind_canonical_header(true);
48+
.with_always_process_payload_attributes_on_canonical_head(true)
49+
.with_persistence_threshold(0)
50+
.with_unwind_canonical_header(true)
51+
// Use legacy state root processor due to performance issues with the new state root processor in reth.
52+
.with_legacy_state_root(true);
4953
let launcher = EngineNodeLauncher::new(
5054
builder.task_executor().clone(),
5155
builder.config().datadir(),

0 commit comments

Comments
 (0)