Skip to content

Add EIP-7997 factory#170

Merged
YoshihitoAso merged 4 commits into
dev-2.8from
eip7997
Jul 9, 2026
Merged

Add EIP-7997 factory#170
YoshihitoAso merged 4 commits into
dev-2.8from
eip7997

Conversation

@YoshihitoAso

@YoshihitoAso YoshihitoAso commented Jul 8, 2026

Copy link
Copy Markdown
Member

close #164

This pull request introduces support for the Amsterdam hard fork (EIP-7997) in the codebase. The main focus is on implementing the EIP-7997 deterministic deployment factory, ensuring it is correctly inserted into the state at the Amsterdam fork transition.

Support for the Amsterdam hard fork and EIP-7997:

  • Added the AmsterdamBlock field to the ChainConfig struct, updated string representations, fork ordering checks, compatibility checks, and chain rule logic to recognize the Amsterdam fork.
  • Implemented ApplyEIP7997 in consensus/misc/eip7997.go to insert the deterministic deployment factory as specified by EIP-7997.
  • Updated chain generation (core/chain_makers.go) and block processing (core/state_processor.go) to apply EIP-7997 at the Amsterdam transition block.
  • Added a comprehensive test suite in core/eip7997_test.go to verify correct installation, code replacement, nonce preservation, factory deployment, and state transitions at the Amsterdam fork.

Other improvements:

  • Improved the STUN NAT test to use a local test server and verify the returned external IP address.

@github-actions github-actions Bot requested a review from purplesmoke05 July 8, 2026 01:38
@YoshihitoAso YoshihitoAso marked this pull request as ready for review July 8, 2026 01:38
@YoshihitoAso YoshihitoAso marked this pull request as draft July 8, 2026 02:05
# Conflicts:
#	params/config.go
@YoshihitoAso YoshihitoAso marked this pull request as ready for review July 8, 2026 06:37
Replace the empty STUN endpoint test with a local UDP STUN server that returns a Binding Success response.
@YoshihitoAso YoshihitoAso merged commit e0d1836 into dev-2.8 Jul 9, 2026
5 checks passed
@YoshihitoAso YoshihitoAso deleted the eip7997 branch July 9, 2026 09:03
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.

[FEATURE] EIP-7997: Deterministic Factory Contract

2 participants