Documentation ¶
Overview ¶
*
- The v0_16 x/auth migration logic is adapted from
- https://github.com/cosmos/cosmos-sdk/blob/b75c29fc15d3320ec0c7596dbd7c787c48dccad8/x/auth/legacy/v040/migrate.go *
- The original migration code is changed here to support the following custom Account from the kava modules.
- - `x/validator-vesting/ValidatorVestingAccount`
*
- The v0_16 x/gov migration logic is adapted from
- https://github.com/cosmos/cosmos-sdk/blob/b75c29fc15d3320ec0c7596dbd7c787c48dccad8/x/gov/legacy/v040/migrate.go *
- The original migration code is changed here to support the following custom proposals from the kava modules.
- - `x/kavadist/CommunityPoolMultiSpendProposal` *
- Note: The committee modules also adds the `CommitteeChangeProposal` and `CommitteeDeleteProposal`.
- However, we should not have any proposals of these type on mainet so we should be good to ignore them here.
Index ¶
- Variables
- func Migrate(genDoc *tmtypes.GenesisDoc, ctx client.Context) (*tmtypes.GenesisDoc, error)
- func MigrateAuthV040(authGenState v039auth.GenesisState, genesisTime time.Time) *v040auth.GenesisState
- func MigrateCosmosAppState(appState genutiltypes.AppMap, clientCtx client.Context, genesisTime time.Time) genutiltypes.AppMap
- func MigrateGovV040(oldGovState v036gov.GenesisState) *v040gov.GenesisState
- func ResetPeriodicVestingAccount(vacc *v040vesting.PeriodicVestingAccount, startTime time.Time)
Constants ¶
This section is empty.
Variables ¶
var ( GenesisTime = time.Date(2022, 1, 19, 16, 0, 0, 0, time.UTC) ChainID = "kava-9" )
Functions ¶
func Migrate ¶
func Migrate(genDoc *tmtypes.GenesisDoc, ctx client.Context) (*tmtypes.GenesisDoc, error)
Migrate converts v15 genesis doc to v16 genesis doc
func MigrateAuthV040 ¶
func MigrateAuthV040(authGenState v039auth.GenesisState, genesisTime time.Time) *v040auth.GenesisState
Migrate accepts exported x/auth genesis state from v0.38/v0.39 and migrates it to v0.40 x/auth genesis state. The migration includes:
- Removing coins from account encoding. - Re-encode in v0.40 GenesisState.
func MigrateCosmosAppState ¶
func MigrateCosmosAppState(appState genutiltypes.AppMap, clientCtx client.Context, genesisTime time.Time) genutiltypes.AppMap
func MigrateGovV040 ¶
func MigrateGovV040(oldGovState v036gov.GenesisState) *v040gov.GenesisState
MigrateGovV036 accepts exported v0.36 x/gov genesis state and migrates it to v0.40 x/gov genesis state. The migration includes:
- Convert vote option & proposal status from byte to enum. - Migrate proposal content to Any. - Convert addresses from bytes to bech32 strings. - Re-encode in v0.40 GenesisState.
func ResetPeriodicVestingAccount ¶
func ResetPeriodicVestingAccount(vacc *v040vesting.PeriodicVestingAccount, startTime time.Time)
ResetPeriodicVestingAccount resets a periodic vesting account to a new start time. The account is modified in place, and vesting periods before the new start time are removed from the account.
Types ¶
This section is empty.