Skip to content

Commit

Permalink
merge from develop
Browse files Browse the repository at this point in the history
  • Loading branch information
hoank101 committed May 16, 2024
1 parent beb1b64 commit ece78ce
Show file tree
Hide file tree
Showing 13 changed files with 10 additions and 249 deletions.
5 changes: 3 additions & 2 deletions app/app.go
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
package app

import (
"cosmossdk.io/client/v2/autocli"
"cosmossdk.io/core/appmodule"
"fmt"
tmproto "github.com/cometbft/cometbft/proto/tendermint/types"
runtimeservices "github.com/cosmos/cosmos-sdk/runtime/services"
authcodec "github.com/cosmos/cosmos-sdk/x/auth/codec"
"io"
"os"
"path/filepath"
"github.com/notional-labs/composable/v6/app/upgrades/v6_6_4"

"cosmossdk.io/x/circuit"
circuittypes "cosmossdk.io/x/circuit/types"
Expand Down Expand Up @@ -146,7 +147,7 @@ var (
// https://github.com/CosmWasm/wasmd/blob/02a54d33ff2c064f3539ae12d75d027d9c665f05/x/wasm/internal/types/proposal.go#L28-L34
EnableSpecificProposals = ""

Upgrades = []upgrades.Upgrade{v7_0_1.Upgrade, v6_6_4.Upgrade}
Upgrades = []upgrades.Upgrade{v7_0_1.Upgrade}
Forks = []upgrades.Fork{}
)

Expand Down
Empty file removed app/upgrades/v6_5_5/constants.go
Empty file.
24 changes: 0 additions & 24 deletions app/upgrades/v6_5_5/upgrade.go

This file was deleted.

20 changes: 0 additions & 20 deletions app/upgrades/v6_6_1/constants.go

This file was deleted.

60 changes: 0 additions & 60 deletions app/upgrades/v6_6_1/upgrade.go

This file was deleted.

20 changes: 0 additions & 20 deletions app/upgrades/v6_6_2/constants.go

This file was deleted.

32 changes: 0 additions & 32 deletions app/upgrades/v6_6_2/upgrade.go

This file was deleted.

20 changes: 0 additions & 20 deletions app/upgrades/v6_6_4/constants.go

This file was deleted.

29 changes: 0 additions & 29 deletions bech32-migration/ibchooks/ibchooks.go

This file was deleted.

32 changes: 0 additions & 32 deletions bech32-migration/ibctransfermiddleware/ibctransfermiddleware.go

This file was deleted.

14 changes: 6 additions & 8 deletions custom/ibc-transfer/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,21 @@ package keeper

import (
"context"
sdkmath "cosmossdk.io/math"
"encoding/json"
"fmt"
"time"

"github.com/cosmos/cosmos-sdk/codec"
ibctransferkeeper "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper"

storetypes "github.com/cosmos/cosmos-sdk/store/types"
sdk "github.com/cosmos/cosmos-sdk/types"
ibctransferkeeper "github.com/cosmos/ibc-go/v8/modules/apps/transfer/keeper"
custombankkeeper "github.com/notional-labs/composable/v6/custom/bank/keeper"
"time"

storetypes "cosmossdk.io/store/types"
sdk "github.com/cosmos/cosmos-sdk/types"
paramtypes "github.com/cosmos/cosmos-sdk/x/params/types"
"github.com/cosmos/ibc-go/v8/modules/apps/transfer/types"
porttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types"
"github.com/cosmos/ibc-go/v8/modules/core/exported"
custombankkeeper "github.com/notional-labs/composable/v6/custom/bank/keeper"
ibctransfermiddleware "github.com/notional-labs/composable/v6/x/ibctransfermiddleware/keeper"
ibctransfermiddlewaretypes "github.com/notional-labs/composable/v6/x/ibctransfermiddleware/types"
)
Expand Down Expand Up @@ -63,7 +61,7 @@ func NewKeeper(
func (k Keeper) Transfer(goCtx context.Context, msg *types.MsgTransfer) (*types.MsgTransferResponse, error) {
ctx := sdk.UnwrapSDKContext(goCtx)
params := k.IbcTransfermiddleware.GetParams(ctx)
charge_coin := sdk.NewCoin(msg.Token.Denom, sdk.ZeroInt())
charge_coin := sdk.NewCoin(msg.Token.Denom, sdkmath.ZeroInt())
if params.ChannelFees != nil && len(params.ChannelFees) > 0 {
channelFee := findChannelParams(params.ChannelFees, msg.SourceChannel)
if channelFee != nil {
Expand Down Expand Up @@ -125,7 +123,7 @@ func (k Keeper) Transfer(goCtx context.Context, msg *types.MsgTransfer) (*types.
return nil, send_err
}

if newAmount.LTE(sdk.ZeroInt()) {
if newAmount.LTE(sdkmath.ZeroInt()) {
return &types.MsgTransferResponse{}, nil
}
msg.Token.Amount = newAmount
Expand Down
2 changes: 1 addition & 1 deletion custom/ibc-transfer/keeper/msg_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ func NewMsgServerImpl(ibcKeeper Keeper, bankKeeper custombankkeeper.Keeper) type
func (k msgServer) Transfer(goCtx context.Context, msg *types.MsgTransfer) (*types.MsgTransferResponse, error) {
ctx := sdk.UnwrapSDKContext(goCtx)
params := k.Keeper.IbcTransfermiddleware.GetParams(ctx)
charge_coin := sdk.NewCoin(msg.Token.Denom, sdk.ZeroInt())
charge_coin := sdk.NewCoin(msg.Token.Denom, sdkmath.ZeroInt())
if params.ChannelFees != nil && len(params.ChannelFees) > 0 {
channelFee := findChannelParams(params.ChannelFees, msg.SourceChannel)
if channelFee != nil {
Expand Down
1 change: 0 additions & 1 deletion x/transfermiddleware/ibc_middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package transfermiddleware

import (
"cosmossdk.io/errors"
sdkmath "cosmossdk.io/math"
sdk "github.com/cosmos/cosmos-sdk/types"
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types"
Expand Down

0 comments on commit ece78ce

Please sign in to comment.