Skip to content

Commit 1206c08

Browse files
committed
tracing: Log to stderr, and drop timestamps
This matches bootc's setup (without the journal integration for now as we don't strictly need it). But specifically this fixes setting `RUST_LOG` and having that break the monitor-status JSON stream: #86 (comment) Signed-off-by: Colin Walters <[email protected]>
1 parent 9094214 commit 1206c08

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

crates/kit/src/main.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,11 @@ fn install_tracing() {
154154
use tracing_subscriber::prelude::*;
155155
use tracing_subscriber::EnvFilter;
156156

157-
let fmt_layer = fmt::layer().with_target(false).with_writer(std::io::stderr);
157+
let format = fmt::format().without_time().with_target(false).compact();
158+
159+
let fmt_layer = fmt::layer()
160+
.event_format(format)
161+
.with_writer(std::io::stderr);
158162
let filter_layer = EnvFilter::try_from_default_env()
159163
.or_else(|_| EnvFilter::try_new("info"))
160164
.unwrap();

0 commit comments

Comments
 (0)