Commit Graph

1746 Commits

Author SHA1 Message Date
Eitan Seri-Levi
d0054d18d0 Merge remote-tracking branch 'origin/gloas-proposer-preferences-sse' into gloas-alpha-spec-9 2026-06-11 18:28:04 +03:00
Eitan Seri-Levi
596b01b5ec Resolve merge conflicts 2026-06-11 18:16:42 +03:00
Eitan Seri-Levi
ed594c50bc Merge branch 'gloas-fix-proposer-pref-gossip-verification' into gloas-alpha-spec-9 2026-06-11 18:10:48 +03:00
Eitan Seri-Levi
8b8ebe3fc0 Merge branch 'gloas-checkpoint-sync' into gloas-alpha-spec-9 2026-06-11 18:09:16 +03:00
Eitan Seri-Levi
ca4330511a Merge branch 'unstable' of https://github.com/sigp/lighthouse into gloas-alpha-spec-9 2026-06-11 18:08:20 +03:00
Eitan Seri-Levi
acf0194f60 Merge branch 'unstable' into gloas-proposer-preferences-sse 2026-06-11 08:04:13 -07:00
Daniel Knopik
43c2e78139 Better partial diagnosics (#9436)
Small collection of improved diagnostics for partials.


  - In the peer info struct (exposing peer data via `/lighthouse/peers`), add a new field to indicate on which subnets the peer supports partials.
- Fix the description of several metrics.
- Downgrade some noisy logging when sending partials to trace, and downgrade one warning that should not worry the user.


Co-Authored-By: Daniel Knopik <daniel@dknopik.de>
2026-06-10 19:39:07 +00:00
Eitan Seri-Levi
4d6d8d7d36 Fix tests 2026-06-10 16:43:07 +03:00
Eitan Seri-Levi
0ce1345ca5 cleanup 2026-06-10 15:17:47 +03:00
Eitan Seri-Levi
126678109c Enable optimistic sync 2026-06-10 14:31:48 +03:00
Eitan Seri-Levi
3226b54cd2 Fix 2026-06-10 14:29:18 +03:00
Eitan Seri-Levi
2ba7593b02 fmt 2026-06-10 13:45:40 +03:00
Eitan Seri-Levi
71b539cf8f fix tests 2026-06-10 13:45:40 +03:00
Eitan Seri-Levi
47789368c4 test changes 2026-06-10 13:45:40 +03:00
Eitan Seri-Levi
57df3021b4 checkpoint envelope test 2026-06-10 13:45:40 +03:00
Eitan Seri-Levi
66521b01d6 Implement gloas checkpoint sync 2026-06-10 13:45:40 +03:00
Pawan Dhananjay
db3192e001 Gloas range sync (#9362)
N/A


  Implement range sync in gloas.
Basically requests blocks and payloads post gloas from the same peer, couples them and sends it for processing.
Does not change sync much at all other than adding the machinery for payloads by range requests.

Main changes are:
`RangeSyncBlock` which used to be a struct is an enum to account for the Gloas case. This allows a clear separation between gloas and pre-gloas code.
`AvailableBlockData` now has a `BlockInEnvelope` variant. This is to clearly indicate the post gloas case. I feel this is simpler to follow compared to `NoData` variant.


Tries to extract post gloas logic into its own functions so that there is minimal logic change in mainnet range sync behaviour.

This is meant as a stable base on which we can iterate further to make range sync cleaner and for unblocking range sync support on devnet. Some ideas for later is removing the retry mechanism in favour of delegating column fetching to lookup sync which can be done post #9155 and batch signature verifying envelopes.


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

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

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-06-10 10:30:57 +00:00
Lion - dapplion
47e0901965 Gloas lookup sync (#9155)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>

Co-Authored-By: Pawan Dhananjay <pawandhananjay@gmail.com>
2026-06-10 01:41:26 +00:00
Daniel Knopik
ebe5ded2fa Fix sending partials from immediately complete columns (#9433)
The initial partial send after getBlobs only sends incomplete partial columns, causing issues as we do not propagate these columns.


  Return complete and incomplete columns from `get_columns_and_mark_as_local_fetched`, and convert any complete columns to partials if necessary. Send all columns retrieved this way after getBlobs


Co-Authored-By: Daniel Knopik <daniel@dknopik.de>
2026-06-09 17:38:55 +00:00
Eitan Seri-Levi
88f514c27d Update beacon_node/beacon_chain/src/payload_attestation_verification/mod.rs
Co-authored-by: Michael Sproul <michaelsproul@users.noreply.github.com>
2026-06-09 10:33:08 +03:00
Eitan Seri-Levi
a70085cd8a Merge branch 'unstable' of https://github.com/sigp/lighthouse into gloas-alpha-spec-9 2026-06-07 16:59:55 +03:00
Eitan Seri-Levi
c1cfcfebf7 fix 2026-06-07 16:59:13 +03:00
Eitan Seri-Levi
21688bccf9 Small comment fix 2026-06-06 15:56:55 +03:00
Eitan Seri-Levi
3524440c48 small fixes' 2026-06-06 15:55:10 +03:00
Jimmy Chen
65f1a832e4 Optimise slow block verification tests (#9274)
Reduce CI time for `block_verification` tests that exceed 120s on Fulu/Gloas forks.

- Cache the chain segment across tests using `LazyLock<OnceCell>` (was rebuilt 10+ times independently)
- Reduce chain length from 320 to 192 slots (10 epochs to 6 epochs)
- Reduce `BLOCK_INDICES` from 7 to 3
- Reduce `chain_segment_varying_chunk_size` from 5 to 3

AI assisted, self reviewed.

Before vs After comparison (1 sample only):

* **Before**: 19 tests exceeded the 120s slow threshold.
* **After**: zero exceed it. Overall: 1,890s down to 797s (-58%).

```
| Test                                                 |  Before |   After |  Change |
|------------------------------------------------------|---------|---------|---------|
| chain_segment_varying_chunk_size                     |   239s  |     98s |    -59% |
| invalid_signature_attester_slashing                  |   175s  |     64s |    -64% |
| invalid_signature_exit                               |   173s  |     62s |    -64% |
| invalid_signature_deposit                            |   170s  |     60s |    -65% |
| invalid_signature_attestation                        |   165s  |     62s |    -63% |
| invalid_signature_proposer_slashing                  |   161s  |     56s |    -66% |
| block_gossip_verification                            |   154s  |     91s |    -41% |
| invalid_signature_block_proposal                     |   151s  |     58s |    -61% |
| invalid_signature_randao_reveal                      |   149s  |     54s |    -64% |
| invalid_signature_gossip_block                       |   135s  |     46s |    -66% |
|------------------------------------------------------|---------|---------|---------|
| TOTAL                                                |  1890s  |    797s |    -58% |
```


  


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

Co-Authored-By: Michael Sproul <michaelsproul@users.noreply.github.com>
2026-06-05 20:51:33 +00:00
Pawan Dhananjay
6698872f8a Improve error types for envelopes (#9414)
N/A


  Currently, we have `EnvelopeError` having a `ImportError` wrapping a `BlockError`. I feel this is extremely unintuitive because most of the envelope processing functions can simply return an `EnvelopeError` that makes sense in the function's context. It revealed further ugliness when implementing range sync in #9362

This PR does 2 main things:
1. Removes `ImportError(BlockError)` variant
2. Adds `EnvelopeError(EnvelopeError)` variant to a `BlockError`.

I feel this is more natural as there can be envelope errors when we try importing a Block but envelope errors can be contained to just envelope related errors.

The main blocker to doing this was `PayloadVerificationHandle` returning a `BlockError`. It uses a very small subset of `BlockError` which I extracted to its own error type which can be converted into both a BlockError and EnvelopeError.

This allows us to keep most of the pure envelope processing functions to just return EnvelopeErrors while we convert it to a `BlockError` only in import paths where we need to return a consolidated `BlockError`.


Co-Authored-By: Pawan Dhananjay <pawandhananjay@gmail.com>
2026-06-05 13:57:28 +00:00
Eitan Seri-Levi
da42d37456 Ensure PTC votes accurately reflect data availability (#9412)
Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-06-05 00:01:20 +00:00
Lion - dapplion
eeae8514b1 Remove unused spec field from AvailableBlock (#9411)
N/A


  Remove unused spec field from AvailableBlock


Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-06-04 19:14:32 +00:00
Lion - dapplion
d98de9f8dd Reject importing Gloas block until parent's payload is imported (#9382)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-06-04 15:53:05 +00:00
Eitan Seri-Levi
ad902d17c2 Fix tests 2026-06-03 10:07:09 +03:00
Eitan Seri-Levi
eb5a2952c1 Fix some tests 2026-06-02 14:29:26 +03:00
Eitan Seri-Levi
e3af316223 Impl 5302 2026-06-02 13:41:30 +03:00
Eitan Seri-Levi
1a2d55a88c impl 5281 gossip verification check 2026-06-02 13:04:49 +03:00
Eitan Seri-Levi
2b729482b3 5306 implemented
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 12:42:50 +03:00
Eitan Seri-Levi
1b929aadef Merge branch 'unstable' of https://github.com/sigp/lighthouse into gloas-remove-slashed-validators-from-propser-duties 2026-06-02 10:34:12 +03:00
Eitan Seri-Levi
3a3f6dafb1 Merge branch 'should_build_on_full_previous_slot' into gloas-remove-slashed-validators-from-propser-duties 2026-06-02 10:34:07 +03:00
Eitan Seri-Levi
7c0bbd5cac new test 2026-06-02 10:34:02 +03:00
Lion - dapplion
bbe7ead813 Move BlockProcessingResult match out of block lookups (#9327)
- https://github.com/sigp/lighthouse/pull/9155 remove the trait abstraction for processing block / blobs / columns / payloads

As a result we would have to duplicate x3 the big match on `BlockProcessingResult` we currently have in block lookups mod.rs

This PR moves the match of `BlockProcessingResult` to `sync_methods` to reduce the diff of https://github.com/sigp/lighthouse/pull/9155. There are some subtle changes that deserve dedicated attention, and may be drowned in the bigger diff of https://github.com/sigp/lighthouse/pull/9155 otherwise:

| Unstable | This PR / #9115 |
| - | - |
| Some error conditions immediately `Drop` the lookup (no retries). For example for "internal" errors like the BeaconChainError | Retries ALL errors 4 times. I believe assuming some errors are internal is risky as dropping a lookup drops all its children potentially forcing the node to resync a lot of blocks because of an internal timeout


  


Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-06-02 02:50:56 +00:00
Eitan Seri-Levi
9c8a577412 EIP=8045 impl with tests for the slashing cache 2026-06-02 01:07:23 +03:00
Lion - dapplion
b781227f1d Deprecate blob lookup sync (#9383)
- Extends https://github.com/sigp/lighthouse/pull/9126 to cover blob lookup sync

Lookup sync is only for unfinalized blocks, which will never contains blobs in any network we support.


  


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

Co-Authored-By: Eitan Seri-Levi <eserilev@ucsc.edu>
2026-06-01 12:10:47 +00:00
Lion - dapplion
cf259e7c50 Make proposer_score_boost non-optional in ChainSpec (#9386)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
2026-06-01 08:43:40 +00:00
Eitan Seri-Levi
dda45d3a06 Update should_build_on_full to match the updated spec plus new test case 2026-06-01 11:07:54 +03:00
Eitan Seri-Levi
bfc7a2bc65 Fix tests 2026-06-01 10:25:28 +03:00
Michael Sproul
74a5609ab1 Delete bogus InvalidBestNode error (#9364)
On Glamsterdam devnets we started seeing Lighthouse nodes unable to start with errors like:

> May 26 04:34:01.582 CRIT  Failed to start beacon node                   reason: "Unable to load fork choice from disk: ForkChoiceError(ProtoArrayStringError(\"find_head failed: InvalidBestNode(InvalidBestNodeInfo { current_slot: Slot(23550), start_root: 0x2c70b1641c29ec46360c99f9a8512f077862cbbc603e16f4a423007d210b0c5f, justified_checkpoint: Checkpoint { epoch: Epoch(712), root: 0x2c70b1641c29ec46360c99f9a8512f077862cbbc603e16f4a423007d210b0c5f }, finalized_checkpoint: Checkpoint { epoch: Epoch(710), root: 0xede5e0b09b51bdb5445ade3398e685bd193b845e0b0ffb827f0c3fec8277ea51 }, head_root: 0x2c70b1641c29ec46360c99f9a8512f077862cbbc603e16f4a423007d210b0c5f, head_justified_checkpoint: Checkpoint { epoch: Epoch(710), root: 0xede5e0b09b51bdb5445ade3398e685bd193b845e0b0ffb827f0c3fec8277ea51 }, head_finalized_checkpoint: Checkpoint { epoch: Epoch(709), root: 0xbb243eff616ff362c52b83113e7c536d0a68cb9ca3d6a1cb1055e732219d9736 } })\"))"

This error was the result of an overly-strict sanity check, based on assumptions that are not true under extreme network conditions.


  Completely remove the `InvalidBestNode` failure path: it is not compliant with the spec, and is actively harmful when triggered (it prevents Lighthouse from starting at all). The error was reachable in any situation where all leaf nodes of fork choice were ineligible to be the head. The payload invalidation tests show some examples of cases where this would happen, and the [newly-added regression test](9a5df1d982) shows a contrived case where it can happen on a Gloas network without _any_ slashings or invalid blocks. There are probably many more cases where it can happen.

We do not lose anything by removing it. The spec's implementation of `get_head` _always_ returns something (unless it crashes), and in these cases it is correct to return the starting node of the traversal: the justified checkpoint block. This is what we now do, and what the new test verifies.

I've also added some facilities to the harness for injecting attestations with fixed `payload_present` fields. @hopinheimer found himself needing something similar when messing with reorg tests, so I think these are probably useful. It might be possible to do without them by juggling the payload reveal timing in just the right way, but I think this approach is just way simpler.


Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
2026-06-01 00:46:58 +00:00
Eitan Seri-Levi
46b6c7519c make sure proposer cache stores by dep root 2026-05-31 22:04:52 +03:00
Eitan Seri-Levi
1e940fc78c Merge branch 'unstable' of https://github.com/sigp/lighthouse into gloas-head-block-number 2026-05-30 17:26:52 +03:00
Eitan Seri-Levi
8396dc87d0 Deprecate gossip blobs (#9126)
#9124

Deprecate unneeded pre-Fulu blob features

- blob gossip
- blob lookup sync
- engine getBlobsV1

Also deprecates some tests and cleans up production code paths

I think this is blocked until gnosis forks to fulu?


  


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>

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

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

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

Co-Authored-By: Michael Sproul <michaelsproul@users.noreply.github.com>
2026-05-29 02:59:23 +00:00
Eitan Seri-Levi
e9ae1d184b Merge branch 'unstable' of https://github.com/sigp/lighthouse into gloas-head-block-number 2026-05-28 12:42:13 +03:00
Eitan Seri-Levi
27a8246e95 fix 2026-05-25 17:24:07 +03:00
Eitan Seri-Levi
eead95f112 Use fork choice to ensure that the execution envelope snapshot is populated in most cases 2026-05-25 17:11:57 +03:00