mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-03 00:31:50 +00:00
simulator: Write dependency logs to separate files (#7433)
This PR relates to: - https://github.com/sigp/lighthouse/pull/7199 - -> workspace_filter has been enabled (dependency logging has been disabled) - https://github.com/sigp/lighthouse/pull/7394 - -> file logging has been optionally enabled Building on these, this PR enables dependency logging for the simulators. The logs are written to separate files. The libp2p/discv5 logs: - are saved to the directory specified with `--log-dir` - respects the `RUST_LOG` environment variable for log level configuration
This commit is contained in:
@@ -37,7 +37,11 @@ pub fn construct_logger<E: EthSpec>(
|
||||
environment_builder.init_tracing(logger_config.clone(), logfile_prefix);
|
||||
|
||||
let libp2p_discv5_layer = if let Some(subcommand_name) = subcommand_name {
|
||||
if subcommand_name == "beacon_node" || subcommand_name == "boot_node" {
|
||||
if subcommand_name == "beacon_node"
|
||||
|| subcommand_name == "boot_node"
|
||||
|| subcommand_name == "basic-sim"
|
||||
|| subcommand_name == "fallback-sim"
|
||||
{
|
||||
if logger_config.max_log_size == 0 || logger_config.max_log_number == 0 {
|
||||
// User has explicitly disabled logging to file.
|
||||
None
|
||||
|
||||
Reference in New Issue
Block a user