Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
6e41894
build(p2p): bump ethrex to v29.0.1 as a workspace dependency
MegaRedHand Oct 19, 2026
ce0cfd0
feat(engine): add an in-process transport for an embedded ethrex
MegaRedHand Oct 20, 2026
4d02f89
feat: embed ethrex as the beacon node's execution client (include-eth…
MegaRedHand Oct 20, 2026
5197940
docs(ethrex): both metrics servers export the default registry
MegaRedHand Oct 20, 2026
1f1b715
ci(ethrex): pin the include-ethrex job's actions like the other jobs
MegaRedHand Oct 29, 2026
cb6936b
Merge main into feat/include-ethrex
MegaRedHand Nov 4, 2026
a8eb015
Merge main into feat/include-ethrex
MegaRedHand Nov 11, 2026
8ea8e07
Merge main into feat/include-ethrex
MegaRedHand Nov 18, 2026
7a62291
Merge main into feat/include-ethrex
MegaRedHand Nov 18, 2026
1086fd0
build: bump ethrex to v31.0.0
MegaRedHand Nov 18, 2026
a5291f6
Merge main into feat/include-ethrex
MegaRedHand Nov 18, 2026
fefd9ce
fix(engine): give in-process getPayload the 1 s timeout HTTP has
MegaRedHand Nov 18, 2026
1dbe6ae
docs: put the ethrex re-diff rule next to the ethrex tag
MegaRedHand Nov 18, 2026
febfb6d
Merge main into feat/include-ethrex
MegaRedHand Nov 19, 2026
f6c8b4e
Merge main into feat/include-ethrex
MegaRedHand Nov 19, 2026
d31d28b
test(ethrex): check the in-process newPayload refuses mismatched blob…
MegaRedHand Nov 19, 2026
ac61f35
ci(ethrex): bound the include-ethrex job at 120 minutes
MegaRedHand Nov 19, 2026
3bf914d
Merge main into feat/include-ethrex
MegaRedHand Nov 20, 2026
c517ea2
docs: say make test runs test-ethrex too
MegaRedHand Nov 20, 2026
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 .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@

- [ ] Ran `make fmt` β€” clean
- [ ] Ran `make lint` (clippy with `-D warnings`) β€” clean
- [ ] Ran `make test` (`test-consensus` plus `test-node`, at `release-fast`) β€” all passing
- [ ] Ran `make test` (`test-consensus`, `test-node` and `test-ethrex`, at `release-fast`) β€” all passing
31 changes: 31 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,12 @@ jobs:
- name: Clippy (skipped spectests)
run: cargo clippy --locked --workspace --test forkchoice_spectests --test signature_spectests --test stf_spectests --test ssz_spectests --test interchange_vectors -- -D warnings

# The binary's `include-ethrex` code (the `--ethrex.*` flags, the
# embedded client's startup and shutdown) is cfg'd out of every pass
# above.
- name: Clippy (include-ethrex)
run: cargo clippy --locked --workspace --all-targets --features ethlambda/include-ethrex -- -D warnings

# `ethlambda-storage` with its `rocksdb` feature off, test targets
# included. Every other build of its tests goes through the workspace,
# where `bin/ethlambda` turns the feature on, so a test or helper that
Expand All @@ -111,6 +117,31 @@ jobs:
- name: Clippy (storage without RocksDB)
run: cargo clippy --locked -p ethlambda-storage --all-targets -- -D warnings

# The embedded execution client, in a job of its own: `make test-ethrex`
# (the third part of `make test`) says why it is kept out of
# `test-consensus` and `test-node`. No leanSpec fixtures:
# its integration tests run ethrex against a checked-in dev genesis.
ethrex:
name: Test (include-ethrex)
runs-on: ${{ vars.ETHLAMBDA_RUNNER || 'ubuntu-latest' }}
needs: detect-changes
if: ${{ !cancelled() && needs.detect-changes.outputs.run_tests != 'false' }}
# Its tests start and stop an embedded ethrex; a hung shutdown should fail
# the job rather than hold the runner for GitHub's six-hour default.
timeout-minutes: 120
steps:
- uses: actions/[email protected]

- uses: $/.github/actions/free-disk

- name: Setup Rust
uses: $/.github/actions/setup-rust
with:
cache-key: test-ethrex

- name: Run tests
run: make test-ethrex

