From e056142d255081a1b5b055393df3c578f199509b Mon Sep 17 00:00:00 2001 From: Ava Howell Date: Mon, 10 Jun 2024 12:05:58 -0700 Subject: [PATCH] penumbra: filter out non-ibc events from event processing --- crates/relayer/src/chain/penumbra/chain.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/crates/relayer/src/chain/penumbra/chain.rs b/crates/relayer/src/chain/penumbra/chain.rs index 081b7dab36..30ffc29413 100644 --- a/crates/relayer/src/chain/penumbra/chain.rs +++ b/crates/relayer/src/chain/penumbra/chain.rs @@ -190,7 +190,13 @@ impl PenumbraChain { .tx_result .events .iter() - .map(|ev| IbcEventWithHeight::new(ibc_event_try_from_abci_event(ev).unwrap(), height)) + .filter_map(|ev| { + if let Ok(ibc_event) = ibc_event_try_from_abci_event(ev) { + Some(IbcEventWithHeight::new(ibc_event, height)) + } else { + None + } + }) .collect(); Ok(events)