Skip to content
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

chore(l1): remove total_difficulty #2052

Merged
merged 5 commits into from
Feb 25, 2025
Merged

Conversation

JulianVentura
Copy link
Contributor

Description

This PR fully removes total_difficulty field, as already done on #307, but later reverted on #566.
While doing so, it also removes the total_difficulty_check function, so it solves #790

Closes #790

@JulianVentura JulianVentura requested a review from a team as a code owner February 21, 2025 19:48
Copy link

github-actions bot commented Feb 21, 2025

| File                                                                       | Lines | Diff |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/blockchain/fork_choice.rs           | 139   | -40  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/api.rs                | 195   | -12  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/rlp.rs                | 88    | -2   |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/store.rs              | 1247  | -25  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/store_db/in_memory.rs | 481   | -35  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/store_db/libmdbx.rs   | 890   | -37  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/store_db/redb.rs      | 873   | -45  |
+----------------------------------------------------------------------------+-------+------+
| /home/runner/work/ethrex/ethrex/crates/storage/store/utils.rs              | 52    | -4   |
+----------------------------------------------------------------------------+-------+------+

Total lines added: 0
Total lines removed: 200
Total lines changed: 200

Copy link
Collaborator

@mpaulucci mpaulucci left a comment

Choose a reason for hiding this comment

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

Blocking this until we're sure it doesn't bring any regressions.

In mainnet this could be an issue since we have to deal with pre merge blocks.

Copy link
Collaborator

@mpaulucci mpaulucci left a comment

Choose a reason for hiding this comment

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

Switching the approach on this. Let's merge it, and if we find an issue, we can revert it.

@JulianVentura JulianVentura added this pull request to the merge queue Feb 25, 2025
Merged via the queue into main with commit 1f21274 Feb 25, 2025
23 checks passed
@JulianVentura JulianVentura deleted the fix/remove-total-difficulty branch February 25, 2025 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Evaluate the total difficulty check
3 participants