Skip to content

Add initial FOCIL implementation #30914

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

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open

Conversation

jihoonsong
Copy link

This PR implements initial FOCIL specifications. For more information, please refer to EIP-7805 and this PR.

Copy link

@ensi321 ensi321 left a comment

Choose a reason for hiding this comment

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

Pointing out Engine API has incorrect type for inclusion list. Current implementation expects base64 strings whereas the convention and the specs demand hex strings.

I suggest either define inclusion list type and its marshal type in beacon/engine/types.go and let gencodec handles the conversion similar to how ExecutableData is handled. Or manually marshal/unmarshal like how convertRequests handles incoming executionRequests in NewPayloadV4

@jihoonsong
Copy link
Author

I've addressed comments. Thank you very much for spotting out the issue and suggesting solutions! @ensi321

@jihoonsong jihoonsong force-pushed the focil branch 2 times, most recently from eb46040 to d5c724b Compare February 24, 2025 16:26
@jihoonsong
Copy link
Author

At the call with Geth team, there was feedback that eth/catalyst/api.go is not the right place to put validateInclusionListConstraints.

I haven't given much thought about where is the best location from the Geth codebase perspective, but from the spec perspective, the IL constraints should be checked after executing all transactions and before processing withdrawal requests. This is to prevent such situations that some withdrawal address become availble to cover some IL transaction that they couldn't. That missing IL transaction can reorg the block, which it shouldn't.

In current implementation, it would be between L106-L107 of core/state_processor.go.

As this would change the core part of Geth, I would wait until I can get more feedback from the Geth team before proceeding.

@jihoonsong
Copy link
Author

This PR has been updated to validate inclusion list inside state_processor.go. Following @fjl's feedback, it puts IL transactions inside block similar to ExecutionWitness. Additionally, now it validates IL transactions before passing using it.

@jihoonsong
Copy link
Author

This PR now has been updated to reflect the latest execution apis spec as of 2025-08-15. A Kurtosis config can access to the docker image via el_jmage: jihoonsg/geth-focil:1a1adcd

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.

7 participants