Closed Akagi201 closed 1 week ago
The changes in this pull request involve a comprehensive overhaul of the block fetching logic within the Ethereum client interaction. The EthRPC
struct and its associated methods have been removed, leading to a new RawRpcClient
struct introduced in a new file. This new structure simplifies the connection to Ethereum nodes and modifies how block data is fetched and handled. Additionally, a new sender type for caching transaction signers is introduced, while an unused parameter in a test function is updated for clarity. A new JSON file for testing purposes is also added.
File Path | Change Summary |
---|---|
cmd/fetch-block/main.go | Removed EthRPC struct and methods; modified fetchMainnetBlocks to use rpcClient for block fetching. |
cmd/fetch-block/rpc.go | Introduced RawRpcClient struct with methods for connecting to Ethereum nodes and fetching block data. |
cmd/fetch-block/schema.go | Deleted file containing BlockInfo , TransactionInfo , and LogInfo structures. |
cmd/fetch-block/sender.go | Added senderFromServer type for caching sender addresses; includes methods for checking equality and retrieving addresses. |
stateless_executor_test.go | Updated function signature in generateMergeChain to indicate unused parameter. |
tests/data/optimism/127609270/block.json | Added new JSON file representing a blockchain block for testing purposes. |
rpcClient
are related to the modifications in the stateless_executor.go
file from PR #4, which also involves processing blocks in a new manner.stateless_executor.go
file in PR #12 reflect changes in how blocks are processed, which aligns with the main PR's overhaul of the block fetching logic and interaction with the Ethereum client.🐇 In the code where the blocks do flow,
A new RPC client helps us know,
With caching senders, swift and bright,
We fetch the data, day and night.
JSON files for tests, all in a row,
Hopping along, our changes in tow! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
New Features
Bug Fixes
Refactor