Skip to content

Commit

Permalink
feat: detach client state verifier enabling users to implement custom…
Browse files Browse the repository at this point in the history
… verifier (#1097)

* Add empty Verifier trait stub

* Remove verifier field from ClientState

* Implement TmVerifier for ClientState

* Move ClientState trait methods into being standalone functions

* Fix some typos

* Remove unused fn param on update_client_state_on_misbehaviour

* Call standalone functions in trait implementations

* Move update_client and misbehaviour methods out of the ClientState impl

* Define `DefaultVerifier` type

* Replace `ClientState` fn params with `ClientStateType`

* Migrate ClientState::initialise function param back to ClientState

* Change some associated type constraints

* Change From<TmConsensusState> constraint to From<ConsensusStateType>

* impl From<ConsensusStateType> for AnyConsensusState

* impl some Displays when use-substrate feature is not enabled

* Remove unused displaydoc use statement

* Revert "Remove unused displaydoc use statement"

This reverts commit 92e8e36.

* Revert "impl some Displays when use-substrate feature is not enabled"

This reverts commit 083399c.

* Add docstring comment illustrating how to implement a custom verifier

* Ad unclog entry

* fix: set NIGHTLY_VERSION=nightly-2024-02-24

* imp: reorganize client_state.rs + clean-ups

* nit

---------

Co-authored-by: Farhad Shabani <[email protected]>
  • Loading branch information
seanchen1991 and Farhad-Shabani authored Feb 29, 2024
1 parent e048e34 commit 6dd3c64
Show file tree
Hide file tree
Showing 15 changed files with 1,131 additions and 790 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- [ibc-client-tendermint] Detach client state verifier such that users have a
way to utilize custom verifiers
([\#1097](https://github.com/cosmos/ibc-rs/pull/1097))
2 changes: 1 addition & 1 deletion .github/workflows/no-std.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
toolchain: nightly-2024-02-24
target: wasm32-unknown-unknown
override: true
- run: |
Expand Down
2 changes: 1 addition & 1 deletion ci/no-std-check/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
NIGHTLY_VERSION=nightly
NIGHTLY_VERSION=nightly-2024-02-24

.DEFAULT_GOAL := help

Expand Down
3 changes: 2 additions & 1 deletion ibc-clients/ics07-tendermint/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ all-features = true

[dependencies]
# external dependencies
serde = { workspace = true, optional = true }
derive_more = { workspace = true }
serde = { workspace = true, optional = true }

# ibc dependencies
ibc-client-tendermint-types = { workspace = true }
Expand Down
Loading

0 comments on commit 6dd3c64

Please sign in to comment.