x/upgrade: protocol version tracking (#8897)
* -added consensus version tracking to x/upgrade * -added interface to module manager -added e2e test for migrations using consensus version store in x/upgrade -cleaned up x/upgrade Keeper -handler in apply upgrade now handles errors and setting consensus versions -cleaned up migration map keys -removed init chainer method -simapp now implements GetConsensusVersions to assist with testing * protocol version p1 * add protocol version to baseapp * rebase against master * add test * added test case * cleanup * docs and change to bigendian * changelog * cleanup keeper * swap appVersion and version * cleanup * change interface id * update keeper field name to versionSetter * reorder keys and docs * -move interface into exported folder * typo * typo2 * docs on keeper fields * docs for upgrade NewKeeper * cleanup * NewKeeper docs Co-authored-by: technicallyty <48813565+tytech3@users.noreply.github.com> Co-authored-by: Alessio Treglia <alessio@tendermint.com>
This commit is contained in:
co-authored by
technicallyty
Alessio Treglia
parent
410d8edb38
commit
e3a0148bf6
+2
-2
@@ -200,7 +200,7 @@ func NewSimApp(
|
||||
|
||||
bApp := baseapp.NewBaseApp(appName, logger, db, encodingConfig.TxConfig.TxDecoder(), baseAppOptions...)
|
||||
bApp.SetCommitMultiStoreTracer(traceStore)
|
||||
bApp.SetAppVersion(version.Version)
|
||||
bApp.SetVersion(version.Version)
|
||||
bApp.SetInterfaceRegistry(interfaceRegistry)
|
||||
|
||||
keys := sdk.NewKVStoreKeys(
|
||||
@@ -257,7 +257,7 @@ func NewSimApp(
|
||||
)
|
||||
|
||||
app.FeeGrantKeeper = feegrantkeeper.NewKeeper(appCodec, keys[feegranttypes.StoreKey], app.AccountKeeper)
|
||||
app.UpgradeKeeper = upgradekeeper.NewKeeper(skipUpgradeHeights, keys[upgradetypes.StoreKey], appCodec, homePath)
|
||||
app.UpgradeKeeper = upgradekeeper.NewKeeper(skipUpgradeHeights, keys[upgradetypes.StoreKey], appCodec, homePath, app.BaseApp)
|
||||
|
||||
// register the staking hooks
|
||||
// NOTE: stakingKeeper above is passed by reference, so that it will contain these hooks
|
||||
|
||||
Reference in New Issue
Block a user