Upstream changes from iqlusioninc:v0.45.16-ics-lsm #6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Intro
As LSM prepares to be merged into Cosmos SDK v45 (ICS) branch, the last two weeks were heavy on some last-moment changes and improvements on Cosmos SDK side. I am glad that this implementation gets many new eyes from SDK team and most intricate issues are being tackled in the upstream.
This PR brings most recent and important changes from the upstream branch iqlusioninc:v0.45.16-ics-lsm, as well as some pending PRs from iqlusioninc repo. Obviously all changes that I took there are being manually adapted for 0.47, tests fixed and lots of issues that I spotted along the way were reported to the upstream. At this moment, I suppose we have 1:1 compatibility with store protos, internal logic, APIs and definitions of the LSM version that goes into SDK.
Since I got all tests working, it seems to be the time we could cut off a release for our Persistence Testnet v8. Once this PR is merged, we can bump all dependent versions.
Note: This PR better be reviewed commit-by-commit!
Testing
Unit tests
Testing all individual modules with unit tests:
Integration tests
Runs longer, expected results
E2E built-in tests
Runs some time, expected results
Simulation
Runs from the project root dir:
Runs some time, expected results
Optionally, to achieve the fullest testing possible:
External Tests
There is a branch in
persistenceCore
persistenceOne/persistenceCore#220 that implements some E2E LSM tests that interact withx/gov
proposal while tokenizing. Make sure to clone the repo at the PR's branch and run the testing:If everything works fine, both tests will finish in parallel in about 1m30s:
List of changes
I understand that it's hard to comprehend changes by glancing at the wall of text in the diff, and it's even harder to map the changes in my single commit there to wall of commits (103 commits!!! 😓) in the upstream branch. Therefore I put a list of changes that we apply in this PR. It is just a memory dump.
CancelTokenizeShareLockExpiration
to remove the lock from the queueAccountIsLiquidStakingProvider
renamed toDelegatorIsLiquidStaker
with more documentationTokenizeShareRecordReward
grpc query fixed bugTokenizeShareLockStatus
definition moved to staking proto filetotal_validator_bond_shares
intovalidator_bond_shares
everywheretotal_liquid_shares
intoliquid_shares
everywheremin_self_delegation
field in protomin_self_delegation
from most interfaces and testsTestRedelegateSelfDelegation
LastTokenizeShareRecordId
in genesis statestakingtypes.ModuleName
into simapp configNewWithdrawAllTokenizeShareRecordRewardCmd
validatorBondFactor
,globalLiquidStakingCap
,validatorLiquidStakingCap
during sims