Skip to content

Commit

Permalink
Update AllowUpdate defaults to true (cosmos#455)
Browse files Browse the repository at this point in the history
* use sensible defaults

* update CHANGELOG
  • Loading branch information
colin-axner committed Mar 15, 2021
1 parent 82d0fe7 commit bca6e68
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 6 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,14 @@

### Relayer

* [\#455](https://github.com/cosmos/relayer/pull/455) Set default client parameter to allow governance to update the client if expiry or misbehaviour freezing occurs.

## v0.8.3

**2021/03/12**

### Relayer

* [\#453](https://github.com/cosmos/relayer/pull/453) Fix light block not found error on missing header
* [\#449](https://github.com/cosmos/relayer/pull/449) Close database connection even if error occurs on initialization
* [\#447](https://github.com/cosmos/relayer/pull/447) Add a light client database lock to prevent concurrency panics
Expand Down
4 changes: 2 additions & 2 deletions cmd/raw.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ $ %s tx raw clnt ibc-1 ibc-0 ibconeclient`, appName, appName)),
dstHeader.GetHeight().(clienttypes.Height),
commitmenttypes.GetSDKSpecs(),
relayer.DefaultUpgradePath,
false,
false,
relayer.AllowUpdateAfterExpiry,
relayer.AllowUpdateAfterMisbehaviour,
)

return sendAndPrint([]sdk.Msg{chains[src].CreateClient(
Expand Down
3 changes: 3 additions & 0 deletions relayer/chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ var (
rtyAtt = retry.Attempts(rtyAttNum)
rtyDel = retry.Delay(time.Millisecond * 400)
rtyErr = retry.LastErrorOnly(true)

AllowUpdateAfterExpiry = true
AllowUpdateAfterMisbehaviour = true
)

// Chain represents the necessary data for connecting to and indentifying a chain and its counterparites
Expand Down
8 changes: 4 additions & 4 deletions relayer/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ func (c *Chain) CreateClients(dst *Chain) (modified bool, err error) {
dstUpdateHeader.GetHeight().(clienttypes.Height),
commitmenttypes.GetSDKSpecs(),
DefaultUpgradePath,
false,
false,
AllowUpdateAfterExpiry,
AllowUpdateAfterMisbehaviour,
)

// Check if an identical light client already exists
Expand Down Expand Up @@ -113,8 +113,8 @@ func (c *Chain) CreateClients(dst *Chain) (modified bool, err error) {
srcUpdateHeader.GetHeight().(clienttypes.Height),
commitmenttypes.GetSDKSpecs(),
DefaultUpgradePath,
false,
false,
AllowUpdateAfterExpiry,
AllowUpdateAfterMisbehaviour,
)

// Check if an identical light client already exists
Expand Down

0 comments on commit bca6e68

Please sign in to comment.