From 1e768d402012f6c7ce83fdd46c55f830ec31416a Mon Sep 17 00:00:00 2001 From: Danil Date: Mon, 2 Sep 2024 19:53:15 +0200 Subject: [PATCH] fix(config): Do not panic for observability config (#2639) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## What ❔ ## Why ❔ ## Checklist - [ ] PR title corresponds to the body of PR (we generate changelog entries from PRs). - [ ] Tests for the changes have been added / updated. - [ ] Documentation comments have been added / updated. - [ ] Code has been formatted via `zk fmt` and `zk lint`. Signed-off-by: Danil --- core/lib/protobuf_config/src/observability.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/core/lib/protobuf_config/src/observability.rs b/core/lib/protobuf_config/src/observability.rs index dcf87771b587..9a6c31f9223c 100644 --- a/core/lib/protobuf_config/src/observability.rs +++ b/core/lib/protobuf_config/src/observability.rs @@ -30,11 +30,7 @@ impl ProtoRepr for proto::Observability { sentry_url, sentry_environment, log_format: required(&self.log_format).context("log_format")?.clone(), - opentelemetry: self - .opentelemetry - .as_ref() - .map(|cfg| cfg.read().context("opentelemetry")) - .transpose()?, + opentelemetry: self.opentelemetry.as_ref().and_then(|cfg| cfg.read().ok()), log_directives: self.log_directives.clone(), }) }