Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deps!: support cosmos-sdk-v45-ics-lsm integration #1120

Merged
merged 19 commits into from
Aug 16, 2023

Conversation

MSalopek
Copy link
Contributor

@MSalopek MSalopek commented Jul 7, 2023

Description

Closes: #1183

Adapting ICS to support sdk-v45 with LSM support.

Mainly concerns about adapting the staking keeper interface and doing QA

Changes are state breaking.

Instructions

When cosmos/cosmos-sdk#16747 is merged and cosmos-sdk v0.45.16-lsm-ics release is cut perform the following actions:

  1. update go.mod
    Remove the github.com/cosmos/cosmos-sdk => github.com/iqlusioninc/cosmos-sdk v0.45.17-0.20230803192832-aab739edf2ca replace directive and use the correct cosmos-sdk version

  2. run go mod tidy

  3. commit the changes

  4. cut ICS v2.1.0


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • Included the correct type prefix in the PR title
  • Targeted the correct branch (see PR Targeting)
  • Provided a link to the relevant issue or specification
  • Reviewed "Files changed" and left comments if necessary
  • Confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • Confirmed the correct type prefix in the PR title
  • Confirmed all author checklist items have been addressed
  • Confirmed that this PR does not change production code

@MSalopek MSalopek self-assigned this Jul 7, 2023
@MSalopek
Copy link
Contributor Author

The issue below happens because of changes in cosmos-sdk logic regarding token shares.

simulate.go:299: error on block  26/100, operation (639/773) from x/authz:
        fee is not a subset of required fees; got 4304869cosmosvaloper15juvg98z0e67u5hu9jafp00dlsk08uqfqdnch9/1, required: 0stake: insufficient fee [/Users/msalopek/informal/gaia/x/globalfee/ante/fee.go:103]
        Comment: unable to deliver tx
--- FAIL: TestAppStateDeterminism (7.95s)

This is the function that introduces the change that breaks the x/globalfee module AnteHandle

// x/staking/types/tokenize_share_record.go [inqlusion's fork]
func (r TokenizeShareRecord) GetShareTokenDenom() string {
	return fmt.Sprintf("%s/%s", strings.ToLower(r.Validator), strconv.Itoa(int(r.Id)))
}

@MSalopek
Copy link
Contributor Author

Starting the simulation from time Fri Jul 23 13:55:17 UTC 9948 (unixtime 251778981317)
Simulating... block 89/100, operation 0/350. simulation halted due to panic on block 89
Logs to writing to /Users/msalopek/.simapp/simulations/2023-07-13_18:29:09.log
--- FAIL: TestAppStateDeterminism (47.18s)
panic: division by zero [recovered]
	panic: division by zero [recovered]
	panic: division by zero

goroutine 37 [running]:
testing.tRunner.func1.2({0x101bf2ae0, 0x101e6c820})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1526 +0x1c8
testing.tRunner.func1()
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1529 +0x384
panic({0x101bf2ae0, 0x101e6c820})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/runtime/panic.go:884 +0x204
github.com/cosmos/cosmos-sdk/x/simulation.SimulateFromSeed.func2()
	/Users/msalopek/inqlusion/cosmos-sdk/x/simulation/simulate.go:146 +0xc8
panic({0x101bf2ae0, 0x101e6c820})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/runtime/panic.go:890 +0x258
math/big.nat.div({0x0?, 0x10314c5b8?, 0x20?}, {0x0?, 0x140131086e0?, 0x0?}, {0x140108f36c0?, 0x100a1f538?, 0x20?}, {0x0?, ...})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/math/big/natdiv.go:520 +0x260
math/big.(*Int).Quo(0x140131086e0, 0x1400261d058, 0x14013108640)
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/math/big/int.go:260 +0x64
github.com/cosmos/cosmos-sdk/types.Dec.Quo({0x101e72890?}, {0x0?})
	/Users/msalopek/inqlusion/cosmos-sdk/types/decimal.go:299 +0x74
github.com/cosmos/cosmos-sdk/x/staking/simulation.SimulateMsgTokenizeShares.func1(_, _, {{0x101e85f00, 0x1400011e018}, {0x101e90838, 0x1400f6632c0}, {{0x0, 0x0}, {0x1012ecb2e, 0x8}, ...}, ...}, ...)
	/Users/msalopek/inqlusion/cosmos-sdk/x/staking/simulation/operations.go:789 +0x734
github.com/cosmos/cosmos-sdk/x/simulation.createBlockSimulator.func1(_, _, {{0x101e85f00, 0x1400011e018}, {0x101e90838, 0x1400f6632c0}, {{0x0, 0x0}, {0x1012ecb2e, 0x8}, ...}, ...}, ...)
	/Users/msalopek/inqlusion/cosmos-sdk/x/simulation/simulate.go:290 +0x3ac
github.com/cosmos/cosmos-sdk/x/simulation.SimulateFromSeed({0x101e96440?, 0x14000ca0ea0}, {0x101e70360?, 0x14000126008}, 0x1?, 0x3d?, 0x101e658b0, {0x1400a4d4a00, 0x18, 0x20}, ...)
	/Users/msalopek/inqlusion/cosmos-sdk/x/simulation/simulate.go:182 +0x10e8
github.com/cosmos/gaia/v11/app_test.TestAppStateDeterminism(0x14000ca0ea0)
	/Users/msalopek/informal/gaia/app/sim_test.go:117 +0x750
testing.tRunner(0x14000ca0ea0, 0x101e66180)
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1576 +0x10c
created by testing.(*T).Run
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1629 +0x368
FAIL	github.com/cosmos/gaia/v11/app	47.622s
FAIL
make: *** [test-sim-nondeterminism] Error 1

@MSalopek MSalopek changed the title tests: check cosmos-sdk-v45-ics-lsm integration deps!: check cosmos-sdk-v45-ics-lsm integration Aug 3, 2023
@MSalopek MSalopek added scope: cosmos-sdk Integration with Cosmos SDK ccv-core labels Aug 3, 2023
@MSalopek
Copy link
Contributor Author

MSalopek commented Aug 3, 2023

Errs in non-determinism tests*

--- FAIL: TestAppStateDeterminism (50.88s)
panic: division by zero [recovered]
	panic: division by zero [recovered]
	panic: division by zero

