diff --git a/CHANGELOG.md b/CHANGELOG.md index 0394dbfd699..ff34fa8dcbc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### API Breaking +* (module/core/02-client) [\#165](https://github.com/cosmos/ibc-go/pull/165) Remove GetFrozenHeight from the ClientState interface. * (modules) [\#166](https://github.com/cosmos/ibc-go/pull/166) Remove GetHeight from the misbehaviour interface. The `consensus_height` attribute has been removed from Misbehaviour events. * (modules) [\#162](https://github.com/cosmos/ibc-go/pull/162) Remove deprecated Handler types in core IBC and the ICS 20 transfer module. * (modules/core) [\#161](https://github.com/cosmos/ibc-go/pull/161) Remove Type(), Route(), GetSignBytes() from 02-client, 03-connection, and 04-channel messages. diff --git a/modules/core/exported/client.go b/modules/core/exported/client.go index 5879bc9fac2..77268b1b350 100644 --- a/modules/core/exported/client.go +++ b/modules/core/exported/client.go @@ -44,7 +44,6 @@ type ClientState interface { ClientType() string GetLatestHeight() Height - GetFrozenHeight() Height Validate() error GetProofSpecs() []*ics23.ProofSpec diff --git a/modules/light-clients/06-solomachine/types/client_state.go b/modules/light-clients/06-solomachine/types/client_state.go index 8a75749433f..fc6b69fffa7 100644 --- a/modules/light-clients/06-solomachine/types/client_state.go +++ b/modules/light-clients/06-solomachine/types/client_state.go @@ -57,13 +57,6 @@ func (cs ClientState) IsFrozen() bool { return cs.FrozenSequence != 0 } -// GetFrozenHeight returns the frozen sequence of the client. -// Return exported.Height to satisfy interface -// Revision number is always 0 for a solo-machine -func (cs ClientState) GetFrozenHeight() exported.Height { - return clienttypes.NewHeight(0, cs.FrozenSequence) -} - // GetProofSpecs returns nil proof specs since client state verification uses signatures. func (cs ClientState) GetProofSpecs() []*ics23.ProofSpec { return nil diff --git a/modules/light-clients/07-tendermint/types/client_state.go b/modules/light-clients/07-tendermint/types/client_state.go index 00d919aeaeb..4928a6819aa 100644 --- a/modules/light-clients/07-tendermint/types/client_state.go +++ b/modules/light-clients/07-tendermint/types/client_state.go @@ -88,12 +88,6 @@ func (cs ClientState) Status( return exported.Active } -// GetFrozenHeight returns the height at which client is frozen -// NOTE: FrozenHeight is zero if client is unfrozen -func (cs ClientState) GetFrozenHeight() exported.Height { - return cs.FrozenHeight -} - // IsExpired returns whether or not the client has passed the trusting period since the last // update (in which case no headers are considered valid). func (cs ClientState) IsExpired(latestTimestamp, now time.Time) bool { diff --git a/modules/light-clients/07-tendermint/types/proposal_handle_test.go b/modules/light-clients/07-tendermint/types/proposal_handle_test.go index 6208aec3165..ce09917853e 100644 --- a/modules/light-clients/07-tendermint/types/proposal_handle_test.go +++ b/modules/light-clients/07-tendermint/types/proposal_handle_test.go @@ -319,7 +319,7 @@ func (suite *TendermintTestSuite) TestCheckSubstituteAndUpdateState() { if tc.expPass { suite.Require().NoError(err) - suite.Require().Equal(clienttypes.ZeroHeight(), updatedClient.GetFrozenHeight()) + suite.Require().Equal(clienttypes.ZeroHeight(), updatedClient.(*types.ClientState).FrozenHeight) } else { suite.Require().Error(err) suite.Require().Nil(updatedClient) diff --git a/modules/light-clients/09-localhost/types/client_state.go b/modules/light-clients/09-localhost/types/client_state.go index 67da74d9c27..294ee4d9d48 100644 --- a/modules/light-clients/09-localhost/types/client_state.go +++ b/modules/light-clients/09-localhost/types/client_state.go @@ -49,11 +49,6 @@ func (cs ClientState) Status(_ sdk.Context, _ sdk.KVStore, _ codec.BinaryCodec, return exported.Active } -// GetFrozenHeight returns an uninitialized IBC Height. -func (cs ClientState) GetFrozenHeight() exported.Height { - return clienttypes.ZeroHeight() -} - // Validate performs a basic validation of the client state fields. func (cs ClientState) Validate() error { if strings.TrimSpace(cs.ChainId) == "" {