Skip to content

Commit

Permalink
feat: updated mechanism for fees in custom denoms
Browse files Browse the repository at this point in the history
  • Loading branch information
Lockwarr committed Jan 9, 2025
1 parent dcfe337 commit 25098cc
Show file tree
Hide file tree
Showing 67 changed files with 3,129 additions and 771 deletions.
2 changes: 1 addition & 1 deletion app/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"

taxkeeper "github.com/Nolus-Protocol/nolus-core/x/tax/keeper"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"
)

// HandlerOptions are the options required for constructing a default SDK AnteHandler.
Expand Down
6 changes: 2 additions & 4 deletions app/keepers/keepers.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ import (
mintkeeper "github.com/Nolus-Protocol/nolus-core/x/mint/keeper"
minttypes "github.com/Nolus-Protocol/nolus-core/x/mint/types"
taxkeeper "github.com/Nolus-Protocol/nolus-core/x/tax/keeper"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"
"github.com/Nolus-Protocol/nolus-core/x/vestings"
vestingskeeper "github.com/Nolus-Protocol/nolus-core/x/vestings/keeper"
vestingstypes "github.com/Nolus-Protocol/nolus-core/x/vestings/types"
Expand Down Expand Up @@ -387,7 +387,7 @@ func (appKeepers *AppKeepers) NewAppKeepers(
contractmanager.NewSudoLimitWrapper(appKeepers.ContractManagerKeeper, &appKeepers.WasmKeeper),
appKeepers.FeeRefunderKeeper,
appKeepers.BankKeeper,
func(ctx sdk.Context) string { return appKeepers.TaxKeeper.ContractAddress(ctx) },
func(ctx sdk.Context) string { return appKeepers.TaxKeeper.TreasuryAddress(ctx) },
authtypes.NewModuleAddress(govtypes.ModuleName).String(),
)
appKeepers.InterchainTxsModule = interchaintxs.NewAppModule(appCodec, *appKeepers.InterchainTxsKeeper, appKeepers.AccountKeeper, appKeepers.BankKeeper)
Expand Down Expand Up @@ -463,7 +463,6 @@ func (appKeepers *AppKeepers) NewAppKeepers(
taxKeeper := taxkeeper.NewKeeper(
appCodec,
runtime.NewKVStoreService(appKeepers.keys[taxtypes.StoreKey]),
appKeepers.WasmKeeper,
authtypes.NewModuleAddress(govtypes.ModuleName).String(),
)
appKeepers.TaxKeeper = &taxKeeper
Expand Down Expand Up @@ -519,7 +518,6 @@ func initParamsKeeper(
appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino, key, tkey storetypes.StoreKey,
) *paramskeeper.Keeper {
paramsKeeper := paramskeeper.NewKeeper(appCodec, legacyAmino, key, tkey)
paramsKeeper.Subspace(taxtypes.ModuleName).WithKeyTable(taxtypes.ParamKeyTable())
paramsKeeper.Subspace(authtypes.ModuleName).WithKeyTable(authtypes.ParamKeyTable()) //nolint:staticcheck
paramsKeeper.Subspace(banktypes.ModuleName).WithKeyTable(banktypes.ParamKeyTable()) //nolint:staticcheck
paramsKeeper.Subspace(stakingtypes.ModuleName).WithKeyTable(stakingtypes.ParamKeyTable()) //nolint:staticcheck
Expand Down
2 changes: 1 addition & 1 deletion app/keepers/keys.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported"

minttypes "github.com/Nolus-Protocol/nolus-core/x/mint/types"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"
vestingstypes "github.com/Nolus-Protocol/nolus-core/x/vestings/types"

wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types"
Expand Down
2 changes: 1 addition & 1 deletion app/modules.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ import (
"github.com/Nolus-Protocol/nolus-core/x/mint"
minttypes "github.com/Nolus-Protocol/nolus-core/x/mint/types"
"github.com/Nolus-Protocol/nolus-core/x/tax"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"
"github.com/Nolus-Protocol/nolus-core/x/vestings"
vestingstypes "github.com/Nolus-Protocol/nolus-core/x/vestings/types"

Expand Down
2 changes: 1 addition & 1 deletion app/sim_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ import (

"github.com/Nolus-Protocol/nolus-core/app/params"
minttypes "github.com/Nolus-Protocol/nolus-core/x/mint/types"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxmoduletypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"

contractmanagermoduletypes "github.com/Nolus-Protocol/nolus-core/x/contractmanager/types"
feetypes "github.com/Nolus-Protocol/nolus-core/x/feerefunder/types"
Expand Down
2 changes: 1 addition & 1 deletion app/test_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

"github.com/Nolus-Protocol/nolus-core/app/params"
minttypes "github.com/Nolus-Protocol/nolus-core/x/mint/types"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/types"
taxtypes "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2"
)

// returns context and app with params set on account keeper.
Expand Down
10 changes: 5 additions & 5 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -194,14 +194,14 @@ require (
go.opentelemetry.io/otel/metric v1.24.0 // indirect
go.opentelemetry.io/otel/trace v1.24.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.28.0 // indirect
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8 // indirect
golang.org/x/net v0.30.0 // indirect
golang.org/x/oauth2 v0.23.0 // indirect
golang.org/x/sync v0.8.0 // indirect
golang.org/x/sys v0.26.0 // indirect
golang.org/x/term v0.25.0 // indirect
golang.org/x/text v0.19.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/term v0.27.0 // indirect
golang.org/x/text v0.21.0 // indirect
golang.org/x/time v0.5.0 // indirect
google.golang.org/api v0.186.0 // indirect
google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094 // indirect
Expand Down
20 changes: 10 additions & 10 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1060,8 +1060,8 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.28.0 h1:GBDwsMXVQi34v5CCYUm2jkJvu4cbtru2U4TN2PSyQnw=
golang.org/x/crypto v0.28.0/go.mod h1:rmgy+3RHxRZMyY0jjAJShp2zgEdOqj2AO7U0pYmeQ7U=
golang.org/x/crypto v0.31.0 h1:ihbySMvVjLAeSH1IbfcRTkD/iNscyz8rGzjF/E5hV6U=
golang.org/x/crypto v0.31.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
Expand Down Expand Up @@ -1203,8 +1203,8 @@ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJ
golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ=
golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sync v0.10.0 h1:3NQrjDixjgGwUOCaF8w2+VYHv0Ve/vGYSbdkTa98gmQ=
golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
Expand Down Expand Up @@ -1299,13 +1299,13 @@ golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.26.0 h1:KHjCJyddX0LoSTb3J+vWpupP9p0oznkqVk/IfjymZbo=
golang.org/x/sys v0.26.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.28.0 h1:Fksou7UEQUWlKvIdsqzJmUmCX3cZuD2+P3XyyzwMhlA=
golang.org/x/sys v0.28.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.25.0 h1:WtHI/ltw4NvSUig5KARz9h521QvRC8RmF/cuYqifU24=
golang.org/x/term v0.25.0/go.mod h1:RPyXicDX+6vLxogjjRxjgD2TKtmAO6NZBsBRfrOLu7M=
golang.org/x/term v0.27.0 h1:WP60Sv1nlK1T6SupCHbXzSaN0b9wUmsPoRS9b61A23Q=
golang.org/x/term v0.27.0/go.mod h1:iMsnZpn0cago0GOrHO2+Y7u7JPn5AylBrcoWkElMTSM=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
Expand All @@ -1316,8 +1316,8 @@ golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.19.0 h1:kTxAhCbGbxhK0IwgSKiMO5awPoDQ0RpfiVYBfK860YM=
golang.org/x/text v0.19.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY=
golang.org/x/text v0.21.0 h1:zyQAAkrwaneQ066sspRyJaG9VNi/YJ1NfzcGB3hZ/qo=
golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ=
golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
Expand Down
8 changes: 4 additions & 4 deletions proto/buf.lock
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ deps:
- remote: buf.build
owner: cosmos
repository: ibc
commit: 41fbc441e4d645119d275150719c5441
digest: shake256:a61d3e152909abddc91dcc1aec8ac997007bebd48a7921bc243681c708e6c9068f6484aa7ed4e6ff60101d3422c98744a4a5294bbda6aacdba07f1dfa4291020
commit: 40034a92f14b4be09e17e7104309daff
digest: shake256:8a6b098454c306c64b382c2dfbf5a5533ad9cf64e0b068250787ef73e9a2d84abf58c90d5133b9bbbdbe631f6e62c9810b31d396fc7637eaf3c11033d9fef155
- remote: buf.build
owner: cosmos
repository: ics23
Expand All @@ -29,5 +29,5 @@ deps:
- remote: buf.build
owner: googleapis
repository: googleapis
commit: e7f8d366f5264595bcc4cd4139af9973
digest: shake256:e5e5f1c12f82e028ea696faa43b4f9dc6258a6d1226282962a8c8b282e10946281d815884f574bd279ebd9cd7588629beb3db17b892af6c33b56f92f8f67f509
commit: acd896313c55464b993332136ded1b6e
digest: shake256:66626d5e4d9c8ecf25cd72bdbfbbf62b9a68e9e9c33dab6b9b39a53a67063eeba6b8493247dd6d6240b1ac1c32eb2dc311484e67dd7d271884a960c2e5ce8c9a
1 change: 1 addition & 0 deletions proto/nolus/tax/v1beta1/genesis.proto
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ import "nolus/tax/v1beta1/params.proto";

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/types";

// Deprecated: please use the GenesisState message from v2.
// GenesisState defines the tax module's genesis state.
message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; }
8 changes: 7 additions & 1 deletion proto/nolus/tax/v1beta1/params.proto
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,31 @@ import "gogoproto/gogo.proto";

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/types";

// Deprecated: please use the Params message from v2.
// Params defines the parameters for the module.
message Params {
option deprecated = true;
option (gogoproto.goproto_stringer) = false;

int32 fee_rate = 1;
string contract_address = 2;
string base_denom = 3;
repeated FeeParam fee_params = 4;
repeated FeeParam fee_params = 4;
}

// Deprecated: please use the message from v2.
// Defines the accepted fees with corresponding oracle and profit addresses
message FeeParam {
option deprecated = true;
string oracle_address = 1;
string profit_address = 2;
repeated DenomTicker accepted_denoms = 3;
}

// Deprecated: please use the message from v2.
// DenomTicker will be used to define accepted denoms and their ticker
message DenomTicker {
option deprecated = true;
string denom = 1;
string ticker = 2;
}
3 changes: 3 additions & 0 deletions proto/nolus/tax/v1beta1/query.proto
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,18 @@ option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/types";

// Query defines the gRPC querier service.
service Query {
// Deprecated: please use the Params query from v2.
// Parameters queries the parameters of the module.
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
option (google.api.http).get = "/nolus/tax/v1beta1/params";
}
}

// Deprecated: please use the QueryParamsRequest message from v2.
// QueryParamsRequest is request type for the Query/Params RPC method.
message QueryParamsRequest {}

// Deprecated: please use the QueryParamsResponse message from v2.
// QueryParamsResponse is response type for the Query/Params RPC method.
message QueryParamsResponse {
// params holds all the parameters of this module.
Expand Down
4 changes: 4 additions & 0 deletions proto/nolus/tax/v1beta1/tx.proto
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,20 @@ import "cosmos_proto/cosmos.proto";
// Msg defines the x/tax Msg service.
service Msg {
option (cosmos.msg.v1.service) = true;
// Deprecated: please use the alternative UpdateParams message from v2.
// UpdateParams defines a governance operation for updating the x/tax module
// parameters. The authority is hard-coded to the x/gov module account.
//
// Since: cosmos-sdk 0.47
rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse);
}

// Deprecated: please use the alternative MsgUpdateParams message from v2.
// MsgUpdateParams is the Msg/UpdateParams request type.
//
// Since: cosmos-sdk 0.47
message MsgUpdateParams {
option deprecated = true;
option (cosmos.msg.v1.signer) = "authority";

// authority is the address of the governance account.
Expand All @@ -34,6 +37,7 @@ message MsgUpdateParams {
Params params = 2 [ (gogoproto.nullable) = false ];
}

// Deprecated: please use the alternative MsgUpdateParamsResponse message from v2.
// MsgUpdateParamsResponse defines the response structure for executing a
// MsgUpdateParams message.
//
Expand Down
10 changes: 10 additions & 0 deletions proto/nolus/tax/v2/genesis.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
syntax = "proto3";
package nolus.tax.v2;

import "gogoproto/gogo.proto";
import "nolus/tax/v2/params.proto";

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2";

// GenesisState defines the tax module's genesis state.
message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; }
29 changes: 29 additions & 0 deletions proto/nolus/tax/v2/params.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
syntax = "proto3";
package nolus.tax.v2;

import "gogoproto/gogo.proto";

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2";

message Params {
option (gogoproto.goproto_stringer) = false;

int32 fee_rate = 1;
string base_denom = 2;
repeated DexFeeParams dex_fee_params = 3;
string treasury_address = 4;
}

// Defines the accepted fees with corresponding min prices and profit addresses
message DexFeeParams {
string profit_address = 1;
repeated DenomPrice accepted_denoms_min_prices = 2;
}

message DenomPrice {
string denom = 1;
// ticker will only be used for a more readable format for the users
string ticker = 2;
float min_price = 3;
}

25 changes: 25 additions & 0 deletions proto/nolus/tax/v2/query.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
syntax = "proto3";
package nolus.tax.v2;

import "gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "nolus/tax/v2/params.proto";

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2";

// Query defines the gRPC querier service.
service Query {
// Parameters queries the parameters of the module.
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
option (google.api.http).get = "/nolus/tax/v2/params";
}
}

// QueryParamsRequest is request type for the Query/Params RPC method.
message QueryParamsRequest {}

// QueryParamsResponse is response type for the Query/Params RPC method.
message QueryParamsResponse {
// params holds all the parameters of this module.
Params params = 1 [ (gogoproto.nullable) = false ];
}
41 changes: 41 additions & 0 deletions proto/nolus/tax/v2/tx.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
syntax = "proto3";
package nolus.tax.v2;

option go_package = "github.com/Nolus-Protocol/nolus-core/x/tax/typesv2";

import "cosmos/msg/v1/msg.proto";
import "nolus/tax/v2/params.proto";

import "gogoproto/gogo.proto";
import "cosmos_proto/cosmos.proto";

// Msg defines the x/tax Msg service.
service Msg {
option (cosmos.msg.v1.service) = true;
// UpdateParams defines a governance operation for updating the x/tax module
// parameters. The authority is hard-coded to the x/gov module account.
//
// Since: cosmos-sdk 0.47
rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse);
}

// MsgUpdateParams is the Msg/UpdateParams request type.
//
// Since: cosmos-sdk 0.47
message MsgUpdateParams {
option (cosmos.msg.v1.signer) = "authority";

// authority is the address of the governance account.
string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];

// params defines the x/tax parameters to update.
//
// NOTE: All parameters must be supplied.
Params params = 2 [ (gogoproto.nullable) = false ];
}

// MsgUpdateParamsResponse defines the response structure for executing a
// MsgUpdateParams message.
//
// Since: cosmos-sdk 0.47
message MsgUpdateParamsResponse {}
Loading

0 comments on commit 25098cc

Please sign in to comment.