goroutine 36 [running]:
testing.tRunner.func1.2({0x106222b00, 0x10649c920})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1526 +0x1c8
testing.tRunner.func1()
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1529 +0x384
panic({0x106222b00, 0x10649c920})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/runtime/panic.go:884 +0x204
github.com/cosmos/cosmos-sdk/x/simulation.SimulateFromSeed.func2()
	/Users/msalopek/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/simulation/simulate.go:146 +0xc8
panic({0x106222b00, 0x10649c920})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/runtime/panic.go:890 +0x258
math/big.nat.div({0x0?, 0x107790a68?, 0x20?}, {0x0?, 0x1401acbc0a0?, 0x14000d32b60?}, {0x1401acb89c0?, 0x105041b08?, 0x20?}, {0x0?, ...})
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/math/big/natdiv.go:520 +0x260
math/big.(*Int).Quo(0x1401acbc0a0, 0x14003da1058, 0x1401acbc000)
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/math/big/int.go:260 +0x64
github.com/cosmos/cosmos-sdk/types.Dec.Quo({0x1064a2990?}, {0x0?})
	/Users/msalopek/go/pkg/mod/github.com/iqlusioninc/[email protected]/types/decimal.go:299 +0x74
github.com/cosmos/cosmos-sdk/x/staking/simulation.SimulateMsgTokenizeShares.func1(_, _, {{0x1064b5fd0, 0x140001a0018}, {0x1064c0918, 0x1400f663580}, {{0x0, 0x0}, {0x105918cc9, 0x8}, ...}, ...}, ...)
	/Users/msalopek/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/staking/simulation/operations.go:789 +0x734
github.com/cosmos/cosmos-sdk/x/simulation.createBlockSimulator.func1(_, _, {{0x1064b5fd0, 0x140001a0018}, {0x1064c0918, 0x1400f663580}, {{0x0, 0x0}, {0x105918cc9, 0x8}, ...}, ...}, ...)
	/Users/msalopek/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/simulation/simulate.go:290 +0x3ac
github.com/cosmos/cosmos-sdk/x/simulation.SimulateFromSeed({0x1064c6500?, 0x14000d329c0}, {0x1064a0460?, 0x140001a8008}, 0x1?, 0x3d?, 0x1064959e0, {0x140085ed400, 0x23, 0x40}, ...)
	/Users/msalopek/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/simulation/simulate.go:182 +0x10e8
github.com/cosmos/gaia/v11/app_test.TestAppStateDeterminism(0x14000d329c0)
	/Users/msalopek/informal/gaia/app/sim_test.go:117 +0x750
testing.tRunner(0x14000d329c0, 0x1064962b0)
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1576 +0x10c
created by testing.(*T).Run
	/opt/homebrew/Cellar/go/1.20.5/libexec/src/testing/testing.go:1629 +0x368
FAIL	github.com/cosmos/gaia/v11/app	51.446s
FAIL
make: *** [test-sim-nondeterminism] Error 1
simulate.go:299: error on block  26/100, operation (639/773) from x/authz:
        fee is not a subset of required fees; got 4304869cosmosvaloper15juvg98z0e67u5hu9jafp00dlsk08uqfqdnch9/1, required: 0stake: insufficient fee [/Users/msalopek/informal/gaia/x/globalfee/ante/fee.go:103]
        Comment: unable to deliver tx
--- FAIL: TestAppStateDeterminism (7.95s)

Some issues with e2e tests (sovereign -> consumer)

[signal SIGSEGV: segmentation violation code=0x1 addr=0x10 pc=0xcc87d4]

goroutine 1 [running]:
math/big.(*Int).Sign(...)
	/usr/local/go/src/math/big/int.go:38
