Skip to content

Pseudo finalization endpoint #7103

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

eserilev
Copy link
Member

@eserilev eserilev commented Mar 10, 2025

Issue Addressed

This is a backport of:

For:

Proposed Changes

Introduce a new lighthouse endpoint that allows a user to force a pseudo finalization. This migrates data to the freezer db and prunes sidechains which may help reduce disk space issues on non finalized networks like Holesky

We also ban peers that send us blocks that conflict with the manually finalized checkpoint.

There were some CI fixes in #7071 that I tried including here

Co-authored with: @jimmygchen @pawanjay176 @michaelsproul

@eserilev eserilev requested a review from jxs as a code owner March 10, 2025 16:44
@eserilev eserilev added ready-for-review The code is ready for review v7.0.0-beta.clean Clean release post Holesky rescue v7.0.0 New release c. Q1 2025 HTTP-API labels Mar 10, 2025
@eserilev eserilev mentioned this pull request Mar 10, 2025
14 tasks
@michaelsproul
Copy link
Member

I've cherry-picked the split check fix from this PR:

It would be awesome if we could add a unit test for manual finalization that shows it working correctly, and the node continuing to work after achieving real finalization.

I think we could add such a test in beacon_node/beacon_chain/tests.

@eserilev
Copy link
Member Author

Added a test that

  • creates an un-finalized chain
  • pseudo finalizes + runs some checks
  • extends & finalizes the chain + runs some checks

Copy link
Member

@michaelsproul michaelsproul left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

I will add one more test case using epochs_per_migration to delay the split update, as I think that case is also interesting.

@michaelsproul
Copy link
Member

Regression test added and passing. Adding this to the queue.

@michaelsproul michaelsproul removed the ready-for-review The code is ready for review label Mar 18, 2025
@michaelsproul michaelsproul added the ready-for-merge This PR is ready to merge. label Mar 18, 2025
Copy link

mergify bot commented Mar 18, 2025

This pull request has been removed from the queue for the following reason: checks failed.

The merge conditions cannot be satisfied due to failing checks:

You may have to fix your CI before adding the pull request to the queue again.

If you want to requeue this pull request, you can post a @mergifyio requeue comment.

@mergify mergify bot merged commit 27aabe8 into sigp:release-v7.0.0 Mar 18, 2025
31 checks passed
mergify bot pushed a commit that referenced this pull request Mar 18, 2025
Backports:
- #7072

To:
- #7039

#7103 should be merged first


  This PR introduces an endpoint that allows users to manually trigger background compaction.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
HTTP-API ready-for-merge This PR is ready to merge. v7.0.0-beta.clean Clean release post Holesky rescue v7.0.0 New release c. Q1 2025
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants