From bbad97572c1282c7dad75df3ff59442c34f7a73f Mon Sep 17 00:00:00 2001 From: Xiang Gao Date: Thu, 9 Jan 2025 12:21:59 -0800 Subject: [PATCH] Omit unsupported lines for OSS Summary: Fixing oss build failure: https://www.internalfb.com/sandcastle/workflow/3233584532457644543 Logger doesn't seem to work in oss.. skipping them Reviewed By: r39xu Differential Revision: D67985573 fbshipit-source-id: e2b98f2ac90fcdbf515539323757f9f2b5a1f2ce --- td_util/src/lib.rs | 2 +- td_util/src/supertd_events.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/td_util/src/lib.rs b/td_util/src/lib.rs index b4c99ef..d4c976e 100644 --- a/td_util/src/lib.rs +++ b/td_util/src/lib.rs @@ -23,7 +23,7 @@ pub mod qe; pub mod schedules; pub mod string; pub mod supertd_events; -pub mod supertd_events_logger; +// @oss-disable: pub mod supertd_events_logger; pub mod tracing; pub mod workflow_error; pub mod xplat; diff --git a/td_util/src/supertd_events.rs b/td_util/src/supertd_events.rs index b289200..5d5dcaa 100644 --- a/td_util/src/supertd_events.rs +++ b/td_util/src/supertd_events.rs @@ -73,7 +73,7 @@ pub enum Step { /// for writing. pub fn init(fb: fbinit::FacebookInit) -> ScubaClientGuard { if should_use_logger() { - crate::supertd_events_logger::init(fb); + // @oss-disable: crate::supertd_events_logger::init(fb); } else { let mut builder = match std::env::var_os("SUPERTD_SCUBA_LOGFILE") { None => ScubaSampleBuilder::new(fb, SCUBA_DATASET), @@ -123,7 +123,7 @@ pub fn init(fb: fbinit::FacebookInit) -> ScubaClientGuard { macro_rules! scuba { ( event: $event:ident $(, $key:ident : $value:expr)* $(,)? ) => { if $crate::supertd_events::should_use_logger() { - $crate::scuba_logger! {event: $event $(, $key : $value)*}; + // @oss-disable: $crate::scuba_logger! {event: $event $(, $key : $value)*}; } else { let mut builder = $crate::supertd_events::sample_builder(); builder.add("event", format!("{:?}", &$crate::supertd_events::Event::$event));