ibc-rs
ibc-rs copied to clipboard
bug(core): client creation only checks if the client is frozen
Bug Summary
only non-frozen status is checked at client creation. we should just check if the client is active.
Details
https://github.com/cosmos/ibc-rs/blob/3b260e209ec6111c1dc2520d14f65fd605fdc834/ibc-core/ics02-client/src/handler/create_client.rs#L35
~should be refactored to if !status.is_active() { ... }.~
The status() is the status of the stored client state and its corresponding stored consensus state. So this doesn't include the provided ConsensusState. So its status needs to be checked locally.
IBC-go also checks for active status, instead of just non-frozen status.
Version
v0.50.0
hi @Farhad-Shabani i have a PR fix this issues, please verify it https://github.com/cosmos/ibc-rs/pull/1098
cc @rnbguy
Hi @rnbguy, I'd like to continue working on this issue. Could you please provide some guidance on how I should approach resolving it? I'd really appreciate any insights or suggestions you have. Thanks!
The status() is the status of the stored client state and its corresponding stored consensus state. So this doesn't include the provided ConsensusState. So its status needs to be checked locally.
Does this means we need to also store the ConsensusState to the validation context?
Hey @tropicaldog, thanks for your interest.
Does this means we need to also store the ConsensusState to the validation context?
We don't modify the store in the validation step. The Context is passed as an immutable reference in the validation calls. This is a convention in ibc-rs.
The way I see it, we may have to modify the status method to take the latest ConsensusState. Since this is an API-breaking change, we need to decide on this internally.