Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin' into eric/lsm-split
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric-Warehime committed Jan 21, 2025
2 parents b1fd9fb + bb48f00 commit 36ffe51
Show file tree
Hide file tree
Showing 69 changed files with 163 additions and 114 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docker-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
flavor: "latest=false"

- name: Build and push docker image
uses: docker/build-push-action@v6.10.0
uses: docker/build-push-action@v6.12.0
with:
context: .
file: Dockerfile
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,10 @@ jobs:
# the old gaiad binary version is hardcoded, need to be updated each major release.
- name: Install Old Gaiad
run: |
curl -LO https://github.com/cosmos/gaia/releases/download/v21.0.0/gaiad-v21.0.0-linux-amd64
chmod a+x gaiad-v21.0.0-linux-amd64
curl -LO https://github.com/cosmos/gaia/releases/download/v22.0.0/gaiad-v22.0.0-linux-amd64
chmod a+x gaiad-v22.0.0-linux-amd64
mkdir build
mv ./gaiad-v21.0.0-linux-amd64 ./build/gaiadold
mv ./gaiad-v22.0.0-linux-amd64 ./build/gaiadold
if: env.GIT_DIFF
- name: Install New Gaiad
run: |
Expand Down
2 changes: 1 addition & 1 deletion ante/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"
wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types"

gaiaerrors "github.com/cosmos/gaia/v22/types/errors"
gaiaerrors "github.com/cosmos/gaia/v23/types/errors"
)

// UseFeeMarketDecorator to make the integration testing easier: we can switch off its ante and post decorators with this flag
Expand Down
2 changes: 1 addition & 1 deletion ante/gov_expedited_ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"

gaiaerrors "github.com/cosmos/gaia/v22/types/errors"
gaiaerrors "github.com/cosmos/gaia/v23/types/errors"
)

var expeditedPropDecoratorEnabled = true
Expand Down
4 changes: 2 additions & 2 deletions ante/gov_expedited_ante_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import (
govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"

"github.com/cosmos/gaia/v22/ante"
"github.com/cosmos/gaia/v22/app/helpers"
"github.com/cosmos/gaia/v23/ante"
"github.com/cosmos/gaia/v23/app/helpers"
)

func TestGovExpeditedProposalsDecorator(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion ante/gov_vote_ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper"
stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"

gaiaerrors "github.com/cosmos/gaia/v22/types/errors"
gaiaerrors "github.com/cosmos/gaia/v23/types/errors"
)

var (
Expand Down
4 changes: 2 additions & 2 deletions ante/gov_vote_ante_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ import (
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"

"github.com/cosmos/gaia/v22/ante"
"github.com/cosmos/gaia/v22/app/helpers"
"github.com/cosmos/gaia/v23/ante"
"github.com/cosmos/gaia/v23/app/helpers"
)

// Test that the GovVoteDecorator rejects v1beta1 vote messages from accounts with less than 1 atom staked
Expand Down
10 changes: 5 additions & 5 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,17 +66,17 @@ import (
wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"
wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types"

gaiaante "github.com/cosmos/gaia/v22/ante"
"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v22/app/upgrades"
v22 "github.com/cosmos/gaia/v22/app/upgrades/v22"
gaiaante "github.com/cosmos/gaia/v23/ante"
"github.com/cosmos/gaia/v23/app/keepers"
"github.com/cosmos/gaia/v23/app/upgrades"
v23 "github.com/cosmos/gaia/v23/app/upgrades/v23"
)

var (
// DefaultNodeHome default home directories for the application daemon
DefaultNodeHome string

Upgrades = []upgrades.Upgrade{v22.Upgrade}
Upgrades = []upgrades.Upgrade{v23.Upgrade}
)

var (
Expand Down
4 changes: 2 additions & 2 deletions app/app_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import (

wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"

gaia "github.com/cosmos/gaia/v22/app"
gaiahelpers "github.com/cosmos/gaia/v22/app/helpers"
gaia "github.com/cosmos/gaia/v23/app"
gaiahelpers "github.com/cosmos/gaia/v23/app/helpers"
)

type EmptyAppOptions struct{}
Expand Down
2 changes: 1 addition & 1 deletion app/helpers/test_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import (

wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"

gaiaapp "github.com/cosmos/gaia/v22/app"
gaiaapp "github.com/cosmos/gaia/v23/app"
)

// SimAppChainID hardcoded chainID for simulation
Expand Down
8 changes: 4 additions & 4 deletions app/modules.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ import (
wasm "github.com/CosmWasm/wasmd/x/wasm"
wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types"

"github.com/cosmos/gaia/v22/x/lsm"
lsmtypes "github.com/cosmos/gaia/v22/x/lsm/types"
"github.com/cosmos/gaia/v22/x/metaprotocols"
metaprotocolstypes "github.com/cosmos/gaia/v22/x/metaprotocols/types"
"github.com/cosmos/gaia/v23/x/lsm"
lsmtypes "github.com/cosmos/gaia/v23/x/lsm/types"
"github.com/cosmos/gaia/v23/x/metaprotocols"
metaprotocolstypes "github.com/cosmos/gaia/v23/x/metaprotocols/types"
)

var maccPerms = map[string][]string{
Expand Down
2 changes: 1 addition & 1 deletion app/post.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"

"github.com/cosmos/gaia/v22/ante"
"github.com/cosmos/gaia/v23/ante"
)

// PostHandlerOptions are the options required for constructing a FeeMarket PostHandler.
Expand Down
2 changes: 1 addition & 1 deletion app/sim/sim_state.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
banktypes "github.com/cosmos/cosmos-sdk/x/bank/types"
stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"

gaia "github.com/cosmos/gaia/v22/app"
gaia "github.com/cosmos/gaia/v23/app"
)

// Simulation parameter constants
Expand Down
2 changes: 1 addition & 1 deletion app/sim/sim_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"github.com/cosmos/cosmos-sdk/types/module"
simtypes "github.com/cosmos/cosmos-sdk/types/simulation"

gaia "github.com/cosmos/gaia/v22/app"
gaia "github.com/cosmos/gaia/v23/app"
)

