fix: remove redundant fmt layer that outputs to hidden stdout

In production builds with windows_subsystem = "windows", stdout is suppressed.
The fmt::layer() was outputting to this hidden stdout, making logs invisible.

Now all tracing logs only go through TauriLogLayer to the debug console.

NOTE: There are still many println!/eprintln! calls throughout the codebase
that bypass tracing entirely. These should be gradually migrated to use
tracing::info!/tracing::error! macros for visibility in production builds.
This commit is contained in:
2026-02-06 23:00:25 -08:00
committed by Naomi Carrigan
parent 0b69de4a43
commit 4078b2b640
+2 -1
View File
@@ -63,9 +63,10 @@ pub fn run() {
.manage(discord_rpc.clone())
.setup(move |app| {
// Initialize tracing with custom layer that emits to frontend
// NOTE: We don't use fmt::layer() because in production builds with windows_subsystem = "windows",
// stdout is hidden. Instead, all logs go through TauriLogLayer to the debug console.
let tauri_layer = TauriLogLayer::new(app.handle().clone());
tracing_subscriber::registry()
.with(tracing_subscriber::fmt::layer())
.with(tauri_layer)
.init();