Skip to content

Commit

Permalink
Merge pull request #115 from BitCannaGlobal/v0.46.6-update
Browse files Browse the repository at this point in the history
v0.46.6-update & fixing Groups bug
  • Loading branch information
RaulBernal authored Nov 24, 2022
2 parents fed39c2 + 1c077f4 commit be1518d
Show file tree
Hide file tree
Showing 3 changed files with 83 additions and 51 deletions.
32 changes: 30 additions & 2 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ import (
ibckeeper "github.com/cosmos/ibc-go/v5/modules/core/keeper"
"github.com/spf13/cast"

// "github.com/tendermint/spm/openapiconsole"
abci "github.com/tendermint/tendermint/abci/types"
tmjson "github.com/tendermint/tendermint/libs/json"
"github.com/tendermint/tendermint/libs/log"
Expand Down Expand Up @@ -675,7 +674,8 @@ func New(

// RegisterUpgradeHandlers is used for registering any on-chain upgrades.
// Make sure it's called after `app.mm` and `app.configurator` are set.
app.RegisterUpgradeHandlers()
// MainNET app.RegisterUpgradeHandlers()
app.RegisterUpgradeHandlersDevNet()

// create the simulation manager and define the order of the modules for deterministic simulations
app.sm = module.NewSimulationManager(
Expand Down Expand Up @@ -867,6 +867,34 @@ func (app *App) RegisterTendermintService(clientCtx client.Context) {
app.Query,
)
}
func (app *App) RegisterUpgradeHandlersDevNet() {
planName := "wakeandbake46.6"
app.UpgradeKeeper.SetUpgradeHandler(planName, func(ctx sdk.Context, plan upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) {
ctx.Logger().Info("start to run module migrations...")

return app.mm.RunMigrations(ctx, app.configurator, fromVM)
})

upgradeInfo, err := app.UpgradeKeeper.ReadUpgradeInfoFromDisk()
if err != nil {
panic(err)
}

if upgradeInfo.Name == planName && !app.UpgradeKeeper.IsSkipHeight(upgradeInfo.Height) {
storeUpgrades := storetypes.StoreUpgrades{
Added: []string{

//group.ModuleName,
//nft.ModuleName,
//liquiq stake
},
}

// Configure store loader that checks if version == upgradeHeight and applies store upgrades
app.SetStoreLoader(upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storeUpgrades))
}

}

func (app *App) RegisterUpgradeHandlers() {
planName := "wakeandbake"
Expand Down
31 changes: 16 additions & 15 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,27 @@ go 1.18

require (
cosmossdk.io/math v1.0.0-beta.3
github.com/cosmos/cosmos-sdk v0.46.4
github.com/cosmos/cosmos-sdk v0.46.6
github.com/cosmos/ibc-go/v5 v5.0.1
github.com/gogo/protobuf v1.3.3
github.com/golang/protobuf v1.5.2
github.com/grpc-ecosystem/grpc-gateway v1.16.0
github.com/ignite/cli v0.25.1
github.com/spf13/cast v1.5.0
github.com/spf13/cobra v1.5.0
github.com/spf13/cobra v1.6.0
github.com/stretchr/testify v1.8.0
github.com/tendermint/tendermint v0.34.22
github.com/tendermint/tendermint v0.34.24
github.com/tendermint/tm-db v0.6.7
google.golang.org/genproto v0.0.0-20221027153422-115e99e71e1c
google.golang.org/genproto v0.0.0-20221114212237-e4508ebdbee1
google.golang.org/grpc v1.50.1
gopkg.in/yaml.v2 v2.4.0
)

require (
cloud.google.com/go v0.105.0 // indirect
cloud.google.com/go/compute v1.10.0 // indirect
cloud.google.com/go/iam v0.6.0 // indirect
cloud.google.com/go/compute v1.12.1 // indirect
cloud.google.com/go/compute/metadata v0.2.1 // indirect
cloud.google.com/go/iam v0.7.0 // indirect
cloud.google.com/go/storage v1.27.0 // indirect
cosmossdk.io/errors v1.0.0-beta.7 // indirect
filippo.io/edwards25519 v1.0.0-rc.1 // indirect
Expand Down Expand Up @@ -96,7 +97,7 @@ require (
github.com/inconshreveable/mousetrap v1.0.1 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/jmhodges/levigo v1.0.0 // indirect
github.com/klauspost/compress v1.15.9 // indirect
github.com/klauspost/compress v1.15.11 // indirect
github.com/lib/pq v1.10.6 // indirect
github.com/libp2p/go-buffer-pool v0.1.0 // indirect
github.com/magiconair/properties v1.8.6 // indirect
Expand All @@ -118,7 +119,7 @@ require (
github.com/prometheus/client_golang v1.12.2 // indirect
github.com/prometheus/client_model v0.2.0 // indirect
github.com/prometheus/common v0.34.0 // indirect
github.com/prometheus/procfs v0.7.3 // indirect
github.com/prometheus/procfs v0.8.0 // indirect
github.com/rakyll/statik v0.1.7 // indirect
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect
github.com/regen-network/cosmos-proto v0.3.1 // indirect
Expand All @@ -138,17 +139,17 @@ require (
github.com/zondax/hid v0.9.1-0.20220302062450-5552068d2266 // indirect
go.etcd.io/bbolt v1.3.6 // indirect
go.opencensus.io v0.23.0 // indirect
golang.org/x/crypto v0.0.0-20220924013350-4ba4fb4dd9e7 // indirect
golang.org/x/crypto v0.1.0 // indirect
golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e // indirect
golang.org/x/net v0.1.0 // indirect
golang.org/x/oauth2 v0.1.0 // indirect
golang.org/x/sys v0.1.0 // indirect
golang.org/x/term v0.1.0 // indirect
golang.org/x/net v0.2.0 // indirect
golang.org/x/oauth2 v0.2.0 // indirect
golang.org/x/sys v0.2.0 // indirect
golang.org/x/term v0.2.0 // indirect
golang.org/x/text v0.4.0 // indirect
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
google.golang.org/api v0.100.0 // indirect
google.golang.org/api v0.102.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.28.1 // indirect
google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
nhooyr.io/websocket v1.8.6 // indirect
Expand Down
Loading

0 comments on commit be1518d

Please sign in to comment.