diff --git a/.changelog/unreleased/bug-fixes/403-fix-error-todos.md b/.changelog/unreleased/bug-fixes/403-fix-error-todos.md new file mode 100644 index 000000000..f165ca366 --- /dev/null +++ b/.changelog/unreleased/bug-fixes/403-fix-error-todos.md @@ -0,0 +1,3 @@ +- Mend error variant todo!()s wherever tendermint client calls the + "consensus_state" method + ([#403](https://github.com/cosmos/ibc-rs/issues/403)) diff --git a/crates/ibc/src/clients/ics07_tendermint/client_state.rs b/crates/ibc/src/clients/ics07_tendermint/client_state.rs index 0eb8f671e..f6508091b 100644 --- a/crates/ibc/src/clients/ics07_tendermint/client_state.rs +++ b/crates/ibc/src/clients/ics07_tendermint/client_state.rs @@ -751,7 +751,9 @@ impl Ics2ClientState for ClientState { ctx.consensus_state(&trusted_client_cons_state_path) .map_err(|e| match e { ContextError::ClientError(e) => e, - _ => todo!(), + _ => ClientError::Other { + description: e.to_string(), + }, })? .as_ref(), )?; @@ -815,7 +817,9 @@ impl Ics2ClientState for ClientState { .next_consensus_state(&client_cons_state_path) .map_err(|e| match e { ContextError::ClientError(e) => e, - _ => todo!(), + _ => ClientError::Other { + description: e.to_string(), + }, })? .as_ref() .map(|cs| downcast_tm_consensus_state(cs.as_ref())) @@ -842,7 +846,9 @@ impl Ics2ClientState for ClientState { .prev_consensus_state(&client_cons_state_path) .map_err(|e| match e { ContextError::ClientError(e) => e, - _ => todo!(), + _ => ClientError::Other { + description: e.to_string(), + }, })? .as_ref() .map(|cs| downcast_tm_consensus_state(cs.as_ref()))