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

feat: refactoring reth_methods() to return multiple Methods #1284

Merged
merged 1 commit into from
Feb 11, 2023

Conversation

leruaa
Copy link
Contributor

@leruaa leruaa commented Feb 11, 2023

Closes #1268

@leruaa leruaa requested a review from gakonst as a code owner February 11, 2023 08:36
@codecov-commenter
Copy link

Codecov Report

Merging #1284 (7930157) into main (3d60a24) will decrease coverage by 0.21%.
The diff coverage is 77.27%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

@@            Coverage Diff             @@
##             main    #1284      +/-   ##
==========================================
- Coverage   76.39%   76.18%   -0.21%     
==========================================
  Files         343      347       +4     
  Lines       38426    38487      +61     
==========================================
- Hits        29354    29323      -31     
- Misses       9072     9164      +92     
Flag Coverage Δ
unit-tests 76.18% <77.27%> (-0.21%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
crates/rpc/rpc-builder/src/lib.rs 71.01% <77.27%> (+2.76%) ⬆️
crates/storage/db/src/abstraction/database.rs 80.00% <0.00%> (-20.00%) ⬇️
crates/storage/db/src/tables/models/blocks.rs 76.54% <0.00%> (-11.12%) ⬇️
...tes/storage/provider/src/providers/state/latest.rs 58.06% <0.00%> (-8.61%) ⬇️
...rates/storage/db/src/implementation/mdbx/cursor.rs 74.64% <0.00%> (-7.18%) ⬇️
crates/transaction-pool/src/test_utils/mock.rs 62.05% <0.00%> (-6.74%) ⬇️
...storage/provider/src/providers/state/historical.rs 91.89% <0.00%> (-1.69%) ⬇️
crates/primitives/src/header.rs 93.18% <0.00%> (-0.98%) ⬇️
crates/net/eth-wire/src/capability.rs 59.43% <0.00%> (-0.95%) ⬇️
crates/storage/provider/src/utils.rs 95.83% <0.00%> (-0.89%) ⬇️
... and 38 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

lgtm

&mut self,
namespaces: impl Iterator<Item = RethRpcModule>,
) -> Vec<Methods> {
let eth_api = self.eth_api();
Copy link
Collaborator

Choose a reason for hiding this comment

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

this will always create an EthApi instance even though it might not be used.

It will not register it, if not required.
This is fine and perhaps even comes in handy when we need to returns the EthAPI somehow

@mattsse mattsse added C-enhancement New feature or request A-rpc Related to the RPC implementation labels Feb 11, 2023
@mattsse mattsse merged commit afb6671 into paradigmxyz:main Feb 11, 2023
@leruaa leruaa deleted the refactoring_reth_methods branch July 12, 2024 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rpc Related to the RPC implementation C-enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Install missing eth_ handlers if eth module is selected
4 participants