MCPcopy Create free account
hub / github.com/hashintel/hash / setup_tracing

Function setup_tracing

libs/error-stack/tests/test_debug.rs:18–26  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

16
17#[cfg(feature = "spantrace")]
18fn setup_tracing() {
19 static ONCE: std::sync::Once = std::sync::Once::new();
20 ONCE.call_once(|| {
21 tracing::subscriber::set_global_default(
22 tracing_subscriber::Registry::default().with(ErrorLayer::default()),
23 )
24 .expect("Could not set tracing subscriber");
25 });
26}
27
28#[cfg(not(feature = "spantrace"))]
29const fn setup_tracing() {}

Callers 1

setupFunction · 0.85

Calls 3

defaultFunction · 0.50
expectMethod · 0.45
withMethod · 0.45

Tested by

no test coverage detected