Skip to content

Commit

Permalink
Enable Dev commands for RPC
Browse files Browse the repository at this point in the history
  • Loading branch information
karolk91 committed May 17, 2023
1 parent 01d19fe commit decd877
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions node/service/src/rpc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ use sc_client_api::{
use sc_consensus_manual_seal::rpc::{EngineCommand, ManualSeal, ManualSealApiServer};
use sc_network::NetworkService;
use sc_rpc::SubscriptionTaskExecutor;
use sc_rpc::dev::{Dev, DevApiServer};
use sc_rpc_api::DenyUnsafe;
use sc_service::TaskManager;
use sc_transaction_pool::{ChainApi, Pool};
Expand Down Expand Up @@ -172,6 +173,7 @@ where
BE::State: StateBackend<BlakeTwo256>,
BE::Blockchain: BlockchainBackend<Block>,
C: ProvideRuntimeApi<Block> + StorageProvider<Block, BE> + AuxStore,
C: sc_client_api::BlockBackend<Block>,
C: BlockchainEvents<Block>,
C: HeaderBackend<Block> + HeaderMetadata<Block, Error = BlockChainError> + 'static,
C: CallApiAt<Block>,
Expand Down Expand Up @@ -309,6 +311,8 @@ where
)?;
}

io.merge(Dev::new(Arc::clone(&client), deny_unsafe).into_rpc())?;

if let Some(tracing_config) = maybe_tracing_config {
if let Some(trace_filter_requester) = tracing_config.tracing_requesters.trace {
io.merge(
Expand Down

0 comments on commit decd877

Please sign in to comment.