You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The add_default_keys() method sets the level field to use the short version version of log fields (e.g. ERRO for Error). If a user does not want to use the short field names, they must essentially re-implement add_default_keys() themselves.
That is,
let drain = slog_json::Json::default(std::io::stderr())
which also requires adding a (top level) dependency on the time crate.
I would like to be able to use the default keys, but be able to choose the strings used for the log levels. Example API:
let drain = slot_json::Json::new(std::io::stderr()).add_default_keys().with_log_levels(["off","critical","error","warn","info","debug","trace"]).build();
The text was updated successfully, but these errors were encountered:
The
add_default_keys()
method sets thelevel
field to use the short version version of log fields (e.g.ERRO
for Error). If a user does not want to use the short field names, they must essentially re-implementadd_default_keys()
themselves.That is,
now becomes
which also requires adding a (top level) dependency on the
time
crate.I would like to be able to use the default keys, but be able to choose the strings used for the log levels. Example API:
The text was updated successfully, but these errors were encountered: