-
Notifications
You must be signed in to change notification settings - Fork 19.6k
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
Stateless witness builder #29719
base: master
Are you sure you want to change the base?
Stateless witness builder #29719
Conversation
bb6e565
to
fce0ff4
Compare
… in a new test suite which executes blockchain tests, building and verifying stateless proofs for each test block.
fce0ff4
to
3bef048
Compare
…fication (this change doesn't fix any tests. it just seemed more intuitive to order the test code this way
…kip broken test case
…n nil access list)
This adds a new test suite |
Converted back to draft while I address remaining TODOs (parts of the code are confusing rn). |
BlockNums []uint64 | ||
BlockHashes []common.Hash | ||
Codes [][]byte | ||
CodeHashes []common.Hash |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can CodeHashes be omitted since they can(and should?) be recalculated from Codes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One case where the code wouldn't be necessary to provide or recompute is when an contract account is a target of EXTCODEHASH
but is never executed or accessed otherwise in the block.
However, I think that for simplicity of the witness format, we should only provide code and calculate/verify the hash as part of the verification.
Thanks for pointing this out!
Rebase of the witness builder on top of #29519 . Apparently I cannot re-open a closed pull request whose branch has been force pushed to.
This PR introduces necessary functionality to construct block witnesses. It doesn't include construction in block building, or cross-validation.
Only the blockchain test suite is modified with the introduction a stateless test. The test executes blockchain tests, constructing and verifying a proof for each block.