Skip to content

Commit

Permalink
Merge pull request #15 from rarimo/chains/mainnet-beta-v1.1.1-rc0
Browse files Browse the repository at this point in the history
Upgrade v1.1.1-rc0
  • Loading branch information
olegfomenko authored Apr 18, 2024
2 parents 08c8f9d + cde7e62 commit 08ff182
Show file tree
Hide file tree
Showing 45 changed files with 5,720 additions and 251 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,4 @@ release/
.vscode/
.DS_Store
vendor/
/genesis/

/config/validator
34 changes: 33 additions & 1 deletion app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,9 @@ import (
bridgemodule "github.com/rarimo/rarimo-core/x/bridge"
bridgemodulekeeper "github.com/rarimo/rarimo-core/x/bridge/keeper"
bridgemoduletypes "github.com/rarimo/rarimo-core/x/bridge/types"
cscalistmodule "github.com/rarimo/rarimo-core/x/cscalist"
cscalistkeeper "github.com/rarimo/rarimo-core/x/cscalist/keeper"
cscalisttypes "github.com/rarimo/rarimo-core/x/cscalist/types"
"github.com/rarimo/rarimo-core/x/evm"
evmkeeper "github.com/rarimo/rarimo-core/x/evm/keeper"
evmtypes "github.com/rarimo/rarimo-core/x/evm/types"
Expand Down Expand Up @@ -203,6 +206,7 @@ var (

vestingmintmodule.AppModuleBasic{},
identitymodule.AppModuleBasic{},
cscalistmodule.AppModuleBasic{},
// this line is used by starport scaffolding # stargate/app/moduleBasic
)

Expand Down Expand Up @@ -284,6 +288,7 @@ type App struct {

VestingmintKeeper vestingmintmodulekeeper.Keeper
IdentityKeeper identitymodulekeeper.Keeper
CSCAListKeeper cscalistkeeper.Keeper
// this line is used by starport scaffolding # stargate/app/keeperDeclaration
RarimocoreKeeper rarimocoremodulekeeper.Keeper

Expand Down Expand Up @@ -347,6 +352,7 @@ func New(
multisigmoduletypes.StoreKey, evmtypes.StoreKey, feemarkettypes.StoreKey,
vestingmintmoduletypes.StoreKey,
identitymoduletypes.StoreKey,
cscalisttypes.StoreKey,
// this line is used by starport scaffolding # stargate/app/storeKey
)
tkeys := sdk.NewTransientStoreKeys(paramstypes.TStoreKey, evmtypes.TransientKey, feemarkettypes.TransientKey)
Expand Down Expand Up @@ -522,6 +528,14 @@ func New(
)
identityModule := identitymodule.NewAppModule(appCodec, app.IdentityKeeper, app.AccountKeeper, app.BankKeeper)

app.CSCAListKeeper = *cscalistkeeper.NewKeeper(
appCodec,
keys[cscalisttypes.StoreKey],
keys[cscalisttypes.MemStoreKey],
app.RarimocoreKeeper,
)
cscaListModule := cscalistmodule.NewAppModule(appCodec, app.CSCAListKeeper)

// Create Transfer Keepers
app.TransferKeeper = ibctransferkeeper.NewKeeper(
appCodec,
Expand Down Expand Up @@ -578,7 +592,8 @@ func New(
AddRoute(tokenmanagermoduletypes.RouterKey, tokenmanagermodule.NewProposalHandler(app.TokenmanagerKeeper)).
//AddRoute(banktypes.RouterKey, bank.NewProposalHandler(app.BankKeeper)).
AddRoute(oraclemanagermoduletypes.RouterKey, oraclemanagermodule.NewProposalHandler(app.OraclemanagerKeeper)).
AddRoute(bridgemoduletypes.RouterKey, bridgemodule.NewProposalHandler(app.BridgeKeeper))
AddRoute(bridgemoduletypes.RouterKey, bridgemodule.NewProposalHandler(app.BridgeKeeper)).
AddRoute(cscalisttypes.RouterKey, cscalistmodule.NewProposalHandler(app.CSCAListKeeper))

govConfig := govtypes.DefaultConfig()
app.GovKeeper = govkeeper.NewKeeper(
Expand Down Expand Up @@ -722,6 +737,7 @@ func New(
evmModule,
vestingmintModule,
identityModule,
cscaListModule,
// this line is used by starport scaffolding # stargate/app/appModule
)

Expand Down Expand Up @@ -760,6 +776,7 @@ func New(
multisigmoduletypes.ModuleName,
vestingmintmoduletypes.ModuleName,
identitymoduletypes.ModuleName,
cscalisttypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/beginBlockers
)

Expand Down Expand Up @@ -793,6 +810,7 @@ func New(
vestingtypes.ModuleName,
vestingmintmoduletypes.ModuleName,
identitymoduletypes.ModuleName,
cscalisttypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/endBlockers
)

Expand Down Expand Up @@ -835,6 +853,7 @@ func New(
crisistypes.ModuleName,
vestingmintmoduletypes.ModuleName,
identitymoduletypes.ModuleName,
cscalisttypes.ModuleName,

// this line is used by starport scaffolding # stargate/app/initGenesis
)
Expand Down Expand Up @@ -1004,6 +1023,19 @@ func New(
},
)

if upgradeInfo.Name == "v1.1.1-rc0" && !app.UpgradeKeeper.IsSkipHeight(upgradeInfo.Height) {
app.SetStoreLoader(upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storetypes.StoreUpgrades{
Added: []string{cscalisttypes.ModuleName},
}))
}

app.UpgradeKeeper.SetUpgradeHandler(
"v1.1.1-rc0",
func(ctx sdk.Context, plan upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) {
return app.mm.RunMigrations(ctx, app.configurator, fromVM)
},
)

if loadLatest {
if err := app.LoadLatestVersion(); err != nil {
tmos.Exit(err.Error())
Expand Down
19 changes: 19 additions & 0 deletions docs/common/mainnet/002-upgrades.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,25 @@ title: Mainnet upgrades

# Mainnet upgrades

## V1.1.0

Core binary: (
alpine-linux/amd64): "<https://github.com/rarimo/rarimo-core/releases/download/v1.1.0/rarimo-core-alpine-linux-amd64>".

Also, you can build core from sources by yourself: use <"https://github.com/rarimo/rarimo-core/releases/tag/v1.1.0">
release information.

Upgrade will perform automatically if you are using `cosmovisor` under Alpine linux.

Also, if you are using Ubuntu linux, please install `musl-dev` using `sudo apt install musl-dev` command to be able to
use Alpine binary on your machine.

Upgrade v1.1.0 introduces a couple of features for identity transfers:

- New WorldCoin identity transfer
- Fix for the Iden3 identity transfers: GIST and state transfers are split into two different operations.
- Double-sending of confirmation messages will not cause TX error.

## V1.0.7

Core binary: (alpine-linux/amd64): "<https://storage.googleapis.com/rarimo-mainnet/1.0.7/rarimo-core>".
Expand Down
Loading

0 comments on commit 08ff182

Please sign in to comment.