mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 23:57:56 +00:00
This reverts commit 6eb2eb81c5.
This commit is contained in:
@@ -21,10 +21,9 @@
|
||||
use crate::arg_enums::Database;
|
||||
use crate::error::Result;
|
||||
use crate::{
|
||||
DatabaseParams, ImportParams, KeystoreParams, NetworkParams, NodeKeyParams,
|
||||
init_logger, DatabaseParams, ImportParams, KeystoreParams, NetworkParams, NodeKeyParams,
|
||||
OffchainWorkerParams, PruningParams, SharedParams, SubstrateCli,
|
||||
};
|
||||
use crate::logger::{LogRotationOpt, init_logger};
|
||||
use names::{Generator, Name};
|
||||
use sc_client_api::execution_extensions::ExecutionStrategies;
|
||||
use sc_service::config::{
|
||||
@@ -489,13 +488,6 @@ pub trait CliConfiguration: Sized {
|
||||
Ok(self.shared_params().log_filters().join(","))
|
||||
}
|
||||
|
||||
/// Get the log directory for logging.
|
||||
///
|
||||
/// By default this is retrieved from `SharedParams`.
|
||||
fn log_rotation_opt(&self) -> Result<LogRotationOpt> {
|
||||
Ok(self.shared_params().log_rotation_opt().clone())
|
||||
}
|
||||
|
||||
/// Initialize substrate. This must be done only once.
|
||||
///
|
||||
/// This method:
|
||||
@@ -505,12 +497,11 @@ pub trait CliConfiguration: Sized {
|
||||
/// 3. Initialize the logger
|
||||
fn init<C: SubstrateCli>(&self) -> Result<()> {
|
||||
let logger_pattern = self.log_filters()?;
|
||||
let log_rotation_opt = self.log_rotation_opt()?;
|
||||
|
||||
sp_panic_handler::set(&C::support_url(), &C::impl_version());
|
||||
|
||||
fdlimit::raise_fd_limit();
|
||||
init_logger(&logger_pattern, Some(log_rotation_opt))?;
|
||||
init_logger(&logger_pattern);
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user