// SimulationOperations retrieves the simulation params from the provided file path
Expand Down
4 changes: 2 additions & 2 deletions app/sim_bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import (
"github.com/cosmos/cosmos-sdk/x/simulation"
simcli "github.com/cosmos/cosmos-sdk/x/simulation/client/cli"

gaia "github.com/cosmos/gaia/v22/app"
"github.com/cosmos/gaia/v22/app/sim"
gaia "github.com/cosmos/gaia/v23/app"
"github.com/cosmos/gaia/v23/app/sim"
)

// Profile with:
Expand Down
6 changes: 3 additions & 3 deletions app/sim_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ import (
"github.com/cosmos/cosmos-sdk/x/simulation"
simcli "github.com/cosmos/cosmos-sdk/x/simulation/client/cli"

"github.com/cosmos/gaia/v22/ante"
gaia "github.com/cosmos/gaia/v22/app"
"github.com/cosmos/gaia/v23/ante"
gaia "github.com/cosmos/gaia/v23/app"
// "github.com/cosmos/gaia/v11/app/helpers"
// "github.com/cosmos/gaia/v11/app/params"
"github.com/cosmos/gaia/v22/app/sim"
"github.com/cosmos/gaia/v23/app/sim"
)

// AppChainID hardcoded chainID for simulation
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"

"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v23/app/keepers"
)

// Upgrade defines a struct containing necessary fields that a SoftwareUpgradeProposal
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v19/constants.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package v19

import (
"github.com/cosmos/gaia/v22/app/upgrades"
"github.com/cosmos/gaia/v23/app/upgrades"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v19/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"

"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v23/app/keepers"
)

