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

Beacon root contract in dev mode and private chains #29539

Closed
s1na opened this issue Apr 15, 2024 · 5 comments · Fixed by #29655
Closed

Beacon root contract in dev mode and private chains #29539

s1na opened this issue Apr 15, 2024 · 5 comments · Fixed by #29655

Comments

@s1na
Copy link
Contributor

s1na commented Apr 15, 2024

EIP-4788 introduces a system contract which is deployed as a normal contract to the state. However it is required for networks which have the Cancun fork enabled. It is a bug when a dev chain or private chain with Cancun enabled is deployed and it is missing the beacon root contract.

For dev-mode, we should add the beacon root contract to the genesis alloc. As for private chain, IMO the least we should do is refuse geth init in case Cancun is enabled and the genesis alloc is missing the beacon root code at the correct address.

@holiman
Copy link
Contributor

holiman commented Apr 18, 2024

For dev-mode, we should add the beacon root contract to the genesis alloc.

I agree

the least we should do is refuse geth init in case Cancun is enabled and the genesis alloc is missing the beacon root code at the correct address.

Why?
If they want it: deploy it. If they don't fine, the system call will have zero side-effects.

@holiman holiman closed this as completed Apr 25, 2024
@holiman
Copy link
Contributor

holiman commented Apr 25, 2024

Sorry, I forgot there was still a task to do here (add the beacon root contract to the genesis alloc.)

@holiman holiman reopened this Apr 25, 2024
@hopinheimer
Copy link

Hi @holiman can I work on this?

@0xbeny
Copy link
Contributor

0xbeny commented Apr 25, 2024

WIP, The PR is finishing soon :)

Hi @holiman can I work on this?

@0xbeny
Copy link
Contributor

0xbeny commented Apr 25, 2024

Kindly find the implementation here: #29655

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants