cosmos-sdk/x/staking
adu-crypto e130915146
fix: the occasional staking module SimulateMsgCancelUnbondingDelegate failure (#12933)
## Description


---
This is a temporary fix targeted at staking module simulation for #12931.
We should randomly choose the unbonding entry `CreationHeight`, and then fetch the first entry that matches the `CreationHeight` to make sure we can get the correct entry balance.
### 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](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation 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](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed 
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
2022-08-17 12:56:02 +00:00
..
client refactor: x/bank integration and e2e tests (#12779) 2022-08-02 10:10:31 -05:00
exported feat(staking): migrate x/params away from x/staking (#12409) 2022-07-21 14:50:25 +00:00
keeper chore: fix linting issues exposed by fixing golangci-lint (#12895) 2022-08-11 22:00:24 +02:00
migrations refactor!: make simapp.MakeTestEncodingConfig private (#12747) 2022-07-27 17:23:56 +02:00
simulation fix: the occasional staking module SimulateMsgCancelUnbondingDelegate failure (#12933) 2022-08-17 12:56:02 +00:00
spec docs: add AfterDelegationModified x/staking hook (#12896) 2022-08-10 19:53:48 -03:00
teststaking chore: math lib update and type fixes (#12791) 2022-08-02 11:16:40 +00:00
types chore: fix linting issues exposed by fixing golangci-lint (#12895) 2022-08-11 22:00:24 +02:00
abci.go feat: migrate x/staking to app wiring (#12102) 2022-06-03 08:10:20 +00:00
app_test.go refactor: remove simapp references from x/bank and x/slashing tests (#12897) 2022-08-11 16:23:45 +00:00
bench_test.go chore: math lib update and type fixes (#12791) 2022-08-02 11:16:40 +00:00
common_test.go chore: math lib update and type fixes (#12791) 2022-08-02 11:16:40 +00:00
genesis_test.go chore: math lib update and type fixes (#12791) 2022-08-02 11:16:40 +00:00
genesis.go feat: migrate x/staking to app wiring (#12102) 2022-06-03 08:10:20 +00:00
module_test.go refactor!: use injected encoding params in simapp (#12717) 2022-07-27 15:21:10 +02:00
module.go refactor: remove simapp references from x/bank and x/slashing tests (#12897) 2022-08-11 16:23:45 +00:00
README.md docs: Improve markdownlint configuration (#11104) 2022-02-10 12:07:01 +00:00

Staking

  • Staking - Proof-of-Stake layer for public blockchains.