# Two features gate code that no step in `lint` reaches, so both would rot
# silently between merges.
#
Expand Down
25 changes: 20 additions & 5 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Ethereum Beacon Chain (AKA Eth2), and `ethlambda node` runs Lean consensus.
**Rust version:** 1.97.1 (edition 2024)
**Test fixtures release:** Download latest production fixtures from leanSpec releases

## Codebase Structure (13 workspace crates)
## Codebase Structure (14 workspace crates)

```
bin/ethlambda/ # Entry point, CLI, orchestration
Expand Down Expand Up @@ -44,8 +44,11 @@ crates/
β”œβ”€ ssz-tree/ # Persistent Merkle tree (List/Vector) behind the beacon registry and balances
β”œβ”€ metrics/ # Prometheus re-exports, TimingGuard, gather utilities
└─ test-fixtures/ # Spec-fixture loading (prod dep of rpc's Hive test driver)
execution/
└─ ethrex/ # [include-ethrex] ethrex in-process: bootstrap, --ethrex.* flags, eth_ server (docs/ethrex.md)
net/
β”œβ”€ api/ # Actor protocol traits wiring BlockChain ↔ P2P
β”œβ”€ engine/ # Engine API client: JSON-RPC over HTTP, or typed in-process ethrex calls (include-ethrex)
β”œβ”€ p2p/ # libp2p: gossipsub + req-resp (Status, BlocksByRoot, BlocksByRange, gloas envelopes)
β”‚ β”œβ”€ src/gossipsub/ # Topic encoding, message handling
β”‚ β”œβ”€ src/req_resp/ # Request/response codec and handlers
Expand Down Expand Up @@ -99,9 +102,11 @@ make test # All tests + forkchoice spec tests
```

`make test` is `test-consensus` plus `test-node`, two halves CI runs as separate
jobs because together they no longer fit a runner's disk. `CONSENSUS_CRATES` in
the Makefile names the first; `test-node` is the workspace minus it. Run one half
directly when iterating on it.
jobs because together they no longer fit a runner's disk, plus `test-ethrex`, the
embedded execution client's tests with the `include-ethrex` feature on (a third
job). `CONSENSUS_CRATES` in the Makefile names the first half; `test-node` is the
workspace minus it and `ETHREX_CRATES`. Run one part directly when iterating on
it.

### Docs-only changes skip CI

Expand Down Expand Up @@ -737,7 +742,7 @@ transitions are in `ethlambda-types`, per the section above. Nothing above
- Tests: `make test-beacon` (builds once per preset), or `test-beacon-mainnet` /
`test-beacon-minimal` for one. CI runs the two as a job each, so they build and
run concurrently. `make test` covers the whole
workspace, in two halves, and still needs no fixture download: the
workspace, in two halves plus `test-ethrex`, and still needs no fixture download: the
`beacon_spec_tests` target declares `required-features = ["beacon-spec-tests"]`
so `cargo test` skips it, and the BLS and KZG fixture vectors, which are unit
tests inside the module, are `#[cfg_attr(not(feature = ...), ignore)]` so they
Expand Down Expand Up @@ -1001,6 +1006,16 @@ incremental, and line-tables-only debuginfo, so rebuilds are much faster than

## Common Gotchas

### Embedded ethrex (`include-ethrex`)
- In a feature build, `ethlambda beacon` without `--execution-endpoint` starts ethrex
in-process; with the endpoint it uses HTTP as before. A feature build has no
"no execution client" mode. See [`docs/ethrex.md`](docs/ethrex.md)
- One ethrex tag for the whole workspace (`[workspace.dependencies]`), shared with
p2p's discovery. Bumping it means re-diffing ethrex's `init_l1`/`init_rpc_api`/
`server_shutdown` against `crates/execution/ethrex/src/lib.rs`, which repeats them
- `make test-node` excludes `ethlambda-ethrex`; `make test-ethrex` (own CI job) runs
it plus the engine and binary with the feature on

### Aggregator Flag Required for Finalization
- At least one node **must** be started with `--is-aggregator` to finalize blocks
- Without this flag, attestations pass signature verification and are logged as "Attestation processed", but the signature is never stored for aggregation (the `is_aggregator` gate in `on_gossip_attestation`, `store.rs`), so blocks are always built with `attestation_count=0`
Expand Down
Loading
Loading