fix(client): default the log filter when RUST_LOG is unset

This commit is contained in:
Serkyo 2026-08-02 03:18:49 +02:00
parent 4153a0e9a0
commit 3f1640ce09

View file

@ -423,8 +423,12 @@ impl ApplicationHandler for App {
} }
fn main() -> Result<()> { fn main() -> Result<()> {
// An unset `RUST_LOG` leaves `from_default_env` with no directives, which discards every event including the statistics panel. A fallback keeps the client audible out of the box while `RUST_LOG` still overrides it.
tracing_subscriber::fmt() tracing_subscriber::fmt()
.with_env_filter(tracing_subscriber::EnvFilter::from_default_env()) .with_env_filter(
tracing_subscriber::EnvFilter::try_from_default_env()
.unwrap_or_else(|_| tracing_subscriber::EnvFilter::new("info")),
)
.init(); .init();
info!("Starting Synvael client"); info!("Starting Synvael client");