Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions app/buck2_env/src/soft_error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,8 @@ pub fn handle_soft_error(
ALL_SOFT_ERROR_COUNTERS.lock().unwrap().push(count);
});

let quiet = options.quiet;

// We want to limit each error to appearing at most 10 times in a build (no point spamming people)
if count.fetch_add(1, Ordering::SeqCst) < 10 {
if let Some(handler) = HANDLER.get() {
Expand All @@ -220,9 +222,10 @@ pub fn handle_soft_error(

// @oss-disable: let is_open_source = false;
let is_open_source = true; // @oss-enable
if is_open_source {
if is_open_source && !quiet {
// We don't log these, and we have no legacy users, and they might not upgrade that often,
// so lets just break open source things immediately.
// so lets just break open source things immediately. We only do this when quiet = False
// because we typically use quiet = True for logging purposes.
return Err(err);
}

Expand Down
Loading