mirror of
https://gitlab.com/veilid/veilid.git
synced 2024-12-25 15:29:32 -05:00
tracing-oslog sucks and crashes
This commit is contained in:
parent
2b1dd49138
commit
440195c267
1
Cargo.lock
generated
1
Cargo.lock
generated
@ -5981,7 +5981,6 @@ dependencies = [
|
||||
"tokio-util",
|
||||
"tracing",
|
||||
"tracing-opentelemetry",
|
||||
"tracing-oslog",
|
||||
"tracing-subscriber",
|
||||
"veilid-core",
|
||||
]
|
||||
|
@ -74,4 +74,3 @@ android_log-sys = { version = "0.3.1", optional = true }
|
||||
# Dependencies for iOS builds only
|
||||
[target.'cfg(target_os = "ios")'.dependencies]
|
||||
oslog = { version = "0.2.0", default-features = false, optional = true }
|
||||
tracing-oslog = { version = "0.1.2" }
|
||||
|
@ -235,10 +235,12 @@ pub extern "C" fn initialize_veilid_core(platform_config: FfiStr) {
|
||||
filters.insert("terminal", filter);
|
||||
layers.push(layer.boxed());
|
||||
} else if #[cfg(target_os = "ios")] {
|
||||
use tracing_oslog::OsLogger;
|
||||
let filter =
|
||||
veilid_core::VeilidLayerFilter::new(platform_config.logging.terminal.level, &platform_config.logging.terminal.ignore_log_targets);
|
||||
let layer = OsLogger::new("com.veilid.veilid-flutter", "default")
|
||||
let layer = tracing_subscriber::fmt::Layer::new()
|
||||
.compact()
|
||||
.with_ansi(false)
|
||||
.with_writer(std::io::stdout)
|
||||
.with_filter(filter.clone());
|
||||
filters.insert("terminal", filter);
|
||||
layers.push(layer.boxed());
|
||||
|
Loading…
Reference in New Issue
Block a user