From 570eb5e1da541092f40bc626f7f06cae432589db Mon Sep 17 00:00:00 2001 From: danielSanchezQ <3danimanimal@gmail.com> Date: Tue, 3 Sep 2024 09:51:45 +0200 Subject: [PATCH] Short circuit failure on init error --- nomos-services/data-availability/sampling/src/lib.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/nomos-services/data-availability/sampling/src/lib.rs b/nomos-services/data-availability/sampling/src/lib.rs index 92cf659ad..9eea10d9c 100644 --- a/nomos-services/data-availability/sampling/src/lib.rs +++ b/nomos-services/data-availability/sampling/src/lib.rs @@ -98,6 +98,8 @@ where .start_sampling(blob_id, &sampling_subnets) .await { + // we can short circuit the failure from beginning + sampler.handle_sampling_error(blob_id).await; error!("Error sampling for BlobId: {blob_id:?}: {e}"); } }