diff --git a/go.mod b/go.mod index 0ecda19c..033f8e5d 100644 --- a/go.mod +++ b/go.mod @@ -29,7 +29,6 @@ require ( github.com/cosmos/rosetta v0.0.0-20231205133638-3bc76705a1c6 github.com/ethereum/go-ethereum v1.10.26 github.com/evmos/ethermint v0.22.0 - github.com/gogo/protobuf v1.3.2 github.com/golang/protobuf v1.5.4 github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 @@ -88,6 +87,7 @@ require ( github.com/go-ole/go-ole v1.2.6 // indirect github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 // indirect github.com/gogo/googleapis v1.4.1 // indirect + github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/mock v1.6.0 // indirect github.com/google/go-cmp v0.6.0 // indirect diff --git a/scripts/proto-tools-installer.sh b/scripts/proto-tools-installer.sh index 1a947df7..2d9d24e6 100755 --- a/scripts/proto-tools-installer.sh +++ b/scripts/proto-tools-installer.sh @@ -83,18 +83,6 @@ f_install_buf() { f_print_done } -f_install_protoc_gen_gocosmos() { - f_print_installing_with_padding protoc-gen-gocosmos - - if ! grep "github.com/gogo/protobuf => github.com/regen-network/protobuf" go.mod &>/dev/null ; then - echo -e "\tPlease run this command from somewhere inside the canto folder." - return 1 - fi - - go get github.com/regen-network/cosmos-proto/protoc-gen-gocosmos 2>/dev/null - f_print_done -} - f_install_protoc_gen_grpc_gateway() { f_print_installing_with_padding protoc-gen-grpc-gateway f_needs_install "${DESTDIR}/${PREFIX}/bin/protoc-gen-grpc-gateway" || return 0 @@ -149,7 +137,6 @@ f_ensure_tools f_ensure_dirs f_install_protoc f_install_buf -f_install_protoc_gen_gocosmos f_install_protoc_gen_grpc_gateway f_install_protoc_gen_swagger f_install_clang_format diff --git a/x/coinswap/keeper/keeper.go b/x/coinswap/keeper/keeper.go index 34c5f644..eb389c00 100644 --- a/x/coinswap/keeper/keeper.go +++ b/x/coinswap/keeper/keeper.go @@ -4,7 +4,7 @@ import ( "fmt" "strconv" - gogotypes "github.com/gogo/protobuf/types" + gogoprototypes "github.com/cosmos/gogoproto/types" "cosmossdk.io/core/store" errorsmod "cosmossdk.io/errors" @@ -352,7 +352,7 @@ func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { // SetStandardDenom sets the standard denom for the coinswap module. func (k Keeper) SetStandardDenom(ctx sdk.Context, denom string) error { store := k.storeService.OpenKVStore(ctx) - denomWrap := gogotypes.StringValue{Value: denom} + denomWrap := gogoprototypes.StringValue{Value: denom} bz := k.cdc.MustMarshal(&denomWrap) err := store.Set(types.KeyStandardDenom, bz) if err != nil { @@ -369,7 +369,7 @@ func (k Keeper) GetStandardDenom(ctx sdk.Context) (string, error) { return "", err } - var denomWrap = gogotypes.StringValue{} + var denomWrap = gogoprototypes.StringValue{} k.cdc.MustUnmarshal(bz, &denomWrap) return denomWrap.Value, nil } diff --git a/x/coinswap/keeper/pool.go b/x/coinswap/keeper/pool.go index 406b9e96..eeeb8958 100644 --- a/x/coinswap/keeper/pool.go +++ b/x/coinswap/keeper/pool.go @@ -3,7 +3,7 @@ package keeper import ( "fmt" - gogotypes "github.com/gogo/protobuf/types" + gogoprototypes "github.com/cosmos/gogoproto/types" errorsmod "cosmossdk.io/errors" storetypes "cosmossdk.io/store/types" @@ -64,7 +64,7 @@ func (k Keeper) GetPoolByLptDenom(ctx sdk.Context, lptDenom string) (types.Pool, return types.Pool{}, false } - poolId := &gogotypes.StringValue{} + poolId := &gogoprototypes.StringValue{} k.cdc.MustUnmarshal(bz, poolId) return k.GetPool(ctx, poolId.Value) } @@ -138,7 +138,7 @@ func (k Keeper) setPool(ctx sdk.Context, pool *types.Pool) { store.Set(types.GetPoolKey(pool.Id), bz) // save by lpt denom - poolId := &gogotypes.StringValue{Value: pool.Id} + poolId := &gogoprototypes.StringValue{Value: pool.Id} poolIdBz := k.cdc.MustMarshal(poolId) store.Set(types.GetLptDenomKey(pool.LptDenom), poolIdBz) }