Commit Graph

7478 Commits

Author SHA1 Message Date
Mac L
b9a68ad2c6 Add support for jemalloc memory profiling (#9326)
Add a new feature flag to `lighthouse` which adds jemalloc profiling support.
We could manually add this during memory profiling but it is a nice QoL to have this built-in imo


Co-Authored-By: Mac L <mjladson@pm.me>
2026-05-25 01:21:26 +00:00
Eitan Seri-Levi
0565a01633 Gloas dont enforce peer column custody on block import (#9341)
Peers that advertise that they have imported a block may not have the columns for that slot available post-Gloas. Ensure that we dont penalize them.


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-25 00:21:17 +00:00
Eitan Seri-Levi
5045e8dd85 Custody backfill sync only penalize peers once per batch (#9340)
During custody backfill sync if a peer fails to serve columns for a batch don't penalize them more than once per batch


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-22 17:50:50 +00:00
Eitan Seri-Levi
5693d86002 Ensure we use the right fork when calculating payload attestation sig domain (#9342)
Using `state.fork` is a bit sketchy at the fork boundary. It's safer to just use the payload attestations slot


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-22 17:50:45 +00:00
Eitan Seri-Levi
60abd4b5b9 Gloas alpha spec 8 (#9315)
https://github.com/ethereum/consensus-specs/releases/tag/v1.7.0-alpha.8


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-05-22 06:21:20 +00:00
Daniel Knopik
b5d5644eeb Add getBlobsV3 to LIGHTHOUSE_CAPABILITIES (#9330)
Forgot to add `ENGINE_GET_BLOBS_V3` to `LIGHTHOUSE_CAPABILITIES`.


  Add `ENGINE_GET_BLOBS_V3` to `LIGHTHOUSE_CAPABILITIES`.


Co-Authored-By: Daniel Knopik <daniel@dknopik.de>
2026-05-21 20:00:16 +00:00
Lion - dapplion
1caaa10fa8 Drop unused EthSpec generic from Stores (#9281)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-05-21 08:35:35 +00:00
Daniel Knopik
a9637c1650 Partial columns cleanup (#9321)
#8314 left a few ugly potentially panicking location behind - all of them believed to be unreachable, but this PR fixes them regardless for good hygiene.


  Update to `ethereum_ssz 0.10.4` for two new helpers: `not_inplace` and `clone_zeroed`.

Remove remaining `expect` and `todo!` in favour of these helpers and one new fallible (but practically infallible) method.


Co-Authored-By: Daniel Knopik <daniel@dknopik.de>
2026-05-21 03:25:02 +00:00
Lion - dapplion
2c76ee5b6b Gloas lookup sync boilerplate (#9322)
Implements the boring boilerplate to send envelopes by root requests and process them. Pre-step to

- https://github.com/sigp/lighthouse/pull/9155


  


Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-05-20 12:56:49 +00:00
Lion - dapplion
398efc3acc Use dedicated cache for HTTP API route (#9318)
- PR https://github.com/sigp/lighthouse/pull/9305 wants to store PTCs in the committee cache.

BUT the http API route wants to use the committee cache and insert historical committees (i.e. given state at epoch 1000, compute and store the committee for epoch 900).

If we want a single cache to serve both use cases we need to:
- Have entries in the committee cache that have no PTC: Makes reading PTCs from the cache not deterministic
- Compute historical PTC: A bunch of complicated code that's useless

Instead we can add a separate cache for the API, very simple one, that caches committees only. And have the one in the beacon chain compute and cache PTCs always.

### Performance impact

Slightly additional memory cost for users of the `beacon/states/committees` route. Caching is almost equivalent, except for queries of recent committees that may already exist in the beacon chain's committee cache.

### AI disclousure

This PR was written by hand 90%. Claude fixed some warp type issues


  


Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-05-19 05:12:17 +00:00
Michael Sproul
fd0852a8e5 Remove outdated SPRP hint (#9312)
While working on this code in another branch I noticed we had this messy, complicated and incorrect code about SPRP (slots-per-restore-point), which is no longer a relevant concept since the introduction of hot state diffs.

In the name of simplicity, I've removed any kind of hinting here in favour of a simple out of bounds error. The benefit of adding complex hinting code (which is not tested) to such a function is not worth it IMO. Users will work it out (or ask) if we just tell them their request is out of bounds.


Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-05-19 01:35:31 +00:00
Daniel Knopik
1a68631180 Gloas payload cache (#9209)
In Gloas, beacon blocks are imported into fork choice immediately - the payload envelope and data columns arrive
separately. KZG commitments moved from the column sidecar into the execution payload bid, so the existing
`DataAvailabilityChecker` (which assumes block and data are coupled) can't be used for Gloas.


  * Introduced `PendingPayloadCache` to keep track of payload and data columns per block root.
* Added gossip column verification
* Added support for Gloas data column reconstruction
* Payload envelope verification simplified: removed `MaybeAvailableEnvelope`, `ExecutedEnvelope`, `EnvelopeImportData`

Not yet implemented (tracked with TODOs):
- Proper lookup sync for Gloas columns arriving before blocks
- Partial column merging for Gloas
- Moving `load_gloas_payload_bid` disk reads off the async runtime
- Backfill/range sync for Gloas

Based on @eserilev's PR and work in progress. See also #9202 for verification.


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Eitan Seri- Levi <eserilev@gmail.com>

Co-Authored-By: Daniel Knopik <daniel@dknopik.de>

Co-Authored-By: Daniel Knopik <107140945+dknopik@users.noreply.github.com>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-05-13 07:03:34 +00:00
Eitan Seri-Levi
9101ddc69d ignore-ws-check flag doesnt allow the node to start outside the weak subjectivity period (#9290)
Using the `ignore-ws-check` doesn't actually let you start up a node thats outside the weak subjectivity period


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-13 04:20:08 +00:00
hopinheimer
757873200b Fix stale beacon_state_root in test helpers (#9289)
Test helpers `add_attested_block_at_slot` and `add_attested_blocks_at_slot` accepted `state_root` argument which was computed before applying the block.


  


Co-Authored-By: hopinheimer <knmanas6@gmail.com>
2026-05-12 06:24:18 +00:00
Eitan Seri-Levi
f968c7e5bb Dont penalize payload envelope peers after gossip verification (#9283)
We got in a little bit of trouble in devnet-3. After gossip verifying an envelope and before importing it, we got the following error

```
May 07 08:04:24.383 WARN  Execution payload envelope rejected           reason: "EnvelopeProcessingError(WithdrawalsRootMismatch { state: 0x852d38aaecc9f4e2e309919f74020c7bbcf050fea4a20edf3304f171e44ee9d5, payload:
```

The envelope had already passed gossip verification checks and was correctly propagated to the network, we should not penalize peers for doing this. This caused our node to isolate itself from the rest of the network. This PR removes peer penalties for any envelope that passes gossip validation


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-12 01:59:54 +00:00
Shane K Moore
2208e17937 chore: remove builder_index from produce_block_v4 (#9267)
Part of #8828 for the stateful path and helps align gloas `produceBlockV4` with beacon-APIs [PR](https://github.com/ethereum/beacon-APIs/pull/580)


  - Plumb `include_payload` query through the handler. Ignored for now since stateless mode isn't wired up yet
- Add `execution_payload_included` metadata field + `Eth-Execution-Payload-Included` header per spec. Both `false` until stateless lands
- Drop the `{builder_index}` segment from the envelope GET URL since no longer included in spec


Co-Authored-By: shane-moore <skm1790@gmail.com>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-05-11 15:27:41 +00:00
chonghe
1b921a64e6 Fix execution integration test CI failure (#9277)
Co-Authored-By: Tan Chee Keong <tanck@sigmaprime.io>
2026-05-08 08:12:38 +00:00
Lion - dapplion
7148bfcdd1 Implement beacon_blocks_by_head (#9237)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-05-07 02:41:01 +00:00
Lion - dapplion
31e5f308c3 Generalise reconstruct_historic_states for ranged replay (#9222)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-05-06 02:25:46 +00:00
Mac L
3351db1ba8 Remove TestRandom (#9006)
We  have a legacy `TestRandom` trait which generates random types for testing and fuzzing.
This function overlaps with `arbitrary` which is used very commonly in the ecosystem.


  Remove `TestRandom` and generate random type instances using `Arbitrary`.


Co-Authored-By: Mac L <mjladson@pm.me>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-05-05 06:35:57 +00:00
Pawan Dhananjay
4b314d8e79 Remove libssl dependency for cargo udeps (#9263)
N/A


  libssl download seems to be failing on [CI](https://github.com/sigp/lighthouse/actions/runs/25346412432/job/74316275231?pr=9126).
This was originally added to unblock CI in https://github.com/sigp/lighthouse/pull/6777, but we may not need this anymore.


Co-Authored-By: Pawan Dhananjay <pawandhananjay@gmail.com>
2026-05-05 02:05:06 +00:00
jking-aus
d9be76afe7 fix: payload_attestation_data when no block received for slot (#9225)
Addresses issue #9220

The `payload_attestation_data` endpoint returns 400 when no block has been received for the requested slot. This causes the VC to log at CRIT level for what is expected behaviour per spec: validators should simply not submit a payload attestation when no block has been seen.


  - Return 404 (Not Found) instead of 400 from `payload_attestation_data` when no block exists for the slot. This is consistent with other beacon api endpoints.
- Downgrade the VC log from `crit` to `debug` when a 503 is received, since this is an expected no-op per spec.
- Add `BlockNotFound` rejection type to `warp_utils`.
- Add a test asserting the 404 response for an empty slot.


Co-Authored-By: Josh King <josh@sigmaprime.io>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-05-04 23:39:33 +00:00
Eitan Seri-Levi
9cf155a0dd Implement gloas proposer preference vc duty (#9208)
Allow for the vc to submit its proposer preferences to the network


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-05-04 11:33:09 +00:00
Mac L
ee61aee659 Unblock CI by temporarily ignoring hickory-proto audit failures (#9257)
Two audit failures for `hickory-proto` which is used upstream in `libp2p-dns` and `libp2p-mdns`

- https://rustsec.org/advisories/RUSTSEC-2026-0118.html
- https://rustsec.org/advisories/RUSTSEC-2026-0119.html

Tracking Issue: https://github.com/sigp/lighthouse/issues/9258


  Since RUSTSEC-2026-0118 does not even have any non-patched versions available and RUSTSEC-2026-0119 requires a major version bump I think we would need to wait on a release from libp2p in both cases.
So for now, add an ignore for each so we can at least unblock CI


Co-Authored-By: Mac L <mjladson@pm.me>
2026-05-03 11:10:19 +00:00
jking-aus
330348ea14 fix: prevent duplicate column reconstruction dispatch (#9250)
Fixes a flaky CI failure in `data_column_reconstruction_at_deadline` where 2 `column_reconstruction` events are emitted instead of the expected 1.


  - Change `queued_column_reconstructions` from `HashMap<Hash256, DelayKey>` to `HashMap<Hash256, Option<DelayKey>>`, where `None` indicates reconstruction was already dispatched.
- On dispatch (`ReadyColumnReconstruction`), set the entry to `None` instead of removing it. This prevents a subsequent gossip column from inserting a fresh reconstruction request into the now-vacant slot.
- Prune stale `None` entries on each dispatch to keep the map bounded.


Co-Authored-By: Josh King <josh@sigmaprime.io>
2026-05-01 12:44:25 +00:00
Michael Sproul
8b8124d4a4 Avoid 0x00 block hashes in fcU (#9233)
- Avoid sending 0x00 block hashes for the safe and finalized block hashes post-Gloas.
- Add code to check this inside the mock EL, which will be reached in all Gloas beacon chain tests


Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-05-01 09:12:11 +00:00
Sayan Mallick
5384ab8d67 Update CI: warp runnner to use snapshot and use warm (#9217)
Update the ci workflow to use warpbuild snapshot image and test suit uses `Swatinew/rust-cache` to utilize warpbuild cache


  


Co-Authored-By: lemon <snyxmk@gmail.com>
2026-05-01 00:05:17 +00:00
Eitan Seri-Levi
effcd08223 Gloas proposer preferences alpha 7 (#9239)
We yolo'd to alpha 7. We're just changing the proposer preference to include dependent root, instead of checkpoint root. This way we can actually construct it within the VC without needing a view of fork choice.


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-04-30 09:36:45 +00:00
Michael Sproul
8bb14d6f3d Gloas HTTP API tests passing (#9154)
Get the Gloas HTTP API tests passing, partly through fixes and partly through disabling tests that don't fit the Gloas paradigm.


Co-Authored-By: Michael Sproul <michael@sigmaprime.io>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-30 08:15:26 +00:00
Eitan Seri-Levi
728356ad03 Submit ptc votes that we produce to the ptc op pool (#9231)
We are not submitting ptc votes that we produce to our lcoal ptc op pool. So when we are the block producer we don't include our own ptc votes!


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-04-30 06:43:14 +00:00
chonghe
8d77b1c08d Remove test_logger feature (#9125)
- #9107


  Remove all instances of `test_logger` in the code


Co-Authored-By: Tan Chee Keong <tanck@sigmaprime.io>
2026-04-30 04:57:47 +00:00
Jimmy Chen
04b2589807 Import execution payload envelope locally during HTTP API publication (#9226)
Fixes a bug where a proposer votes payload missing on its own block.

The payload is published to the network but never imported locally. This PR adds gossip verification and import when a payload is sent to the http API


  


Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-29 15:43:30 +00:00
Michael Sproul
f406e9c3fb Update proposer boost calculation (#9215)
Closes:

- https://github.com/sigp/lighthouse/issues/8689


  - Calculate the proposer index on the canonical chain (from canonical head) at `slot` and plumb it through to fork choice so it can be used to determine whether or not to apply the proposer boost. We use the proposer cache to handle state advances and avoid duplicate work.
- Update our FC tests to use `block.message().proposer_index()` (always pass), we are not attempting to test this feature in those tests. The EF tests use the correct canonical proposer idnex via `on_block`, except for invalid blocks which just auto-pass this check (these blocks get rejected by other checks in `on_block` anyway).


Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-04-29 12:19:44 +00:00
Lion - dapplion
0e427ab77b Add Gloas bid inclusion (#9221)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-04-29 12:02:12 +00:00
jking-aus
16132a3694 Spec v1.7.0-alpha.6 and Gloas genesis (#9190)
Co-Authored-By: Josh King <josh@sigmaprime.io>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-04-29 08:23:24 +00:00
Eitan Seri-Levi
e8c865dcc6 Gossip reprocessed payload envelopes that are timely (#9210)
Payloads from the reprocess queue should be gossiped after import if they are still timely. In devnets this happens frequently since there are many cases where the envelope arrives before the block


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-04-28 21:50:07 +00:00
Eitan Seri-Levi
6258eadc91 Gloas publish data columns during local block building (#9182)
Make sure we are publishing columns during local block production


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-04-28 13:19:47 +00:00
Eitan Seri-Levi
4415cf0506 Gloas filter conflicting voluntary exits (#9183)
Parent envelope execution requests can invalidate voluntary exits. We should filter out any conflicting voluntary exits during block production to avoid triggering failures.

Spec change: https://github.com/ethereum/consensus-specs/pull/5176


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-04-28 12:45:03 +00:00
Jimmy Chen
d8790f6677 Add payload attestation to op pool and pack into block (#9180)
Store gossip-verified `PayloadAttestationMessage`s in the operation pool and pack them into the block body at during block production.

Built on top of #9145.


  


Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-28 10:49:28 +00:00
Mac L
e35a671303 Fix validator manager compilation (#9187)
Currently, running `cargo check -p validator_manager` fails due to missing features. Although the `validator_manager` will almost always be called through the Lighthouse binary which will enable the required features, it is still good hygiene to ensure all workspace crates can compile standalone.


  Add the `lighthouse` feature to the `eth2` dependency in `validator_manager`


Co-Authored-By: Mac L <mjladson@pm.me>
2026-04-28 08:59:07 +00:00
Jimmy Chen
280e2f1d53 Wire up ePBS SSE events and fix envelope availability (#9199)
Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-28 08:59:01 +00:00
Jimmy Chen
919c996c18 Fix spurious re-org logs on ePBS payload status changes (#9191)
Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-28 08:15:10 +00:00
Mac L
949c027dfd Add method to Hash256 to display shortened hashes (#9118)
#6689


  Inspired by the initial implementation of #9108, credit to @chong-he.
This adds an extension trait to `Hash256` and add a `short` method to provide smaller formatted hashes for logging.


Co-Authored-By: Mac L <mjladson@pm.me>
2026-04-28 07:01:13 +00:00
Eitan Seri-Levi
028b5a42a9 Add payload attestation validator duty (#9178)
Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-27 15:13:35 +00:00
hopinheimer
6ab48a76f0 Gloas PayloadAttestation gossip verification (#9145)
Co-Authored-By: hopinheimer <knmanas6@gmail.com>

Co-Authored-By: hopinheimer <48147533+hopinheimer@users.noreply.github.com>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-27 09:51:20 +00:00
Shane K Moore
fae7941b2d Gloas ptc duties beacon node response (#8415)
Co-Authored-By: shane-moore <skm1790@gmail.com>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: Eitan Seri-Levi <eserilev@gmail.com>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-04-26 15:25:00 +00:00
Eitan Seri-Levi
276c4d5ff3 Gloas set AttestationData.index (#9100)
For gloas `attestation.data.index` should be set to 1 if we are attesting to a block whose slot is not the attestation duty slot and slot payload_status is `FULL`


  


Co-Authored-By: Eitan Seri- Levi <eserilev@gmail.com>

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>

Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-04-26 13:40:22 +00:00
Eitan Seri-Levi
6323cd3827 Fix builder exit signature batch verification logic and small refactor (#9173)
We had a bug when performing batch builder exit signature verification. The EF spec tests cover this case, but the EF tests only calls  individual signature verification (which is a separate code path). This PR unifies the two code paths. We should probably spend some time reviewing EF test code coverage and make sure we don't have separate code paths that do similar things.


  


Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-04-25 23:51:02 +00:00
hopinheimer
df764ffa9a Re-issue ForkchoiceUpdate based on updated PayloadStatus (#9102)
Co-Authored-By: hopinheimer <knmanas6@gmail.com>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>

Co-Authored-By: Michael Sproul <michaelsproul@users.noreply.github.com>
2026-04-25 08:04:09 +00:00
Daniel Knopik
8a384ff445 Cell Dissemination (Partial messages) (#8314)
- https://github.com/ethereum/consensus-specs/pull/4558
- https://eips.ethereum.org/EIPS/eip-8136


  


Co-Authored-By: Daniel Knopik <daniel@dknopik.de>

Co-Authored-By: Pawan Dhananjay <pawandhananjay@gmail.com>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>
2026-04-23 18:52:28 +00:00