mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 17:01:09 +00:00
Add methods param for RPC state_traceBlock (#9642)
* Add methods param for RPC state_traceBlock Signed-off-by: koushiro <koushiro.cqx@gmail.com> * rename event_values_filter arg Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Add some doc Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Add some doc Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Fix doc Signed-off-by: koushiro <koushiro.cqx@gmail.com> * format Signed-off-by: koushiro <koushiro.cqx@gmail.com>
This commit is contained in:
@@ -178,6 +178,7 @@ where
|
||||
block: Block::Hash,
|
||||
targets: Option<String>,
|
||||
storage_keys: Option<String>,
|
||||
methods: Option<String>,
|
||||
) -> FutureResult<sp_rpc::tracing::TraceBlockResponse>;
|
||||
}
|
||||
|
||||
@@ -413,12 +414,13 @@ where
|
||||
block: Block::Hash,
|
||||
targets: Option<String>,
|
||||
storage_keys: Option<String>,
|
||||
methods: Option<String>,
|
||||
) -> FutureResult<sp_rpc::tracing::TraceBlockResponse> {
|
||||
if let Err(err) = self.deny_unsafe.check_if_safe() {
|
||||
return async move { Err(err.into()) }.boxed()
|
||||
}
|
||||
|
||||
self.backend.trace_block(block, targets, storage_keys)
|
||||
self.backend.trace_block(block, targets, storage_keys, methods)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -581,12 +581,14 @@ where
|
||||
block: Block::Hash,
|
||||
targets: Option<String>,
|
||||
storage_keys: Option<String>,
|
||||
methods: Option<String>,
|
||||
) -> FutureResult<sp_rpc::tracing::TraceBlockResponse> {
|
||||
let block_executor = sc_tracing::block::BlockExecutor::new(
|
||||
self.client.clone(),
|
||||
block,
|
||||
targets,
|
||||
storage_keys,
|
||||
methods,
|
||||
self.rpc_max_payload,
|
||||
);
|
||||
let r = block_executor
|
||||
|
||||
@@ -449,6 +449,7 @@ where
|
||||
_block: Block::Hash,
|
||||
_targets: Option<String>,
|
||||
_storage_keys: Option<String>,
|
||||
_methods: Option<String>,
|
||||
) -> FutureResult<sp_rpc::tracing::TraceBlockResponse> {
|
||||
async move { Err(client_err(ClientError::NotAvailableOnLightClient)) }.boxed()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user