Skip to content

Commit e1478a4

Browse files
remove msg
1 parent deaf79f commit e1478a4

File tree

9 files changed

+70
-339
lines changed

9 files changed

+70
-339
lines changed

go.mod

+16-9
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ require (
1818
github.com/cosmos/cosmos-sdk/db v1.0.0-beta.1
1919
github.com/cosmos/go-bip39 v1.0.0
2020
github.com/cosmos/iavl v0.19.6
21+
github.com/cosmos/ibc-go/v6 v6.1.1
2122
github.com/cosmos/ledger-cosmos-go v0.12.2
2223
github.com/gogo/gateway v1.1.0
2324
github.com/gogo/protobuf v1.3.3
@@ -53,7 +54,8 @@ require (
5354
github.com/tidwall/btree v1.5.0
5455
golang.org/x/crypto v0.21.0
5556
golang.org/x/exp v0.0.0-20230310171629-522b1b587ee0
56-
google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9
57+
golang.org/x/net v0.23.0
58+
google.golang.org/genproto/googleapis/api v0.0.0-20240318140521-94a12d6c2237
5759
google.golang.org/grpc v1.64.0
5860
google.golang.org/protobuf v1.34.1
5961
pgregory.net/rapid v0.5.5
@@ -63,7 +65,6 @@ require (
6365

6466
require (
6567
cloud.google.com/go v0.112.1 // indirect
66-
cloud.google.com/go/compute v1.25.1 // indirect
6768
cloud.google.com/go/compute/metadata v0.3.0 // indirect
6869
cloud.google.com/go/iam v1.1.6 // indirect
6970
cloud.google.com/go/storage v1.38.0 // indirect
@@ -78,9 +79,7 @@ require (
7879
github.com/cespare/xxhash v1.1.0 // indirect
7980
github.com/cespare/xxhash/v2 v2.2.0 // indirect
8081
github.com/cometbft/cometbft-db v0.7.0 // indirect
81-
github.com/cosmos/gogoproto v1.4.8 // indirect
8282
github.com/cosmos/gorocksdb v1.2.0 // indirect
83-
github.com/cosmos/ibc-go/v6 v6.1.1 // indirect
8483
github.com/creachadair/taskgroup v0.3.2 // indirect
8584
github.com/danieljoos/wincred v1.1.2 // indirect
8685
github.com/davecgh/go-spew v1.1.1 // indirect
@@ -96,13 +95,15 @@ require (
9695
github.com/go-kit/kit v0.12.0 // indirect
9796
github.com/go-kit/log v0.2.1 // indirect
9897
github.com/go-logfmt/logfmt v0.5.1 // indirect
98+
github.com/go-logr/logr v1.4.1 // indirect
99+
github.com/go-logr/stdr v1.2.2 // indirect
99100
github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect
100101
github.com/golang/glog v1.2.0 // indirect
101102
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
102103
github.com/golang/snappy v0.0.4 // indirect
103104
github.com/google/btree v1.1.2 // indirect
104-
github.com/google/go-cmp v0.6.0 // indirect
105105
github.com/google/orderedcode v0.0.1 // indirect
106+
github.com/google/s2a-go v0.1.7 // indirect
106107
github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect
107108
github.com/googleapis/gax-go/v2 v2.12.2 // indirect
108109
github.com/gorilla/websocket v1.5.0 // indirect
@@ -147,14 +148,20 @@ require (
147148
github.com/zondax/ledger-go v0.14.1 // indirect
148149
go.etcd.io/bbolt v1.3.6 // indirect
149150
go.opencensus.io v0.24.0 // indirect
150-
golang.org/x/net v0.23.0 // indirect
151+
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.49.0 // indirect
152+
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0 // indirect
153+
go.opentelemetry.io/otel v1.24.0 // indirect
154+
go.opentelemetry.io/otel/metric v1.24.0 // indirect
155+
go.opentelemetry.io/otel/trace v1.24.0 // indirect
151156
golang.org/x/oauth2 v0.20.0 // indirect
157+
golang.org/x/sync v0.6.0 // indirect
152158
golang.org/x/sys v0.18.0 // indirect
153159
golang.org/x/term v0.18.0 // indirect
154160
golang.org/x/text v0.15.0 // indirect
155-
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
161+
golang.org/x/time v0.5.0 // indirect
156162
google.golang.org/api v0.169.0 // indirect
157-
google.golang.org/appengine v1.6.8 // indirect
163+
google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 // indirect
164+
google.golang.org/genproto/googleapis/rpc v0.0.0-20240318140521-94a12d6c2237 // indirect
158165
gopkg.in/ini.v1 v1.67.0 // indirect
159166
gopkg.in/yaml.v2 v2.4.0 // indirect
160167
gopkg.in/yaml.v3 v3.0.1 // indirect
@@ -168,7 +175,7 @@ replace (
168175
// TODO: remove it: https://github.com/cosmos/cosmos-sdk/issues/13134
169176
github.com/dgrijalva/jwt-go => github.com/golang-jwt/jwt/v4 v4.4.2
170177

171-
// Fix upstream GHSA-h395-qcrw-5vmq and GHSA-3vp4-m3rf-835h vulnerabilities.
178+
// Fix upstream GHSA-h395-qcrw-5vmq and GHSA-3vp4-m3rf-835h vulnerabilities.
172179
// TODO Remove it: https://github.com/cosmos/cosmos-sdk/issues/10409
173180
github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.0
174181
github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1

go.sum

+52-55
Large diffs are not rendered by default.

x/accumulator/handler.go

+2-15
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,17 @@
11
package accumulator
22

33
import (
4-
"fmt"
5-
"github.com/cosmos/cosmos-sdk/x/accumulator/keeper"
6-
"github.com/cosmos/cosmos-sdk/x/accumulator/types"
7-
84
sdk "github.com/cosmos/cosmos-sdk/types"
9-
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
5+
"github.com/cosmos/cosmos-sdk/x/accumulator/keeper"
106
)
117

128
// NewHandler ...
139
func NewHandler(k keeper.Keeper) sdk.Handler {
14-
msgServer := keeper.NewMsgServerImpl(k)
1510
// this line is used by starport scaffolding # handler/msgServer
1611

1712
return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) {
18-
ctx = ctx.WithEventManager(sdk.NewEventManager())
1913

20-
switch msg := msg.(type) {
21-
case *types.DistributeTokensRequest:
22-
res, err := msgServer.DistributeTokens(sdk.WrapSDKContext(ctx), msg)
23-
return sdk.WrapServiceResult(ctx, res, err)
24-
default:
25-
errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg)
26-
return nil, sdkerrors.Wrap(sdkerrors.ErrUnknownRequest, errMsg)
27-
}
14+
return nil, nil
2815
}
2916

3017
// this line is used by starport scaffolding # 1

x/accumulator/module.go

-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,6 @@ func NewAppModule(
125125

126126
// RegisterServices registers a gRPC query service to respond to the module-specific gRPC queries
127127
func (am AppModule) RegisterServices(cfg module.Configurator) {
128-
types.RegisterMsgServiceServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper))
129128
types.RegisterQueryServer(cfg.QueryServer(), am.keeper)
130129
}
131130

x/accumulator/types/codec.go

-8
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,13 @@ package types
33
import (
44
"github.com/cosmos/cosmos-sdk/codec"
55
cdctypes "github.com/cosmos/cosmos-sdk/codec/types"
6-
sdk "github.com/cosmos/cosmos-sdk/types"
7-
"github.com/cosmos/cosmos-sdk/types/msgservice"
86
)
97

108
func RegisterCodec(cdc *codec.LegacyAmino) {
119
// this line is used by starport scaffolding # 2
12-
cdc.RegisterConcrete(&DistributeTokensRequest{}, "accumulator/DistributeTokens", nil)
1310
}
1411

1512
func RegisterInterfaces(registry cdctypes.InterfaceRegistry) {
1613
// this line is used by starport scaffolding # 3
1714

18-
registry.RegisterImplementations((*sdk.Msg)(nil),
19-
&DistributeTokensRequest{},
20-
)
21-
22-
msgservice.RegisterMsgServiceDesc(registry, &_MsgService_serviceDesc)
2315
}

x/distribution/client/testutil/suite.go

-5
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,6 @@ func (s *IntegrationTestSuite) SetupSuite() {
4646
var mintData minttypes.GenesisState
4747
s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[minttypes.ModuleName], &mintData))
4848

49-
inflation := sdk.MustNewDecFromStr("1.0")
50-
mintData.Minter.Inflation = inflation
51-
mintData.Params.InflationMin = inflation
52-
mintData.Params.InflationMax = inflation
53-
5449
mintDataBz, err := s.cfg.Codec.MarshalJSON(&mintData)
5550
s.Require().NoError(err)
5651
genesisState[minttypes.ModuleName] = mintDataBz

x/mint/client/testutil/cli_test.go

-18
This file was deleted.

x/mint/client/testutil/grpc.go

-64
This file was deleted.

0 commit comments

Comments
 (0)