Commit 7c9d6da
committed
fix: emit migration warning before tracing subscriber is initialised
Config::load fires before init_logging in the normal serve path, so the
tracing::warn! in load_json_and_migrate was silently dropped - the
subscriber didn't exist yet. Fix by calling init_logging("warn") before
Config::load so the migration notice is visible. The second init_logging
call with config.log_level is a harmless no-op (try_init semantics);
RUST_LOG is still respected because EnvFilter checks the env var first,
and "warn" is already the compiled default for log_level anyway
this adds no overhead, the subscriber is registered once; the second call is a no-op.1 parent d44c2fd commit 7c9d6da
1 file changed
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
201 | 201 | | |
202 | 202 | | |
203 | 203 | | |
| 204 | + | |
204 | 205 | | |
205 | 206 | | |
206 | 207 | | |
| |||
0 commit comments