Skip to content

Commit

Permalink
fix: remove addr validation for provider fee pool addr param (#1262)
Browse files Browse the repository at this point in the history
* fix: remove validation for provider chain address since we cannot validate it properly on consumer

* add changelog entry
  • Loading branch information
NeverHappened authored Sep 6, 2023
1 parent 8ec7bc5 commit b152c03
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Add an entry to the unreleased consumer section whenever merging a PR to main th
* (fix!) [#1146](https://github.com/cosmos/interchain-security/pull/1146) Proper deletion of pending packets.
* (feat!) [#1037](https://github.com/cosmos/interchain-security/pull/1037) Optimize pending packets storage on consumer, with migration.
* (feat) [#1164](https://github.com/cosmos/interchain-security/pull/1164) Introduce the gRPC query `/interchain_security/ccv/consumer/provider-info` and CLI command `interchain-security-cd q ccvconsumer provider-info` to retrieve provider info from the consumer chain.
* (fix!) [#1262](https://github.com/cosmos/interchain-security/pull/1262) Remove incorrect address validation on `ProviderFeePoolAddrStr` param

## v3.1.0

Expand Down
4 changes: 0 additions & 4 deletions x/ccv/consumer/types/params_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ func TestValidateParams(t *testing.T) {
"custom invalid params, dist transmission channel",
ccvtypes.NewParams(true, 5, "badchannel/", "", 5, 1005, "0.5", 1000, 24*21*time.Hour, "0.05", []string{"untrn"}, []string{"uatom"}), false,
},
{
"custom invalid params, provider fee pool addr string",
ccvtypes.NewParams(true, 5, "", "imabadaddress", 5, 1005, "0.5", 1000, 24*21*time.Hour, "0.05", []string{"untrn"}, []string{"uatom"}), false,
},
{
"custom invalid params, ccv timeout",
ccvtypes.NewParams(true, 5, "", "", -5, 1005, "0.5", 1000, 24*21*time.Hour, "0.05", []string{"untrn"}, []string{"uatom"}), false,
Expand Down
4 changes: 2 additions & 2 deletions x/ccv/types/params.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ func ValidateProviderFeePoolAddrStr(i interface{}) error {
if i == "" {
return nil
}
// Otherwise validate as usual for a bech32 address
return ValidateBech32(i)
// Cannot validate provider chain address on the consumer chain
return nil
}

func ValidateSoftOptOutThreshold(i interface{}) error {
Expand Down

0 comments on commit b152c03

Please sign in to comment.