func CreateUpgradeHandler(
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v20/constants.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package v20

import (
"github.com/cosmos/gaia/v22/app/upgrades"
"github.com/cosmos/gaia/v23/app/upgrades"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v20/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper"

"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v23/app/keepers"
)

// Constants for the new parameters in the v20 upgrade.
Expand Down
4 changes: 2 additions & 2 deletions app/upgrades/v20/upgrades_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import (
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types"
v1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"

"github.com/cosmos/gaia/v22/app/helpers"
v20 "github.com/cosmos/gaia/v22/app/upgrades/v20"
"github.com/cosmos/gaia/v23/app/helpers"
v20 "github.com/cosmos/gaia/v23/app/upgrades/v20"
)

func GetTestMsgConsumerAddition() providertypes.MsgConsumerAddition { //nolint:staticcheck
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v21/constants.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package v21

import (
"github.com/cosmos/gaia/v22/app/upgrades"
"github.com/cosmos/gaia/v23/app/upgrades"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v21/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper"
govparams "github.com/cosmos/cosmos-sdk/x/gov/types/v1"

"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v23/app/keepers"
)

// Neutron and Stride denoms that were not whitelisted but the consumer rewards pool contains amounts of those denoms.
Expand Down
4 changes: 2 additions & 2 deletions app/upgrades/v21/upgrades_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (

govparams "github.com/cosmos/cosmos-sdk/x/gov/types/v1"

"github.com/cosmos/gaia/v22/app/helpers"
v21 "github.com/cosmos/gaia/v22/app/upgrades/v21"
"github.com/cosmos/gaia/v23/app/helpers"
v21 "github.com/cosmos/gaia/v23/app/upgrades/v21"
)

func TestHasExpectedChainIDSanityCheck(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v22/constants.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package v22

import (
"github.com/cosmos/gaia/v22/app/upgrades"
"github.com/cosmos/gaia/v23/app/upgrades"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v22/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"

"github.com/cosmos/gaia/v22/app/keepers"
"github.com/cosmos/gaia/v23/app/keepers"
)

// CreateUpgradeHandler returns an upgrade handler for Gaia v22.
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/v22/upgrades_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

"cosmossdk.io/math"

v22 "github.com/cosmos/gaia/v22/app/upgrades/v22"
v22 "github.com/cosmos/gaia/v23/app/upgrades/v22"
)

func TestSetDefaultConsumerInfractionParams(t *testing.T) {
Expand Down
15 changes: 15 additions & 0 deletions app/upgrades/v23/constants.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package v23

import (
"github.com/cosmos/gaia/v23/app/upgrades"
)

const (
// UpgradeName defines the on-chain upgrade name.
UpgradeName = "v23"
)

var Upgrade = upgrades.Upgrade{
UpgradeName: UpgradeName,
CreateUpgradeHandler: CreateUpgradeHandler,
}
33 changes: 33 additions & 0 deletions app/upgrades/v23/upgrades.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package v23

import (
"context"

errorsmod "cosmossdk.io/errors"
upgradetypes "cosmossdk.io/x/upgrade/types"

sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"

"github.com/cosmos/gaia/v23/app/keepers"
)

// CreateUpgradeHandler returns an upgrade handler for Gaia v23.
func CreateUpgradeHandler(
mm *module.Manager,
configurator module.Configurator,
keepers *keepers.AppKeepers,
) upgradetypes.UpgradeHandler {
return func(c context.Context, plan upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) {
ctx := sdk.UnwrapSDKContext(c)
ctx.Logger().Info("Starting module migrations...")

vm, err := mm.RunMigrations(ctx, configurator, vm)
if err != nil {
return vm, errorsmod.Wrapf(err, "running module migrations")
}

ctx.Logger().Info("Upgrade v23 complete")
return vm, nil
}
}
2 changes: 1 addition & 1 deletion cmd/gaiad/cmd/bech32_convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (

"github.com/spf13/cobra"

addressutil "github.com/cosmos/gaia/v22/pkg/address"
addressutil "github.com/cosmos/gaia/v23/pkg/address"
)

var flagBech32Prefix = "prefix"
Expand Down
2 changes: 1 addition & 1 deletion cmd/gaiad/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ import (
wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"
wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types"

gaia "github.com/cosmos/gaia/v22/app"
gaia "github.com/cosmos/gaia/v23/app"
)

// NewRootCmd creates a new root command for simd. It is called once in the
Expand Down
4 changes: 2 additions & 2 deletions cmd/gaiad/cmd/root_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (

svrcmd "github.com/cosmos/cosmos-sdk/server/cmd"

app "github.com/cosmos/gaia/v22/app"
"github.com/cosmos/gaia/v22/cmd/gaiad/cmd"
app "github.com/cosmos/gaia/v23/app"
"github.com/cosmos/gaia/v23/cmd/gaiad/cmd"
)

func TestRootCmdConfig(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion cmd/gaiad/cmd/testnet_set_local_validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"github.com/spf13/cast"
"github.com/spf13/cobra"

gaia "github.com/cosmos/gaia/v22/app"
gaia "github.com/cosmos/gaia/v23/app"

"cosmossdk.io/log"
"github.com/cometbft/cometbft/crypto"
Expand Down
4 changes: 2 additions & 2 deletions cmd/gaiad/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (

svrcmd "github.com/cosmos/cosmos-sdk/server/cmd"

app "github.com/cosmos/gaia/v22/app"
"github.com/cosmos/gaia/v22/cmd/gaiad/cmd"
app "github.com/cosmos/gaia/v23/app"
"github.com/cosmos/gaia/v23/cmd/gaiad/cmd"
)

func main() {
Expand Down
Loading

0 comments on commit 36ffe51

Please sign in to comment.