-
Couldn't load subscription status.
- Fork 293
Update 1.10: London and Berlin forks #4953
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
base: dev
Are you sure you want to change the base?
Conversation
…ure proper dependency installation
… interface and add BLS12-381 precompile implementations
…simplify stack handling
…gToHash with additional test cases
…gToHash with additional test cases
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.
Pull Request Overview
This pull request implements support for London and Berlin Ethereum hard forks along with corresponding updates to the codebase for Harmony 1.10. The main focus is on updating EVM components and protocol parameters to align with these Ethereum improvements.
- Updates EVM context structures to use separate block and transaction contexts
- Adds new gas constants and protocol parameters for London/Berlin fork features
- Integrates blockchain state handling improvements and tracer updates
Reviewed Changes
Copilot reviewed 87 out of 93 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| rpc/harmony/tracer.go | Updates EVM context creation to use new block context API |
| rosetta/services/block.go | Updates callback signature for block context parameter |
| internal/registry/registry.go | Adds quorum decision support with getter/setter methods |
| internal/params/protocol_params.go | Adds new gas constants for Keccak operations and EIP-2200 storage |
| internal/params/config.go | Adds new rule flags for London/Berlin fork features |
| hmy/tracers/tracer.go | Updates stack handling to use uint256 and adds block context access |
| hmy/tracers/block_tracer_test.go | Fixes typo in error message and improves test output |
| hmy/tracers/block_tracer.go | Updates stack operations for uint256 compatibility |
| hmy/tracer.go | Major refactor to use separate block/transaction contexts |
| hmy/override_test.go | Updates test interfaces for new precompiled contract types |
| hmy/override.go | Updates override interfaces to use new contract types |
| hmy/hmy.go | Updates EVM creation to use separate contexts |
| core/vm/testdata/precompiles/* | Adds comprehensive test data for new precompiled contracts |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| var resultPiece string | ||
| if ac.err != nil { | ||
| resultPiece = fmt.Sprintf(`,"error":"Reverted","revert":"0x%x"`, ac.revert) | ||
| resultPiece = fmt.Sprintf(`,"error":"Reverted","revert":"%x"`, ac.revert) |
Copilot
AI
Oct 6, 2025
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.
Missing '0x' prefix in hexadecimal format string. Should be \"revert\":\"0x%x\" to maintain consistency with other hex-encoded values in the codebase.
| resultPiece = fmt.Sprintf(`,"error":"Reverted","revert":"%x"`, ac.revert) | |
| resultPiece = fmt.Sprintf(`,"error":"Reverted","revert":"0x%x"`, ac.revert) |
| func (d dummyPrecompile) Run(input []byte) ([]byte, error) { return nil, nil } | ||
| func (d dummyPrecompile) RequiredGas(input []byte) uint64 { return 0 } | ||
|
|
||
| // func (d dummyPrecompile) RequiredGas(input []byte) uint64 { return 0 } |
Copilot
AI
Oct 6, 2025
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.
Remove commented-out code. The old RequiredGas method signature is no longer needed since it has been replaced with the new EVM-aware version.
| // func (d dummyPrecompile) RequiredGas(input []byte) uint64 { return 0 } |
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.
Seems this fixed the segfault on the trace RPC calls
UPD: after normally run for 3 hours it crashed again
* Transient storage functionality * Commented code block in blockchain_test.go * Refactor state transition rules and remove commented-out Prepare method * Remove commented-out code block in chain_makers_test.go * Remove unnecessary parameter from ChainConfig.Rules calls in runtime.go * Refactor ActivePrecompiles function to use rules parameter instead of evm.chainRules * Refactor state transition preparation to use statedb.Prepare method
No description provided.