github.com/cosmos/cosmos-sdk/types.Dec.IsNegative(...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/types/decimal.go:211
github.com/cosmos/cosmos-sdk/x/staking/types.validateValidatorBondFactor({0x160bc20?, 0x0?})
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/staking/types/params.go:260 +0x44
github.com/cosmos/cosmos-sdk/x/params/types.Subspace.SetParamSet({{_, _}, _, {_, _}, {_, _}, {_, _, _}, ...}, ...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/params/types/subspace.go:245 +0x1a8
github.com/cosmos/cosmos-sdk/x/staking/keeper.Keeper.SetParams(...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/staking/keeper/params.go:84
github.com/cosmos/cosmos-sdk/x/staking.InitGenesis({{0x1efc868, 0x4000050080}, {0x1f0a150, 0x400013d080}, {{0x0, 0x0}, {0x4000df4d19, 0x5}, 0x0, {0x3b832133, ...}, ...}, ...}, ...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/staking/genesis.go:35 +0x1ec
github.com/cosmos/cosmos-sdk/x/staking.AppModule.InitGenesis({{{0x1f10398, 0x4000fff5b0}}, {{0x1ee88f8, 0x4000c39e40}, {0x1f0a970, 0x4000fff5b0}, {0x1f00320, 0x40001525a0}, {0xffff5d1b9f40, 0x4000145e40}, ...}, ...}, ...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/x/staking/module.go:153 +0xdc
github.com/cosmos/cosmos-sdk/types/module.(*Manager).InitGenesis(_, {{0x1efc868, 0x4000050080}, {0x1f0a150, 0x400013d080}, {{0x0, 0x0}, {0x4000df4d19, 0x5}, 0x0, ...}, ...}, ...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/types/module/module.go:327 +0x1ec
github.com/cosmos/interchain-security/v2/app/sovereign.(*App).InitChainer(_, {{0x1efc868, 0x4000050080}, {0x1f0a150, 0x400013d080}, {{0x0, 0x0}, {0x4000df4d19, 0x5}, 0x0, ...}, ...}, ...)
	/interchain-security/app/sovereign/app.go:625 +0x1d0
github.com/cosmos/cosmos-sdk/baseapp.(*BaseApp).InitChain(0x4000b516c0, {{0x3b832133, 0xedc1a47a9, 0x0}, {0x4000df4d19, 0x5}, 0x4000058680, {0x2d483d8, 0x0, 0x0}, ...})
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/baseapp/abci.go:63 +0x344
github.com/tendermint/tendermint/abci/client.(*localClient).InitChainSync(0x4000da1440, {{0x3b832133, 0xedc1a47a9, 0x0}, {0x4000df4d19, 0x5}, 0x4000058680, {0x2d483d8, 0x0, 0x0}, ...})
	/go/pkg/mod/github.com/cometbft/[email protected]/abci/client/local_client.go:272 +0x18c
github.com/tendermint/tendermint/proxy.(*appConnConsensus).InitChainSync(0x4000d08de0?, {{0x3b832133, 0xedc1a47a9, 0x0}, {0x4000df4d19, 0x5}, 0x4000058680, {0x2d483d8, 0x0, 0x0}, ...})
	/go/pkg/mod/github.com/cometbft/[email protected]/proxy/app_conn.go:77 +0x80
github.com/tendermint/tendermint/consensus.(*Handshaker).ReplayBlocks(_, {{{0xb, 0x0}, {0x16307ee, 0x7}}, {0x4000df4d19, 0x5}, 0x1, 0x0, {{0x0, ...}, ...}, ...}, ...)
	/go/pkg/mod/github.com/cometbft/[email protected]/consensus/replay.go:319 +0xa9c
github.com/tendermint/tendermint/consensus.(*Handshaker).Handshake(0x4000ca3e30, {0x1f0d698, 0x4000570c30})
	/go/pkg/mod/github.com/cometbft/[email protected]/consensus/replay.go:268 +0x3a0
github.com/tendermint/tendermint/node.doHandshake({_, _}, {{{0xb, 0x0}, {0x16307ee, 0x7}}, {0x4000df4d19, 0x5}, 0x1, 0x0, ...}, ...)
	/go/pkg/mod/github.com/cometbft/[email protected]/node/node.go:329 +0x11c
github.com/tendermint/tendermint/node.NewNode(0x40001768c0, {0x1ef9160, 0x4000573900}, 0x4000c4dea0, {0x1ee3780, 0x4000b02570}, 0x1ee3240?, 0x40005781a0?, 0x4000c820b0, {0x1efd5f8, ...}, ...)
	/go/pkg/mod/github.com/cometbft/[email protected]/node/node.go:779 +0x3f0
github.com/cosmos/cosmos-sdk/server.startInProcess(_, {{0x0, 0x0, 0x0}, {0x1f19058, 0x4000d9aa50}, {0x0, 0x0}, {0x1f01ed8, 0x4000fff5b0}, ...}, ...)
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/server/start.go:280 +0x608
github.com/cosmos/cosmos-sdk/server.StartCmd.func2(0x4000ae7800?, {0x40005708f0?, 0x0?, 0xd?})
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/server/start.go:128 +0xf0
github.com/spf13/cobra.(*Command).execute(0x4000ae7800, {0x4000570820, 0xd, 0xd})
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:940 +0x5e0
github.com/spf13/cobra.(*Command).ExecuteC(0x4000de6300)
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:1068 +0x368
github.com/spf13/cobra.(*Command).Execute(...)
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:992
github.com/spf13/cobra.(*Command).ExecuteContext(...)
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:985
github.com/cosmos/cosmos-sdk/server/cmd.Execute(0x400006c768?, {0x4000ff9120, 0x1c})
	/go/pkg/mod/github.com/iqlusioninc/[email protected]/server/cmd/execute.go:36 +0x1a0
main.main()
	/interchain-security/cmd/interchain-security-sd/main.go:15 +0x38

@MSalopek MSalopek linked an issue Aug 3, 2023 that may be closed by this pull request
5 tasks
@MSalopek MSalopek changed the title deps!: check cosmos-sdk-v45-ics-lsm integration deps!: support cosmos-sdk-v45-ics-lsm integration Aug 3, 2023
MSalopek and others added 5 commits August 3, 2023 11:50
* handle CancelUnbondingDelegation message

* tests: add cancel-unbond e2e test

* fix: appease linter

* chore: Hardcode golangci-lint version (#990)

* Hardcode golangci-lint version

* Hardcode version in CI config

---------

Co-authored-by: MSalopek <[email protected]>
Co-authored-by: Philip Offtermatt <[email protected]>
@MSalopek
Copy link
Contributor Author

MSalopek commented Aug 3, 2023

Issue after backporting cancel-unbond operation handling and tests

➜  interchain-security git:(masa/test-ics-v2-with-cosmos-sdk-lsm) ✗ go run ./tests/e2e/... --happy-path-only
=============== running happy path only ===============
=============== building default testRun ===============
=============== started default tests ===============
running default: step 1 == StartChainAction
running default: step 2 == submitConsumerAdditionProposalAction
running default: step 3 == assignConsumerPubKeyAction
running default: step 4 == assignConsumerPubKeyAction
running default: step 5 == assignConsumerPubKeyAction
running default: step 6 == voteGovProposalAction
running default: step 7 == startConsumerChainAction
running default: step 8 == addIbcConnectionAction
running default: step 9 == addIbcChannelAction
running default: step 10 == delegateTokensAction
running default: step 11 == SendTokensAction
running default: step 12 == relayPacketsAction
running default: step 13 == SendTokensAction
running default: step 14 == assignConsumerPubKeyAction
running default: step 15 == relayPacketsAction
running default: step 16 == unbondTokensAction
running default: step 17 == relayPacketsAction
running default: step 18 == unbondTokensAction
running default: step 19 == relayPacketsAction
running default: step 20 == cancelUnbondTokensAction
2023/08/03 12:52:27 exit status 1
Error: unknown command "cancel-unbond" for "staking"
Usage:
  simd tx staking [flags]
  simd tx staking [command]

Available Commands:
  create-validator               create new validator initialized with a self-delegation to it
  delegate                       Delegate liquid tokens to a validator
  disable-tokenize-shares        Disable tokenization of shares
  edit-validator                 edit an existing validator account
  enable-tokenize-shares         Enable tokenization of shares
  redeem-tokens                  Redeem specified amount of share tokens to delegation
  redelegate                     Redelegate illiquid tokens from one validator to another
  tokenize-share                 Tokenize delegation to share tokens
  transfer-tokenize-share-record Transfer ownership of TokenizeShareRecord
  unbond                         Unbond shares from a validator
  unbond-validator               Unbond a validator
  validator-bond                 Mark a delegation as a validator self-bond

Flags:
  -h, --help   help for staking

Global Flags:
      --chain-id string     The network chain ID
      --home string         directory for config and data (default "/root/.interchain-security-p")
      --log_format string   The logging format (json|plain) (default "plain")
      --log_level string    The logging level (trace|debug|info|warn|error|fatal|panic) (default "info")
      --trace               print out full stack trace on errors

Use "simd tx staking [command] --help" for more information about a command.

exit status 1

@mpoke mpoke changed the base branch from release/v2.0.x to release/v2.0.x-lsm August 16, 2023 11:08
@mpoke mpoke marked this pull request as ready for review August 16, 2023 11:21
@mpoke mpoke requested a review from a team as a code owner August 16, 2023 11:21
Copy link
Contributor

@mpoke mpoke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work @MSalopek. LGTM

}

validators = append(validators, validator)
// NOTE: @MSalopek
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's because we don't have any ICS tests that are dealing with this flag.

Copy link
Contributor

@p-offtermatt p-offtermatt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the work. Just one minor comment on a line that's commented out.

UnbondingHeight: int64(0),
UnbondingTime: time.Unix(0, 0).UTC(),
Commission: stakingtypes.NewCommission(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()),
// MinSelfDelegation: sdk.ZeroInt(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this commented out instead of removed outright?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was deprecated in SDK. Probably @MSalopek can give a better reasoning for commenting it out.

@mpoke mpoke merged commit 309bd85 into release/v2.0.x-lsm Aug 16, 2023
6 of 7 checks passed
@mpoke mpoke deleted the masa/test-ics-v2-with-cosmos-sdk-lsm branch August 16, 2023 11:42
sainoe added a commit that referenced this pull request Nov 21, 2023
* docs: cleanup changelog for v2.0.0 on release/v2.0.x (#987)

* Update CHANGELOG.md

* Update CHANGELOG.md

* comment

* chore: Hardcode golangci-lint version (backport #990) (#1013)

chore: Hardcode golangci-lint version (#990)

* Hardcode golangci-lint version

* Hardcode version in CI config

(cherry picked from commit 9920121)

Co-authored-by: Philip Offtermatt <[email protected]>

* fix: proper consumer key prefix ordering (backport #991) (#1011)

fix: proper consumer key prefix ordering (#991)

* Update keys.go

* tests

* fix another bug

* fix comments

(cherry picked from commit a1e18d0)

Co-authored-by: Shawn <[email protected]>

* feat: Remove consumer genesis migration on provider (backport #997) (#1012)

feat: Remove consumer genesis migration on provider (#997)

* Update keys.go

* tests

* fix another bug

* remove consumer genesis deletion, link to test

* remove unused bond denom method

* Revert "remove unused bond denom method"

This reverts commit f930eca.

* remove test too

* update changelog

(cherry picked from commit e2ac974)

Co-authored-by: Shawn <[email protected]>

* fix: limit vsc matured packets handled per endblocker (backport #1004) (#1015)

fix: limit vsc matured packets handled per endblocker (#1004)

* initial implementation, still need tests

* UTs

* integration test

* linter

* Update CHANGELOG.md

* make vsc matured handled this block a var

* comment

(cherry picked from commit 8c2fc56)

Co-authored-by: Shawn <[email protected]>

* feat: integrate cometmock (backport #989) (#1030)

feat: integrate cometmock (#989)

* Add gorelayer and CometMock to Dockerfile

* Add option to start with cometmock in start-chain script

* Start adding support for rly

* Adjust relayer start action

* Add entrypoint for short happy path steps

* Add . nosec G204 and waiting for blocks

* Adjust rly config: Gas is free

* Remove optout steps from short happy path

* Use separate redelegate step for short happy path

* Wait for blocks after unbonding

* Make naming more descriptive and add comments

* Add comment to chain name sorting and improve comments

* Update start-chain.sh

Address comments form joint review session with @MSalopek

* Fix typo

(cherry picked from commit 07be71a)

Co-authored-by: Philip Offtermatt <[email protected]>

* feat!: Add DistributionTransmissionChannel to ConsumerAdditionProposal (manual backport #965) (#1031)

feat!: Add DistributionTransmissionChannel to ConsumerAdditionProposal (#965)

* update proto

* remove transfer_channel_id from consumer genesis

* ConsumerAdditionProposal: transfer_channel_id -> distribution_transmission_channel

* send updated ConsumerAdditionProposal

* validate consumer genesis param

* remove StandaloneTransferChannelID from store

* fix TestOnChanOpenAck

* remove state breaking change

* finalize merge and fix issues

* chore: update docs and changelog

* chore: regenerate protos

* re-add integrationt tests around changeover

* mv entry in changelog

* test: add sovereign to consumer changeover e2e (#1025)

* tests: add sovereign to consumer e2e test

* rm unused bash scripts

* partially address review comments

* apply remaining review comments

* chore: apply formatting rules

---------

Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: MSalopek <[email protected]>

* refactor: log when constructing IBC err ack (backport #1090) (#1094)

refactor: log when constructing IBC err ack (#1090)

* log with err ack

* linter

(cherry picked from commit 07302ff)

Co-authored-by: Shawn <[email protected]>

* fix: `AttributeDistributionTotal` in event emit (backport #1097) (#1114)

* fix: `AttributeDistributionTotal` in event emit (#1097)

* fix: emitted distribution events

* docs: update changelog

* fix: lint

---------

Co-authored-by: MSalopek <[email protected]>
(cherry picked from commit d16c766)

# Conflicts:
#	CHANGELOG.md
#	x/ccv/consumer/keeper/distribution.go

* resolve conflicts

* docs: remove v3 changelog from v2 release line

---------

Co-authored-by: yaruwangway <[email protected]>
Co-authored-by: Yaru Wang <[email protected]>

* docs: update broken md links (backport #1130) (#1142)

* docs: update broken md links (#1130)

(cherry picked from commit fd76f45)

# Conflicts:
#	docs/docs/validators/joining-testnet.md

* Update joining-testnet.md

---------

Co-authored-by: MSalopek <[email protected]>
Co-authored-by: Shawn <[email protected]>

* feat!: add ICS misbehaviour handling (#826)

* define msg to submit misbehaviour to provider

implement msg handling logic

e2e test msg handling logic

* wip: get byzantine validators in misbehavioiur handling

* add tx handler

* format HandleConsumerMisbehaviour

* add tx handler

* add debugging stuff

* Add misbehaviour handler

* create message for consumer double voting evidence

* add DRAFT double vote handler

* Add cli cmd for submit consumer double voting

* Add double-vote handler

* add last update

* fix jailing

* pass first jailing integration test

* format tests

* doc

* save

* update e2e tests'

* fix typo and improve docs

* remove unwanted tm evidence protofile

* fix typos

* update submit-consumer-misbehaviour cli description

* check that header1 and header2 have the same TrustedValidators

* feat: add e2e tests for ICS misbehaviour (#1118)

* remove unwanted changes

* fix hermes config with assigned key

* revert unwanted changes

* revert local setup

* remove log file

* typo

* update doc

* update ICS misbehaviour test

* update ICS misbehaviour test

* revert mixed commits

* add doc

* lint

* update to handle only equivocations

* improve doc

* update doc

* update E2E tests comment

* optimize signatures check

* doc

* update e2e tests

* linter

* remove todo

* Feat: avoid race condition in ICS misbehaviour handling (#1148)

* remove unwanted changes

* fix hermes config with assigned key

* revert unwanted changes

* revert local setup

* remove log file

* typo

* update doc

* update ICS misbehaviour test

* update ICS misbehaviour test

* revert mixed commits

* update ICS misbehaviour test

* update ICS misbehaviour test

* Add test for MsgSubmitConsumerMisbehaviour parsing

* fix linter

* save progress

* add CheckMisbehaviourAndUpdateState

* update integration tests

* typo

* remove e2e tests from another PRs

* cleaning'

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* update integration tests

* save

* save

* nits

* remove todo

* lint

* Update x/ccv/provider/keeper/misbehaviour.go

---------

Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: Marius Poke <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: Anca Zamfir <[email protected]>

* add attributes to EventTypeSubmitConsumerMisbehaviour

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* apply review suggestions

* fix docstring

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* fix link

* apply review suggestions

* update docstring

---------

Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: Marius Poke <[email protected]>

* deps!: support  cosmos-sdk-v45-ics-lsm integration (#1120)

* tests: check cosmos-sdk-v45-ics-lsm integration

* bump cosmos-sdk to inqlusion latest

* support new method signatuers

* fix: bump v0.45.16-ics-lsm to latest [fixes difftests]

* fix: update democracy tests representative registration

* chore: bump iqlusion:cosmos-sdk to latest

* chore: bump iqlusion:cosmos-sdk to latest

* chore: bump iqlusion:cosmos-sdk to latest

* fix!: avoid panicking on CancelUnbondingDelegation  (#977)

* handle CancelUnbondingDelegation message

* tests: add cancel-unbond e2e test

* fix: appease linter

* chore: Hardcode golangci-lint version (#990)

* Hardcode golangci-lint version

* Hardcode version in CI config

---------

Co-authored-by: MSalopek <[email protected]>
Co-authored-by: Philip Offtermatt <[email protected]>

* tests: fix broken cancelUnbond e2e after cherry pick

* chore: regenerate mocks

* chore: run make proto-gen

* fix: complete concel-unbond handling in hooks

* chore: bump iqlusion:cosmos-sdk to latest

* chore: fix brokene gov prop submit

* chore: fix brokene gov prop submit

* use SDK 0.45.16-ics-lsm-rc0

* add changelog entry

---------

Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: Philip Offtermatt <[email protected]>

* docs: add v2.0.0-lsm changelog section (#1210)

add changelog section

* deps: bump SDK to v0.45.16-ics-lsm (#1212)

bump SDK to v0.45.16-ics-lsm

* feat: improve ICS misbehaviour E2E testing coverage (#1225)

* update e2e tests

* update the chain halt assertion

* refactor: address comments of ICS Misbehaviour PRs #826 and #1148  (#1223)

* remove interface

* improve comment

* update godoc

* address last comments

* feat: add handler for consumer double voting (#1232)

* create new endpoint for consumer double voting

* add first draft handling logic

* first iteration of double voting

* draft first mem test

* error handling

* refactor

* add unit test of double voting verification

* remove evidence age checks

* document

* doc

* protogen

* reformat double voting handling

* logger nit

* nits

* check evidence age duration

* move verify double voting evidence to ut

* fix nit

* nits

* fix e2e tests

* improve double vote testing coverage

* remove TODO

* lint

* add UT for JailAndTombstoneValidator

* nits

* nits

* remove tombstoning and evidence age check

* lint

* typo

* improve godoc

* fix: tiny bug in `NewSubmitConsumerDoubleVotingCmd` (#1247)

* fix double voting cli

* fix bug double signing handler

* godoc

* nits

* revert wrong push of lasts commits

* fix: make `HandleConsumerDoubleVoting` works with provider pubkeys (#1254)

* fix double voting cli

* fix bug double signing handler

* godoc

* nits

* lint

* nit

* fix: verify equivocation using validator pubkey in `SubmitConsumerDoubleVoting` msg (#1264)

* verify dv evidence using malicious validator pubkey in infraction block header

* nits

* nits

* refactor: update the E2E tests to work with Hermes relayer v1.6.0 (#1278)

* save changes

* fix hermes config

* fist successful run

* nit

* nits

* nits

* doc and nits

* lint

* test: add E2E tests for double voting evidence handling (#1256)

* fix double voting cli

* add double-signing e2e test

* refortmat e2e double voting test

* godoc, revert unwanted changes

* nit

* verify dv evidence using malicious validator pubkey in infraction block header

* save changes

* fix hermes config

* fist successful run

* nit

* nits

* nits

* doc and nits

* lint

* refactor

* typo

* change hermes docker image

* nits

* Update tests/e2e/steps.go

Co-authored-by: Philip Offtermatt <[email protected]>

* address PR comments

* nits

---------

Co-authored-by: Philip Offtermatt <[email protected]>

* feat!: provider proposal for changing reward denoms (backport #1280) (#1291)

* feat!: provider proposal for changing reward denoms (#1280)

* new provider prop type

* add methods and tests for new prop, update docs

* remove old tx, fix tests

* e2e handling

* fix command type

* boilerplate

* fix e2e tests

* Update CHANGELOG.md

* lint

* validate denoms

* Update proposal.go

* rm msg string

* fix tests

* rm chain in change denom action

* lint

* test for invalid denom

* events for both add and remove

* Update proposal_test.go

(cherry picked from commit 48a2186)

# Conflicts:
#	CHANGELOG.md
#	app/provider/app.go
#	proto/interchain_security/ccv/provider/v1/provider.proto
#	proto/interchain_security/ccv/provider/v1/tx.proto
#	tests/e2e/actions.go
#	tests/integration/distribution.go
#	x/ccv/provider/client/cli/tx.go
#	x/ccv/provider/client/proposal_handler.go
#	x/ccv/provider/keeper/distribution.go
#	x/ccv/provider/keeper/distribution_test.go
#	x/ccv/provider/proposal_handler_test.go
#	x/ccv/provider/types/codec.go
#	x/ccv/provider/types/proposal.go
#	x/ccv/provider/types/provider.pb.go
#	x/ccv/provider/types/tx.pb.go

* fix conflicts

* fix rest handler

* Update CHANGELOG.md

* rm uneeded tx proto

---------

Co-authored-by: Shawn <[email protected]>

* save

* fix nits

* update changelog and fix nits

* feat: implement slashing functionality on the provider chain (ADR-013) (#1275)

Implementing the slashing functionality, as described in ADDR, on the provider chain.

* fix e2e happy-path-short test

* make consumer misbehaviour and double signing tests pass

* currently debugging democracy-reward

* fix e2e democ test

* refactor: remove equivocation proposal (#1294)

* remove equivocation proposal

* bring back evidencekeeper

* go.sum added

* rebase and fix lint issues

* fix mocks

* clean up protos & delete unecessary file

* fix E2E test

* fix Dockerfile

* more fixes

* increase wait attempt

* increase wait attempt

* wait 1 block in gov proposal

* fix numbers

---------

Co-authored-by: Karolos Antoniadis <[email protected]>

* add equivo removal failing tests

* fix democ e2e tests

* make mem tests pass

* lint

* fix Dockerfile

* update changelog

* fix nits

* update rapid test

* fix democ tests

* update changelog

* fix CHANGELOG.md

* nits

* Update docs/docs/features/slashing.md

Co-authored-by: insumity <[email protected]>

* Update proto/interchain_security/ccv/provider/v1/tx.proto

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* check verifying pubkey against validator address

* add tests

* update checkMisbehaviour tests

* save

* update all misbehaviour memory tests

* fix misb verify valset sigs test

* revert misb check fix for ibc 7

* nit fix

* fix nit

* fix: add equivocation proposal message back in protos (#1394)

* add depreacted equiv prop msg def

* add codec and content for equivo proposal msg

* doc

* proto

* fix!: verify the signatures of byzantine validators in misbehaviour handling (#1422)

* update byzantine validators extraction

* nits

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* last changes

* udpdate changelog

---------

Co-authored-by: insumity <[email protected]>

* feat: update misbehaviour handling using IBC-Go 7 (#1401)

* nit fix

* improve doc

* super picky nit

* fix!: drop nil votes in misbehaviour handling (#1404)

* update CHANGELOG for final release

* save

* update test to extract byzantine validators

* improve testing

* nits

* nits

* Update tests/integration/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update testutil/crypto/evidence.go

Co-authored-by: insumity <[email protected]>

* update util func

* doc

* check misb client ID

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* nits

---------

Co-authored-by: insumity <[email protected]>

* fix comments

* update changelog

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* improve tests

* lint

* udpate traces

* silly bug

---------

Co-authored-by: insumity <[email protected]>

* nit

* Update x/ccv/provider/keeper/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update tests/integration/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* address comments

* address comments

* Update x/ccv/provider/types/proposal.go

Co-authored-by: Philip Offtermatt <[email protected]>

* Update tests/integration/double_vote.go

Co-authored-by: Philip Offtermatt <[email protected]>

* Port: (feat!) [#1435](#1435) Add height-base filter for consumer equivocation evidence.

* fix: update consumer double vote cmd (#1439)

add cmd fix

* update CHANGELOG

* update changelog

* update changelog entries

* nits

---------

Co-authored-by: Shawn <[email protected]>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Philip Offtermatt <[email protected]>
Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: MSalopek <[email protected]>
Co-authored-by: yaruwangway <[email protected]>
Co-authored-by: Yaru Wang <[email protected]>
Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: insumity <[email protected]>
Co-authored-by: Karolos Antoniadis <[email protected]>
MSalopek added a commit that referenced this pull request Dec 1, 2023
* docs: cleanup changelog for v2.0.0 on release/v2.0.x (#987)

* Update CHANGELOG.md

* Update CHANGELOG.md

* comment

* chore: Hardcode golangci-lint version (backport #990) (#1013)

chore: Hardcode golangci-lint version (#990)

* Hardcode golangci-lint version

* Hardcode version in CI config

(cherry picked from commit 9920121)

Co-authored-by: Philip Offtermatt <[email protected]>

* fix: proper consumer key prefix ordering (backport #991) (#1011)

fix: proper consumer key prefix ordering (#991)

* Update keys.go

* tests

* fix another bug

* fix comments

(cherry picked from commit a1e18d0)

Co-authored-by: Shawn <[email protected]>

* feat: Remove consumer genesis migration on provider (backport #997) (#1012)

feat: Remove consumer genesis migration on provider (#997)

* Update keys.go

* tests

* fix another bug

* remove consumer genesis deletion, link to test

* remove unused bond denom method

* Revert "remove unused bond denom method"

This reverts commit f930eca.

* remove test too

* update changelog

(cherry picked from commit e2ac974)

Co-authored-by: Shawn <[email protected]>

* fix: limit vsc matured packets handled per endblocker (backport #1004) (#1015)

fix: limit vsc matured packets handled per endblocker (#1004)

* initial implementation, still need tests

* UTs

* integration test

* linter

* Update CHANGELOG.md

* make vsc matured handled this block a var

* comment

(cherry picked from commit 8c2fc56)

Co-authored-by: Shawn <[email protected]>

* feat: integrate cometmock (backport #989) (#1030)

feat: integrate cometmock (#989)

* Add gorelayer and CometMock to Dockerfile

* Add option to start with cometmock in start-chain script

* Start adding support for rly

* Adjust relayer start action

* Add entrypoint for short happy path steps

* Add . nosec G204 and waiting for blocks

* Adjust rly config: Gas is free

* Remove optout steps from short happy path

* Use separate redelegate step for short happy path

* Wait for blocks after unbonding

* Make naming more descriptive and add comments

* Add comment to chain name sorting and improve comments

* Update start-chain.sh

Address comments form joint review session with @MSalopek

* Fix typo

(cherry picked from commit 07be71a)

Co-authored-by: Philip Offtermatt <[email protected]>

* feat!: Add DistributionTransmissionChannel to ConsumerAdditionProposal (manual backport #965) (#1031)

feat!: Add DistributionTransmissionChannel to ConsumerAdditionProposal (#965)

* update proto

* remove transfer_channel_id from consumer genesis

* ConsumerAdditionProposal: transfer_channel_id -> distribution_transmission_channel

* send updated ConsumerAdditionProposal

* validate consumer genesis param

* remove StandaloneTransferChannelID from store

* fix TestOnChanOpenAck

* remove state breaking change

* finalize merge and fix issues

* chore: update docs and changelog

* chore: regenerate protos

* re-add integrationt tests around changeover

* mv entry in changelog

* test: add sovereign to consumer changeover e2e (#1025)

* tests: add sovereign to consumer e2e test

* rm unused bash scripts

* partially address review comments

* apply remaining review comments

* chore: apply formatting rules

---------

Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: MSalopek <[email protected]>

* refactor: log when constructing IBC err ack (backport #1090) (#1094)

refactor: log when constructing IBC err ack (#1090)

* log with err ack

* linter

(cherry picked from commit 07302ff)

Co-authored-by: Shawn <[email protected]>

* fix: `AttributeDistributionTotal` in event emit (backport #1097) (#1114)

* fix: `AttributeDistributionTotal` in event emit (#1097)

* fix: emitted distribution events

* docs: update changelog

* fix: lint

---------

Co-authored-by: MSalopek <[email protected]>
(cherry picked from commit d16c766)

* resolve conflicts

* docs: remove v3 changelog from v2 release line

---------

Co-authored-by: yaruwangway <[email protected]>
Co-authored-by: Yaru Wang <[email protected]>

* docs: update broken md links (backport #1130) (#1142)

* docs: update broken md links (#1130)

(cherry picked from commit fd76f45)

* Update joining-testnet.md

---------

Co-authored-by: MSalopek <[email protected]>
Co-authored-by: Shawn <[email protected]>

* feat!: add ICS misbehaviour handling (#826)

* define msg to submit misbehaviour to provider

implement msg handling logic

e2e test msg handling logic

* wip: get byzantine validators in misbehavioiur handling

* add tx handler

* format HandleConsumerMisbehaviour

* add tx handler

* add debugging stuff

* Add misbehaviour handler

* create message for consumer double voting evidence

* add DRAFT double vote handler

* Add cli cmd for submit consumer double voting

* Add double-vote handler

* add last update

* fix jailing

* pass first jailing integration test

* format tests

* doc

* save

* update e2e tests'

* fix typo and improve docs

* remove unwanted tm evidence protofile

* fix typos

* update submit-consumer-misbehaviour cli description

* check that header1 and header2 have the same TrustedValidators

* feat: add e2e tests for ICS misbehaviour (#1118)

* remove unwanted changes

* fix hermes config with assigned key

* revert unwanted changes

* revert local setup

* remove log file

* typo

* update doc

* update ICS misbehaviour test

* update ICS misbehaviour test

* revert mixed commits

* add doc

* lint

* update to handle only equivocations

* improve doc

* update doc

* update E2E tests comment

* optimize signatures check

* doc

* update e2e tests

* linter

* remove todo

* Feat: avoid race condition in ICS misbehaviour handling (#1148)

* remove unwanted changes

* fix hermes config with assigned key

* revert unwanted changes

* revert local setup

* remove log file

* typo

* update doc

* update ICS misbehaviour test

* update ICS misbehaviour test

* revert mixed commits

* update ICS misbehaviour test

* update ICS misbehaviour test

* Add test for MsgSubmitConsumerMisbehaviour parsing

* fix linter

* save progress

* add CheckMisbehaviourAndUpdateState

* update integration tests

* typo

* remove e2e tests from another PRs

* cleaning'

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* update integration tests

* save

* save

* nits

* remove todo

* lint

* Update x/ccv/provider/keeper/misbehaviour.go

---------

Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: Marius Poke <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: Anca Zamfir <[email protected]>

* add attributes to EventTypeSubmitConsumerMisbehaviour

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* apply review suggestions

* fix docstring

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: Anca Zamfir <[email protected]>

* fix link

* apply review suggestions

* update docstring

---------

Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: Marius Poke <[email protected]>

* deps!: support  cosmos-sdk-v45-ics-lsm integration (#1120)

* tests: check cosmos-sdk-v45-ics-lsm integration

* bump cosmos-sdk to inqlusion latest

* support new method signatuers

* fix: bump v0.45.16-ics-lsm to latest [fixes difftests]

* fix: update democracy tests representative registration

* chore: bump iqlusion:cosmos-sdk to latest

* chore: bump iqlusion:cosmos-sdk to latest

* chore: bump iqlusion:cosmos-sdk to latest

* fix!: avoid panicking on CancelUnbondingDelegation  (#977)

* handle CancelUnbondingDelegation message

* tests: add cancel-unbond e2e test

* fix: appease linter

* chore: Hardcode golangci-lint version (#990)

* Hardcode golangci-lint version

* Hardcode version in CI config

---------

Co-authored-by: MSalopek <[email protected]>
Co-authored-by: Philip Offtermatt <[email protected]>

* tests: fix broken cancelUnbond e2e after cherry pick

* chore: regenerate mocks

* chore: run make proto-gen

* fix: complete concel-unbond handling in hooks

* chore: bump iqlusion:cosmos-sdk to latest

* chore: fix brokene gov prop submit

* chore: fix brokene gov prop submit

* use SDK 0.45.16-ics-lsm-rc0

* add changelog entry

---------

Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: Philip Offtermatt <[email protected]>

* docs: add v2.0.0-lsm changelog section (#1210)

add changelog section

* deps: bump SDK to v0.45.16-ics-lsm (#1212)

bump SDK to v0.45.16-ics-lsm

* feat: improve ICS misbehaviour E2E testing coverage (#1225)

* update e2e tests

* update the chain halt assertion

* refactor: address comments of ICS Misbehaviour PRs #826 and #1148  (#1223)

* remove interface

* improve comment

* update godoc

* address last comments

* feat: add handler for consumer double voting (#1232)

* create new endpoint for consumer double voting

* add first draft handling logic

* first iteration of double voting

* draft first mem test

* error handling

* refactor

* add unit test of double voting verification

* remove evidence age checks

* document

* doc

* protogen

* reformat double voting handling

* logger nit

* nits

* check evidence age duration

* move verify double voting evidence to ut

* fix nit

* nits

* fix e2e tests

* improve double vote testing coverage

* remove TODO

* lint

* add UT for JailAndTombstoneValidator

* nits

* nits

* remove tombstoning and evidence age check

* lint

* typo

* improve godoc

* fix: tiny bug in `NewSubmitConsumerDoubleVotingCmd` (#1247)

* fix double voting cli

* fix bug double signing handler

* godoc

* nits

* revert wrong push of lasts commits

* fix: make `HandleConsumerDoubleVoting` works with provider pubkeys (#1254)

* fix double voting cli

* fix bug double signing handler

* godoc

* nits

* lint

* nit

* fix: verify equivocation using validator pubkey in `SubmitConsumerDoubleVoting` msg (#1264)

* verify dv evidence using malicious validator pubkey in infraction block header

* nits

* nits

* refactor: update the E2E tests to work with Hermes relayer v1.6.0 (#1278)

* save changes

* fix hermes config

* fist successful run

* nit

* nits

* nits

* doc and nits

* lint

* test: add E2E tests for double voting evidence handling (#1256)

* fix double voting cli

* add double-signing e2e test

* refortmat e2e double voting test

* godoc, revert unwanted changes

* nit

* verify dv evidence using malicious validator pubkey in infraction block header

* save changes

* fix hermes config

* fist successful run

* nit

* nits

* nits

* doc and nits

* lint

* refactor

* typo

* change hermes docker image

* nits

* Update tests/e2e/steps.go

Co-authored-by: Philip Offtermatt <[email protected]>

* address PR comments

* nits

---------

Co-authored-by: Philip Offtermatt <[email protected]>

* feat!: provider proposal for changing reward denoms (backport #1280) (#1291)

* feat!: provider proposal for changing reward denoms (#1280)

* new provider prop type

* add methods and tests for new prop, update docs

* remove old tx, fix tests

* e2e handling

* fix command type

* boilerplate

* fix e2e tests

* Update CHANGELOG.md

* lint

* validate denoms

* Update proposal.go

* rm msg string

* fix tests

* rm chain in change denom action

* lint

* test for invalid denom

* events for both add and remove

* Update proposal_test.go

(cherry picked from commit 48a2186)

* fix conflicts

* fix rest handler

* Update CHANGELOG.md

* rm uneeded tx proto

---------

Co-authored-by: Shawn <[email protected]>

* save

* fix nits

* update changelog and fix nits

* feat: implement slashing functionality on the provider chain (ADR-013) (#1275)

Implementing the slashing functionality, as described in ADDR, on the provider chain.

* fix e2e happy-path-short test

* make consumer misbehaviour and double signing tests pass

* currently debugging democracy-reward

* fix e2e democ test

* refactor: remove equivocation proposal (#1294)

* remove equivocation proposal

* bring back evidencekeeper

* go.sum added

* rebase and fix lint issues

* fix mocks

* clean up protos & delete unecessary file

* fix E2E test

* fix Dockerfile

* more fixes

* increase wait attempt

* increase wait attempt

* wait 1 block in gov proposal

* fix numbers

---------

Co-authored-by: Karolos Antoniadis <[email protected]>

* add equivo removal failing tests

* fix democ e2e tests

* make mem tests pass

* lint

* fix Dockerfile

* update changelog

* fix nits

* update rapid test

* fix democ tests

* update changelog

* fix CHANGELOG.md

* nits

* Update docs/docs/features/slashing.md

Co-authored-by: insumity <[email protected]>

* Update proto/interchain_security/ccv/provider/v1/tx.proto

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/punish_validator.go

Co-authored-by: insumity <[email protected]>

* check verifying pubkey against validator address

* add tests

* update checkMisbehaviour tests

* save

* update all misbehaviour memory tests

* fix misb verify valset sigs test

* revert misb check fix for ibc 7

* nit fix

* fix nit

* fix: add equivocation proposal message back in protos (#1394)

* add depreacted equiv prop msg def

* add codec and content for equivo proposal msg

* doc

* proto

* fix!: verify the signatures of byzantine validators in misbehaviour handling (#1422)

* update byzantine validators extraction

* nits

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* last changes

* udpdate changelog

---------

Co-authored-by: insumity <[email protected]>

* feat: update misbehaviour handling using IBC-Go 7 (#1401)

* nit fix

* improve doc

* super picky nit

* fix!: drop nil votes in misbehaviour handling (#1404)

* update CHANGELOG for final release

* save

* update test to extract byzantine validators

* improve testing

* nits

* nits

* Update tests/integration/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update testutil/crypto/evidence.go

Co-authored-by: insumity <[email protected]>

* update util func

* doc

* check misb client ID

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* nits

---------

Co-authored-by: insumity <[email protected]>

* fix comments

* update changelog

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* improve tests

* lint

* udpate traces

* silly bug

---------

Co-authored-by: insumity <[email protected]>

* nit

* Update x/ccv/provider/keeper/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/keeper/misbehaviour.go

Co-authored-by: insumity <[email protected]>

* Update tests/integration/double_vote.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* Update x/ccv/provider/client/cli/tx.go

Co-authored-by: insumity <[email protected]>

* address comments

* address comments

* Update x/ccv/provider/types/proposal.go

Co-authored-by: Philip Offtermatt <[email protected]>

* Update tests/integration/double_vote.go

Co-authored-by: Philip Offtermatt <[email protected]>

* Port: (feat!) [#1435](#1435) Add height-base filter for consumer equivocation evidence.

* fix: update consumer double vote cmd (#1439)

add cmd fix

* update CHANGELOG

* update changelog

* update changelog entries

* nits

---------

Co-authored-by: Shawn <[email protected]>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Philip Offtermatt <[email protected]>
Co-authored-by: Marius Poke <[email protected]>
Co-authored-by: MSalopek <[email protected]>
Co-authored-by: yaruwangway <[email protected]>
Co-authored-by: Yaru Wang <[email protected]>
Co-authored-by: Anca Zamfir <[email protected]>
Co-authored-by: insumity <[email protected]>
Co-authored-by: Karolos Antoniadis <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: cosmos-sdk Integration with Cosmos SDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

support cosmos-sdk with LSM changes in ICS v2
3 participants