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

Replace async trait with ->impl Future #6791

Merged
merged 4 commits into from
Feb 26, 2024

Conversation

AbnerZheng
Copy link
Contributor

Related to #6657
Remove async-trait as dependency from crate transaction-pool, rpc-api.

The remaining usage towards async-trait are mostly related to rpc server implementation based on jsonrpsee, and jsonrpsee is working on migrating to native async trait.

@@ -5,7 +5,6 @@ use reth_rpc_types::{NodeInfo, PeerInfo};
/// Admin namespace rpc interface that gives access to several non-standard RPC methods.
#[cfg_attr(not(feature = "client"), rpc(server, namespace = "admin"))]
#[cfg_attr(feature = "client", rpc(server, client, namespace = "admin"))]
#[async_trait::async_trait]
pub trait AdminApi {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

#[async_trait::async_trait] is not needed here since the macro rpc already uses #[async_trait::async_trait]

@mattsse mattsse added this pull request to the merge queue Feb 26, 2024
@mattsse mattsse added the C-debt Refactor of code section that is hard to understand or maintain label Feb 26, 2024
Merged via the queue into paradigmxyz:main with commit 323bad2 Feb 26, 2024
30 checks passed
@AbnerZheng AbnerZheng deleted the replace-async-trait-in-tx-pool branch February 26, 2024 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-debt Refactor of code section that is hard to understand or maintain
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants