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

client: ensure executed block does not get pruned if head=final FCU #3153

Merged
merged 4 commits into from Feb 20, 2024

Conversation

jochem-brouwer
Copy link
Member

This PR fixes:

./hive --client ethereumjs --sim ethereum/engine --sim.limit="engine-cancun/Valid NewPayload->ForkchoiceUpdated on Syncing Client

In this test, first FCU is called (after receiving the VALID newPayload):

  {
    headBlockHash: A
    safeBlockHash: A
    finalizedBlockHash: A
  }

We reply VALID

Then, FCU is called again, but now with:

  {
    headBlockHash: A
    safeBlockHash: B
    finalizedBlockHash: C
  }

B,C are known and VALID. However, before this PR we replied Syncing, since the pruneCachedBlocks will actually deleted the just-executed block A from the executed blocks. So if we FCU again (without newPayload which executes the block if this is possible) then it sees that the block is not executed (we thus start executing it) but reply early here with SYNCING.

Note: PR still draft because might fix other hive tests here too.

Copy link

codecov bot commented Nov 10, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (c0d5fc8) 87.93% compared to head (d698c72) 86.92%.

Additional details and impacted files

Impacted file tree graph

Flag Coverage Δ
block 88.34% <ø> (ø)
blockchain 91.61% <ø> (ø)
client 84.69% <0.00%> (?)
common 98.25% <ø> (ø)
devp2p 82.12% <ø> (ø)
ethash ∅ <ø> (∅)
evm 74.33% <ø> (ø)
genesis 99.98% <ø> (ø)
rlp ∅ <ø> (∅)
statemanager 77.02% <ø> (ø)
trie 89.29% <ø> (ø)
tx 95.45% <ø> (ø)
util 89.13% <ø> (ø)
vm 80.20% <ø> (ø)
wallet 88.35% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@jochem-brouwer jochem-brouwer marked this pull request as draft November 10, 2023 23:53
@holgerd77
Copy link
Member

@jochem-brouwer what is the status of this PR?

@jochem-brouwer
Copy link
Member Author

jochem-brouwer commented Feb 14, 2024

Ah right I intended this to include more hive fixes. We can use this PR to fix the Cancun failing hive tests, which I assigned myself to #3275.

@holgerd77
Copy link
Member

@jochem-brouwer ah, can we then please rather take this one in and open a new one instead of re-cycle?

This re-purposing of PRs is always a bit problematic.

I would then merge this in here.

@jochem-brouwer
Copy link
Member Author

Sure, that is fine!

@holgerd77 holgerd77 marked this pull request as ready for review February 14, 2024 12:32
@holgerd77
Copy link
Member

Updated this via UI

@holgerd77
Copy link
Member

Updated this via UI

Copy link
Member

@holgerd77 holgerd77 left a comment

Choose a reason for hiding this comment

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

LGTM

@holgerd77 holgerd77 merged commit 5fb1cef into master Feb 20, 2024
45 of 46 checks passed
@holgerd77 holgerd77 deleted the more-hive-fixes branch February 20, 2024 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants