From c307001349d9171d45855aeedd8c4ff877cf7cba Mon Sep 17 00:00:00 2001 From: levisyin <150114626+levisyin@users.noreply.github.com> Date: Mon, 8 Jan 2024 20:42:24 +0800 Subject: [PATCH 01/28] refactor(client): check name validation for `keys add|import|rename` (#18950) --- CHANGELOG.md | 1 + client/keys/add.go | 4 ++++ client/keys/add_test.go | 11 +++++++++++ client/keys/import.go | 10 ++++++++++ client/keys/import_test.go | 34 ++++++++++++++++++++++++++++++++++ client/keys/rename.go | 5 +++++ client/keys/rename_test.go | 4 ++++ 7 files changed, 69 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d41323763cf5..f014579d9206 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,6 +55,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* (client/keys) [#18950](https://github.com/cosmos/cosmos-sdk/pull/18950) Improve ` keys add`, ` keys import` and ` keys rename` by checking name validation. * (baseapp) [#18915](https://github.com/cosmos/cosmos-sdk/pull/18915) Add a new `ExecModeVerifyVoteExtension` exec mode and ensure it's populated in the `Context` during `VerifyVoteExtension` execution. * (types) [#18888](https://github.com/cosmos/cosmos-sdk/pull/18888) Speedup DecCoin.Sort() if len(coins) <= 1 * (types) [#18875](https://github.com/cosmos/cosmos-sdk/pull/18875) Speedup coins.Sort() if len(coins) <= 1 diff --git a/client/keys/add.go b/client/keys/add.go index 13dd35ec4764..4e6e4f27f756 100644 --- a/client/keys/add.go +++ b/client/keys/add.go @@ -8,6 +8,7 @@ import ( "errors" "fmt" "sort" + "strings" "github.com/cosmos/go-bip39" "github.com/spf13/cobra" @@ -123,6 +124,9 @@ func runAddCmd(ctx client.Context, cmd *cobra.Command, args []string, inBuf *buf var err error name := args[0] + if strings.TrimSpace(name) == "" { + return errors.New("the provided name is invalid or empty after trimming whitespace") + } interactive, _ := cmd.Flags().GetBool(flagInteractive) kb := ctx.Keyring outputFormat := ctx.OutputFormat diff --git a/client/keys/add_test.go b/client/keys/add_test.go index 6dff014b2263..95cf3347810a 100644 --- a/client/keys/add_test.go +++ b/client/keys/add_test.go @@ -47,6 +47,17 @@ func Test_runAddCmdBasic(t *testing.T) { _ = kb.Delete("keyname2") }) + // test empty name + cmd.SetArgs([]string{ + "", + fmt.Sprintf("--%s=%s", flags.FlagKeyringDir, kbHome), + fmt.Sprintf("--%s=%s", flags.FlagOutput, flags.OutputFormatText), + fmt.Sprintf("--%s=%s", flags.FlagKeyType, hd.Secp256k1Type), + fmt.Sprintf("--%s=%s", flags.FlagKeyringBackend, keyring.BackendTest), + }) + mockIn.Reset("y\n") + require.ErrorContains(t, cmd.ExecuteContext(ctx), "the provided name is invalid or empty after trimming whitespace") + cmd.SetArgs([]string{ "keyname1", fmt.Sprintf("--%s=%s", flags.FlagKeyringDir, kbHome), diff --git a/client/keys/import.go b/client/keys/import.go index 98ccb6547ff0..9a86da287978 100644 --- a/client/keys/import.go +++ b/client/keys/import.go @@ -2,8 +2,10 @@ package keys import ( "bufio" + "errors" "fmt" "os" + "strings" "github.com/spf13/cobra" @@ -26,6 +28,10 @@ func ImportKeyCommand() *cobra.Command { if err != nil { return err } + name := args[0] + if strings.TrimSpace(name) == "" { + return errors.New("the provided name is invalid or empty after trimming whitespace") + } buf := bufio.NewReader(clientCtx.Input) bz, err := os.ReadFile(args[1]) @@ -54,6 +60,10 @@ func ImportKeyHexCommand() *cobra.Command { if err != nil { return err } + name := args[0] + if strings.TrimSpace(name) == "" { + return errors.New("the provided name is invalid or empty after trimming whitespace") + } keyType, _ := cmd.Flags().GetString(flags.FlagKeyType) return clientCtx.Keyring.ImportPrivKeyHex(args[0], args[1], keyType) }, diff --git a/client/keys/import_test.go b/client/keys/import_test.go index 0cff5065d82c..006f8ce672b2 100644 --- a/client/keys/import_test.go +++ b/client/keys/import_test.go @@ -177,3 +177,37 @@ func Test_runImportHexCmd(t *testing.T) { }) } } + +func Test_runImportCmdWithEmptyName(t *testing.T) { + cmd := ImportKeyCommand() + cmd.Flags().AddFlagSet(Commands().PersistentFlags()) + mockIn := testutil.ApplyMockIODiscardOutErr(cmd) + // Now add a temporary keybase + kbHome := t.TempDir() + cdc := moduletestutil.MakeTestEncodingConfig().Codec + kb, err := keyring.New(sdk.KeyringServiceName(), keyring.BackendTest, kbHome, mockIn, cdc) + require.NoError(t, err) + + clientCtx := client.Context{}. + WithKeyringDir(kbHome). + WithKeyring(kb). + WithInput(mockIn). + WithCodec(cdc) + ctx := context.WithValue(context.Background(), client.ClientContextKey, &clientCtx) + cmd.SetArgs([]string{ + "", "fake-file", + fmt.Sprintf("--%s=%s", flags.FlagKeyringBackend, keyring.BackendTest), + }) + + require.ErrorContains(t, cmd.ExecuteContext(ctx), "the provided name is invalid or empty after trimming whitespace") + + cmd = ImportKeyHexCommand() + cmd.Flags().AddFlagSet(Commands().PersistentFlags()) + testutil.ApplyMockIODiscardOutErr(cmd) + cmd.SetArgs([]string{ + "", "fake-hex", + fmt.Sprintf("--%s=%s", flags.FlagKeyringBackend, keyring.BackendTest), + }) + + require.ErrorContains(t, cmd.ExecuteContext(ctx), "the provided name is invalid or empty after trimming whitespace") +} diff --git a/client/keys/rename.go b/client/keys/rename.go index f703c60f20eb..f37d2307e12b 100644 --- a/client/keys/rename.go +++ b/client/keys/rename.go @@ -2,7 +2,9 @@ package keys import ( "bufio" + "errors" "fmt" + "strings" "github.com/spf13/cobra" @@ -31,6 +33,9 @@ private keys stored in a ledger device cannot be renamed with the CLI. } oldName, newName := args[0], args[1] + if strings.TrimSpace(newName) == "" { + return errors.New("the new name cannot be empty or consist solely of whitespace") + } k, err := clientCtx.Keyring.Key(oldName) if err != nil { diff --git a/client/keys/rename_test.go b/client/keys/rename_test.go index dad91168f07b..62253d382be5 100644 --- a/client/keys/rename_test.go +++ b/client/keys/rename_test.go @@ -27,6 +27,7 @@ func Test_runRenameCmd(t *testing.T) { yesF, _ := cmd.Flags().GetBool(flagYes) require.False(t, yesF) + invalidName := "" fakeKeyName1 := "runRenameCmd_Key1" fakeKeyName2 := "runRenameCmd_Key2" @@ -46,6 +47,9 @@ func Test_runRenameCmd(t *testing.T) { ctx := context.WithValue(context.Background(), client.ClientContextKey, &clientCtx) + cmd.SetArgs([]string{fakeKeyName1, invalidName, fmt.Sprintf("--%s=%s", flags.FlagKeyringDir, kbHome)}) + require.ErrorContains(t, cmd.ExecuteContext(ctx), "the new name cannot be empty or consist solely of whitespace") + // rename a key 'blah' which doesnt exist cmd.SetArgs([]string{"blah", "blaah", fmt.Sprintf("--%s=%s", flags.FlagKeyringDir, kbHome)}) err = cmd.ExecuteContext(ctx) From 20b1da7a2ecad161d40db4d3f8dbf4821ddf6d3d Mon Sep 17 00:00:00 2001 From: Aleksandr Bezobchuk Date: Mon, 8 Jan 2024 14:26:10 -0500 Subject: [PATCH 02/28] refactor(store/v2): Use Core Iterator (#18957) Co-authored-by: marbar3778 Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com> --- core/store/store.go | 52 +++++++++++++---------------- store/database.go | 7 ++-- store/go.mod | 2 ++ store/iterator.go | 38 --------------------- store/kv/branch/iterator.go | 35 +++++++++++-------- store/kv/branch/store.go | 13 ++++---- store/kv/branch/store_test.go | 16 --------- store/kv/mem/iterator.go | 14 ++++---- store/kv/mem/store.go | 5 +-- store/kv/mem/store_test.go | 9 +---- store/kv/trace/iterator.go | 15 +++++---- store/kv/trace/store.go | 5 +-- store/kv/trace/store_test.go | 2 -- store/storage/database.go | 5 +-- store/storage/pebbledb/db.go | 5 +-- store/storage/pebbledb/iterator.go | 29 ++++++++-------- store/storage/rocksdb/db.go | 5 +-- store/storage/rocksdb/db_test.go | 2 -- store/storage/rocksdb/iterator.go | 14 ++++---- store/storage/sqlite/db.go | 7 ++-- store/storage/sqlite/db_test.go | 2 -- store/storage/sqlite/iterator.go | 16 +++++---- store/storage/storage_test_suite.go | 2 -- store/storage/store.go | 5 +-- store/store.go | 5 +-- 25 files changed, 131 insertions(+), 179 deletions(-) delete mode 100644 store/iterator.go diff --git a/core/store/store.go b/core/store/store.go index 2969ef29b9d3..8943390cc5d7 100644 --- a/core/store/store.go +++ b/core/store/store.go @@ -30,32 +30,15 @@ type KVStore interface { ReverseIterator(start, end []byte) (Iterator, error) } -// Iterator represents an iterator over a domain of keys. Callers must call Close when done. -// No writes can happen to a domain while there exists an iterator over it, some backends may take -// out database locks to ensure this will not happen. +// Iterator represents an iterator over a domain of keys. Callers must call +// Close when done. No writes can happen to a domain while there exists an +// iterator over it. Some backends may take out database locks to ensure this +// will not happen. // -// Callers must make sure the iterator is valid before calling any methods on it, otherwise -// these methods will panic. This is in part caused by most backend databases using this convention. -// -// As with DB, keys and values should be considered read-only, and must be copied before they are -// modified. -// -// Typical usage: -// -// var itr Iterator = ... -// defer itr.Close() -// -// for ; itr.Valid(); itr.Next() { -// k, v := itr.Key(); itr.Value() -// ... -// } -// -// if err := itr.Error(); err != nil { -// ... -// } +// Callers must make sure the iterator is valid before calling any methods on it, +// otherwise these methods will panic. type Iterator interface { // Domain returns the start (inclusive) and end (exclusive) limits of the iterator. - // CONTRACT: start, end readonly []byte Domain() (start, end []byte) // Valid returns whether the current iterator is valid. Once invalid, the Iterator remains @@ -67,12 +50,13 @@ type Iterator interface { Next() // Key returns the key at the current position. Panics if the iterator is invalid. - // CONTRACT: key readonly []byte - Key() (key []byte) + // Note, the key returned should be a copy and thus safe for modification. + Key() []byte - // Value returns the value at the current position. Panics if the iterator is invalid. - // CONTRACT: value readonly []byte - Value() (value []byte) + // Value returns the value at the current position. Panics if the iterator is + // invalid. + // Note, the value returned should be a copy and thus safe for modification. + Value() []byte // Error returns the last error encountered by the iterator, if any. Error() error @@ -80,3 +64,15 @@ type Iterator interface { // Close closes the iterator, releasing any allocated resources. Close() error } + +// IteratorCreator defines an interface for creating forward and reverse iterators. +type IteratorCreator interface { + // Iterator creates a new iterator for the given store name and domain, where + // domain is defined by [start, end). Note, both start and end are optional. + Iterator(storeKey string, start, end []byte) (Iterator, error) + + // ReverseIterator creates a new reverse iterator for the given store name + // and domain, where domain is defined by [start, end). Note, both start and + // end are optional. + ReverseIterator(storeKey string, start, end []byte) (Iterator, error) +} diff --git a/store/database.go b/store/database.go index 992dd3db4684..2df28059a490 100644 --- a/store/database.go +++ b/store/database.go @@ -3,6 +3,7 @@ package store import ( "io" + corestore "cosmossdk.io/core/store" ics23 "github.com/cosmos/ics23/go" ) @@ -38,7 +39,7 @@ type Writer interface { type Database interface { Reader Writer - IteratorCreator + corestore.IteratorCreator io.Closer } @@ -50,8 +51,8 @@ type VersionedDatabase interface { GetLatestVersion() (uint64, error) SetLatestVersion(version uint64) error - Iterator(storeKey string, version uint64, start, end []byte) (Iterator, error) - ReverseIterator(storeKey string, version uint64, start, end []byte) (Iterator, error) + Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) + ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) ApplyChangeset(version uint64, cs *Changeset) error diff --git a/store/go.mod b/store/go.mod index 1a1d22508ed0..2f657cb22282 100644 --- a/store/go.mod +++ b/store/go.mod @@ -68,3 +68,5 @@ require ( gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect ) + +replace cosmossdk.io/core => ../core diff --git a/store/iterator.go b/store/iterator.go deleted file mode 100644 index fa49b715be07..000000000000 --- a/store/iterator.go +++ /dev/null @@ -1,38 +0,0 @@ -package store - -// Iterator defines an interface for iterating over a domain of key/value pairs. -type Iterator interface { - // Domain returns the start (inclusive) and end (exclusive) limits of the iterator. - Domain() ([]byte, []byte) - - // Valid returns if the iterator is currently valid. - Valid() bool - - // Error returns any accumulated error. Error() should be called after all - // key/value pairs have been exhausted, i.e. after Next() has returned false. - Error() error - - // Key returns the key of the current key/value pair, or nil if done. - Key() []byte - - // Value returns the value of the current key/value pair, or nil if done. - Value() []byte - - // Next moves the iterator to the next key/value pair. - Next() bool - - // Close releases associated resources. It should NOT be idempotent. It must - // only be called once and any call after may panic. - Close() -} - -// IteratorCreator defines an interface for creating forward and reverse iterators. -type IteratorCreator interface { - // Iterator creates a new iterator for the given store name and domain, where - // domain is defined by [start, end). Note, both start and end are optional. - Iterator(storeKey string, start, end []byte) (Iterator, error) - // ReverseIterator creates a new reverse iterator for the given store name - // and domain, where domain is defined by [start, end). Note, both start and - // end are optional. - ReverseIterator(storeKey string, start, end []byte) (Iterator, error) -} diff --git a/store/kv/branch/iterator.go b/store/kv/branch/iterator.go index 02f3e3c0f6d0..5fc952f5f5a2 100644 --- a/store/kv/branch/iterator.go +++ b/store/kv/branch/iterator.go @@ -3,10 +3,11 @@ package branch import ( "slices" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) // iterator walks over both the KVStore's changeset, i.e. dirty writes, and the // parent iterator, which can either be another KVStore or the SS backend, at the @@ -16,7 +17,7 @@ var _ store.Iterator = (*iterator)(nil) // iterator. This is because when an iterator is created, it takes a current // snapshot of the changeset. type iterator struct { - parentItr store.Iterator + parentItr corestore.Iterator start []byte end []byte key []byte @@ -41,21 +42,21 @@ func (itr *iterator) Value() []byte { return slices.Clone(itr.value) } -func (itr *iterator) Close() { +func (itr *iterator) Close() error { itr.key = nil itr.value = nil itr.keys = nil itr.values = nil - itr.parentItr.Close() + return itr.parentItr.Close() } -func (itr *iterator) Next() bool { +func (itr *iterator) Next() { for { switch { case itr.exhausted && len(itr.keys) == 0: // exhausted both itr.key = nil itr.value = nil - return false + return case itr.exhausted: // exhausted parent iterator but not store (dirty writes) iterator nextKey := itr.keys[0] @@ -72,15 +73,17 @@ func (itr *iterator) Next() bool { if nextValue.Value != nil { itr.key = []byte(nextKey) itr.value = nextValue.Value - return true + return } case len(itr.keys) == 0: // exhausted store (dirty writes) iterator but not parent iterator itr.key = itr.parentItr.Key() itr.value = itr.parentItr.Value() - itr.exhausted = !itr.parentItr.Next() - return true + itr.parentItr.Next() + itr.exhausted = !itr.parentItr.Valid() + + return default: // parent iterator is not exhausted and we have store (dirty writes) remaining dirtyKey := itr.keys[0] @@ -102,14 +105,17 @@ func (itr *iterator) Next() bool { if dirtyVal.Value != nil { itr.key = []byte(dirtyKey) itr.value = dirtyVal.Value - return true + return } case (!itr.reverse && parentKeyStr < dirtyKey) || (itr.reverse && parentKeyStr > dirtyKey): // parent's key should come before dirty key itr.key = parentKey itr.value = itr.parentItr.Value() - itr.exhausted = !itr.parentItr.Next() - return true + + itr.parentItr.Next() + itr.exhausted = !itr.parentItr.Valid() + + return default: // pop off key @@ -120,12 +126,13 @@ func (itr *iterator) Next() bool { itr.values[0].Value = nil itr.values = itr.values[1:] - itr.exhausted = !itr.parentItr.Next() + itr.parentItr.Next() + itr.exhausted = !itr.parentItr.Valid() if dirtyVal.Value != nil { itr.key = []byte(dirtyKey) itr.value = dirtyVal.Value - return true + return } } } diff --git a/store/kv/branch/store.go b/store/kv/branch/store.go index aaefcf04871e..98416a9655c1 100644 --- a/store/kv/branch/store.go +++ b/store/kv/branch/store.go @@ -8,6 +8,7 @@ import ( "golang.org/x/exp/maps" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" "cosmossdk.io/store/v2/kv/trace" ) @@ -212,11 +213,11 @@ func (s *Store) Write() { // Note, writes that happen on the KVStore over an iterator will not affect the // iterator. This is because when an iterator is created, it takes a current // snapshot of the changeset. -func (s *Store) Iterator(start, end []byte) store.Iterator { +func (s *Store) Iterator(start, end []byte) corestore.Iterator { s.mu.Lock() defer s.mu.Unlock() - var parentItr store.Iterator + var parentItr corestore.Iterator if s.parent != nil { parentItr = s.parent.Iterator(start, end) } else { @@ -238,11 +239,11 @@ func (s *Store) Iterator(start, end []byte) store.Iterator { // Note, writes that happen on the KVStore over an iterator will not affect the // iterator. This is because when an iterator is created, it takes a current // snapshot of the changeset. -func (s *Store) ReverseIterator(start, end []byte) store.Iterator { +func (s *Store) ReverseIterator(start, end []byte) corestore.Iterator { s.mu.Lock() defer s.mu.Unlock() - var parentItr store.Iterator + var parentItr corestore.Iterator if s.parent != nil { parentItr = s.parent.ReverseIterator(start, end) } else { @@ -256,7 +257,7 @@ func (s *Store) ReverseIterator(start, end []byte) store.Iterator { return s.newIterator(parentItr, start, end, true) } -func (s *Store) newIterator(parentItr store.Iterator, start, end []byte, reverse bool) *iterator { +func (s *Store) newIterator(parentItr corestore.Iterator, start, end []byte, reverse bool) *iterator { startStr := string(start) endStr := string(end) @@ -305,7 +306,7 @@ func (s *Store) newIterator(parentItr store.Iterator, start, end []byte, reverse } // call Next() to move the iterator to the first key/value entry - _ = itr.Next() + itr.Next() return itr } diff --git a/store/kv/branch/store_test.go b/store/kv/branch/store_test.go index 424e396e0b2e..0d3ffffd3ecb 100644 --- a/store/kv/branch/store_test.go +++ b/store/kv/branch/store_test.go @@ -157,7 +157,6 @@ func (s *StoreTestSuite) TestIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -178,7 +177,6 @@ func (s *StoreTestSuite) TestIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -199,7 +197,6 @@ func (s *StoreTestSuite) TestIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -220,7 +217,6 @@ func (s *StoreTestSuite) TestIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } @@ -264,7 +260,6 @@ func (s *StoreTestSuite) TestIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -290,7 +285,6 @@ func (s *StoreTestSuite) TestIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -316,7 +310,6 @@ func (s *StoreTestSuite) TestIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -342,7 +335,6 @@ func (s *StoreTestSuite) TestIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } @@ -366,7 +358,6 @@ func (s *StoreTestSuite) TestReverseIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -388,7 +379,6 @@ func (s *StoreTestSuite) TestReverseIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -410,7 +400,6 @@ func (s *StoreTestSuite) TestReverseIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -432,7 +421,6 @@ func (s *StoreTestSuite) TestReverseIterator_NoWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } @@ -477,7 +465,6 @@ func (s *StoreTestSuite) TestReverseIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -504,7 +491,6 @@ func (s *StoreTestSuite) TestReverseIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -531,7 +517,6 @@ func (s *StoreTestSuite) TestReverseIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -558,7 +543,6 @@ func (s *StoreTestSuite) TestReverseIterator_DirtyWrites() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } diff --git a/store/kv/mem/iterator.go b/store/kv/mem/iterator.go index e6d58437ca16..da7cdc61af94 100644 --- a/store/kv/mem/iterator.go +++ b/store/kv/mem/iterator.go @@ -6,10 +6,11 @@ import ( "github.com/tidwall/btree" "golang.org/x/exp/slices" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) type iterator struct { treeItr btree.IterG[store.KVPair] @@ -19,7 +20,7 @@ type iterator struct { valid bool } -func newIterator(tree *btree.BTreeG[store.KVPair], start, end []byte, reverse bool) store.Iterator { +func newIterator(tree *btree.BTreeG[store.KVPair], start, end []byte, reverse bool) corestore.Iterator { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { panic(store.ErrKeyEmpty) } @@ -83,9 +84,9 @@ func (itr *iterator) Value() []byte { return slices.Clone(itr.treeItr.Item().Value) } -func (itr *iterator) Next() bool { +func (itr *iterator) Next() { if !itr.valid { - return false + return } if !itr.reverse { @@ -98,11 +99,12 @@ func (itr *iterator) Next() bool { itr.valid = itr.keyInRange(itr.Key()) } - return itr.valid + return } -func (itr *iterator) Close() { +func (itr *iterator) Close() error { itr.treeItr.Release() + return nil } func (itr *iterator) Error() error { diff --git a/store/kv/mem/store.go b/store/kv/mem/store.go index eca7de48d713..4e3a1dbb8e87 100644 --- a/store/kv/mem/store.go +++ b/store/kv/mem/store.go @@ -5,6 +5,7 @@ import ( "github.com/tidwall/btree" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) @@ -92,10 +93,10 @@ func (s *Store) Reset(_ uint64) error { return nil } -func (s *Store) Iterator(start, end []byte) store.Iterator { +func (s *Store) Iterator(start, end []byte) corestore.Iterator { return newIterator(s.tree, start, end, false) } -func (s *Store) ReverseIterator(start, end []byte) store.Iterator { +func (s *Store) ReverseIterator(start, end []byte) corestore.Iterator { return newIterator(s.tree, start, end, true) } diff --git a/store/kv/mem/store_test.go b/store/kv/mem/store_test.go index 656cf5319428..3eeea2bd8523 100644 --- a/store/kv/mem/store_test.go +++ b/store/kv/mem/store_test.go @@ -92,7 +92,6 @@ func (s *StoreTestSuite) TestIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -113,7 +112,6 @@ func (s *StoreTestSuite) TestIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -134,7 +132,7 @@ func (s *StoreTestSuite) TestIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) + s.Require().False(itr.Valid()) }) @@ -155,7 +153,6 @@ func (s *StoreTestSuite) TestIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } @@ -185,7 +182,6 @@ func (s *StoreTestSuite) TestReverseIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -208,7 +204,6 @@ func (s *StoreTestSuite) TestReverseIterator() { // seek past domain, which should make the iterator invalid and produce an error s.Require().False(itr.Valid()) - s.Require().False(itr.Next()) }) // reverse iterator with with a start and end domain @@ -229,7 +224,6 @@ func (s *StoreTestSuite) TestReverseIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) @@ -251,7 +245,6 @@ func (s *StoreTestSuite) TestReverseIterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) }) } diff --git a/store/kv/trace/iterator.go b/store/kv/trace/iterator.go index 98de8b2d1ce8..a01d8567b0db 100644 --- a/store/kv/trace/iterator.go +++ b/store/kv/trace/iterator.go @@ -3,18 +3,19 @@ package trace import ( "io" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) type iterator struct { - parent store.Iterator + parent corestore.Iterator writer io.Writer context store.TraceContext } -func newIterator(w io.Writer, parent store.Iterator, tc store.TraceContext) store.Iterator { +func newIterator(w io.Writer, parent corestore.Iterator, tc store.TraceContext) corestore.Iterator { return &iterator{ parent: parent, writer: w, @@ -30,16 +31,16 @@ func (itr *iterator) Valid() bool { return itr.parent.Valid() } -func (itr *iterator) Next() bool { - return itr.parent.Next() +func (itr *iterator) Next() { + itr.parent.Next() } func (itr *iterator) Error() error { return itr.parent.Error() } -func (itr *iterator) Close() { - itr.parent.Close() +func (itr *iterator) Close() error { + return itr.parent.Close() } func (itr *iterator) Key() []byte { diff --git a/store/kv/trace/store.go b/store/kv/trace/store.go index 6dcecfa0f615..278f4b8e7d44 100644 --- a/store/kv/trace/store.go +++ b/store/kv/trace/store.go @@ -8,6 +8,7 @@ import ( "github.com/cockroachdb/errors" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) @@ -98,11 +99,11 @@ func (s *Store) BranchWithTrace(_ io.Writer, _ store.TraceContext) store.Branche panic(fmt.Sprintf("cannot call BranchWithTrace() on %T", s)) } -func (s *Store) Iterator(start, end []byte) store.Iterator { +func (s *Store) Iterator(start, end []byte) corestore.Iterator { return newIterator(s.writer, s.parent.Iterator(start, end), s.context) } -func (s *Store) ReverseIterator(start, end []byte) store.Iterator { +func (s *Store) ReverseIterator(start, end []byte) corestore.Iterator { return newIterator(s.writer, s.parent.ReverseIterator(start, end), s.context) } diff --git a/store/kv/trace/store_test.go b/store/kv/trace/store_test.go index f1cf1db494e3..6aab8a90ba11 100644 --- a/store/kv/trace/store_test.go +++ b/store/kv/trace/store_test.go @@ -203,7 +203,6 @@ func TestTestTraceKVStoreIterator(t *testing.T) { } require.False(t, iterator.Valid()) - require.False(t, iterator.Next()) } func TestTestTraceKVStoreReverseIterator(t *testing.T) { @@ -258,7 +257,6 @@ func TestTestTraceKVStoreReverseIterator(t *testing.T) { } require.False(t, iterator.Valid()) - require.False(t, iterator.Next()) } func TestTraceKVStoreGetStoreType(t *testing.T) { diff --git a/store/storage/database.go b/store/storage/database.go index 884981f6138f..05a7fedcf119 100644 --- a/store/storage/database.go +++ b/store/storage/database.go @@ -3,6 +3,7 @@ package storage import ( "io" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" ) @@ -16,8 +17,8 @@ type Database interface { GetLatestVersion() (uint64, error) SetLatestVersion(version uint64) error - Iterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) - ReverseIterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) + Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) + ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) Prune(version uint64) error diff --git a/store/storage/pebbledb/db.go b/store/storage/pebbledb/db.go index 449656bf5305..5a62c6b7122f 100644 --- a/store/storage/pebbledb/db.go +++ b/store/storage/pebbledb/db.go @@ -10,6 +10,7 @@ import ( "github.com/cockroachdb/pebble" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" "cosmossdk.io/store/v2/storage" ) @@ -262,7 +263,7 @@ func (db *Database) Prune(version uint64) error { return db.setPruneHeight(version) } -func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } @@ -283,7 +284,7 @@ func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) return newPebbleDBIterator(itr, storePrefix(storeKey), start, end, version, db.earliestVersion, false), nil } -func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } diff --git a/store/storage/pebbledb/iterator.go b/store/storage/pebbledb/iterator.go index aa9ff04bc063..10b03bbe1143 100644 --- a/store/storage/pebbledb/iterator.go +++ b/store/storage/pebbledb/iterator.go @@ -7,20 +7,17 @@ import ( "github.com/cockroachdb/pebble" - "cosmossdk.io/store/v2" + corestore "cosmossdk.io/core/store" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) // iterator implements the store.Iterator interface. It wraps a PebbleDB iterator // with added MVCC key handling logic. The iterator will iterate over the key space // in the provided domain for a given version. If a key has been written at the // provided version, that key/value pair will be iterated over. Otherwise, the // latest version for that key/value pair will be iterated over s.t. it's less -// than the provided version. Note: -// -// - The start key must not be empty. -// - Currently, reverse iteration is NOT supported. +// than the provided version. type iterator struct { source *pebble.Iterator prefix, start, end []byte @@ -76,7 +73,7 @@ func newPebbleDBIterator(src *pebble.Iterator, prefix, mvccStart, mvccEnd []byte // The cursor might now be pointing at a key/value pair that is tombstoned. // If so, we must move the cursor. if itr.valid && itr.cursorTombstoned() { - itr.valid = itr.Next() + itr.Next() } return itr @@ -115,7 +112,7 @@ func (itr *iterator) Value() []byte { return slices.Clone(val) } -func (itr *iterator) Next() bool { +func (itr *iterator) Next() { var next bool if itr.reverse { currKey, _, ok := SplitMVCCKey(itr.source.Key()) @@ -142,12 +139,12 @@ func (itr *iterator) Next() bool { // XXX: This should not happen as that would indicate we have a malformed // MVCC key. itr.valid = false - return itr.valid + return } if !bytes.HasPrefix(nextKey, itr.prefix) { // the next key must have itr.prefix as the prefix itr.valid = false - return itr.valid + return } // Move the iterator to the closest version to the desired version, so we @@ -157,14 +154,14 @@ func (itr *iterator) Next() bool { // The cursor might now be pointing at a key/value pair that is tombstoned. // If so, we must move the cursor. if itr.valid && itr.cursorTombstoned() { - itr.valid = itr.Next() + itr.Next() } - return itr.valid + return } itr.valid = false - return itr.valid + return } func (itr *iterator) Valid() bool { @@ -195,10 +192,12 @@ func (itr *iterator) Error() error { return itr.source.Error() } -func (itr *iterator) Close() { - _ = itr.source.Close() +func (itr *iterator) Close() error { + err := itr.source.Close() itr.source = nil itr.valid = false + + return err } func (itr *iterator) assertIsValid() { diff --git a/store/storage/rocksdb/db.go b/store/storage/rocksdb/db.go index 6ebe3c89dd7d..b2525e3d8e81 100644 --- a/store/storage/rocksdb/db.go +++ b/store/storage/rocksdb/db.go @@ -11,6 +11,7 @@ import ( "github.com/linxGnu/grocksdb" "golang.org/x/exp/slices" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" "cosmossdk.io/store/v2/storage" "cosmossdk.io/store/v2/storage/util" @@ -162,7 +163,7 @@ func (db *Database) Prune(version uint64) error { return nil } -func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } @@ -178,7 +179,7 @@ func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) return newRocksDBIterator(itr, prefix, start, end, false), nil } -func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } diff --git a/store/storage/rocksdb/db_test.go b/store/storage/rocksdb/db_test.go index 8788bfe632e2..e3542fe91ba0 100644 --- a/store/storage/rocksdb/db_test.go +++ b/store/storage/rocksdb/db_test.go @@ -62,7 +62,6 @@ func TestDatabase_ReverseIterator(t *testing.T) { require.NoError(t, iter.Error()) // seek past domain, which should make the iterator invalid and produce an error - require.False(t, iter.Next()) require.False(t, iter.Valid()) // reverse iterator with with a start and end domain @@ -83,7 +82,6 @@ func TestDatabase_ReverseIterator(t *testing.T) { require.NoError(t, iter2.Error()) // seek past domain, which should make the iterator invalid and produce an error - require.False(t, iter2.Next()) require.False(t, iter2.Valid()) // start must be <= end diff --git a/store/storage/rocksdb/iterator.go b/store/storage/rocksdb/iterator.go index 80d255dce720..e960b0277a4e 100644 --- a/store/storage/rocksdb/iterator.go +++ b/store/storage/rocksdb/iterator.go @@ -8,10 +8,10 @@ import ( "github.com/linxGnu/grocksdb" - "cosmossdk.io/store/v2" + corestore "cosmossdk.io/core/store" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) type iterator struct { source *grocksdb.Iterator @@ -124,9 +124,9 @@ func (itr *iterator) Value() []byte { return copyAndFreeSlice(itr.source.Value()) } -func (itr iterator) Next() bool { +func (itr iterator) Next() { if itr.invalid { - return false + return } if itr.reverse { @@ -135,17 +135,19 @@ func (itr iterator) Next() bool { itr.source.Next() } - return itr.Valid() + return } func (itr *iterator) Error() error { return itr.source.Err() } -func (itr *iterator) Close() { +func (itr *iterator) Close() error { itr.source.Close() itr.source = nil itr.invalid = true + + return nil } func (itr *iterator) assertIsValid() { diff --git a/store/storage/sqlite/db.go b/store/storage/sqlite/db.go index 05fde45b03fd..5d6b6138f249 100644 --- a/store/storage/sqlite/db.go +++ b/store/storage/sqlite/db.go @@ -10,6 +10,7 @@ import ( _ "github.com/mattn/go-sqlite3" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" "cosmossdk.io/store/v2/storage" ) @@ -59,7 +60,7 @@ func New(dataDir string) (*Database, error) { stmt := ` CREATE TABLE IF NOT EXISTS state_storage ( - id integer not null primary key, + id integer not null primary key, store_key varchar not null, key varchar not null, value varchar not null, @@ -214,7 +215,7 @@ func (db *Database) Prune(version uint64) error { return nil } -func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } @@ -226,7 +227,7 @@ func (db *Database) Iterator(storeKey string, version uint64, start, end []byte) return newIterator(db, storeKey, version, start, end, false) } -func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (db *Database) ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { if (start != nil && len(start) == 0) || (end != nil && len(end) == 0) { return nil, store.ErrKeyEmpty } diff --git a/store/storage/sqlite/db_test.go b/store/storage/sqlite/db_test.go index deff98ec4348..890a55a0d1c1 100644 --- a/store/storage/sqlite/db_test.go +++ b/store/storage/sqlite/db_test.go @@ -61,7 +61,6 @@ func TestDatabase_ReverseIterator(t *testing.T) { require.NoError(t, iter.Error()) // seek past domain, which should make the iterator invalid and produce an error - require.False(t, iter.Next()) require.False(t, iter.Valid()) // reverse iterator with with a start and end domain @@ -82,7 +81,6 @@ func TestDatabase_ReverseIterator(t *testing.T) { require.NoError(t, iter2.Error()) // seek past domain, which should make the iterator invalid and produce an error - require.False(t, iter2.Next()) require.False(t, iter2.Valid()) // start must be <= end diff --git a/store/storage/sqlite/iterator.go b/store/storage/sqlite/iterator.go index 01ef6f85d6d8..4549c478fad1 100644 --- a/store/storage/sqlite/iterator.go +++ b/store/storage/sqlite/iterator.go @@ -8,10 +8,10 @@ import ( "golang.org/x/exp/slices" - "cosmossdk.io/store/v2" + corestore "cosmossdk.io/core/store" ) -var _ store.Iterator = (*iterator)(nil) +var _ corestore.Iterator = (*iterator)(nil) type iterator struct { statement *sql.Stmt @@ -100,14 +100,16 @@ func newIterator(db *Database, storeKey string, targetVersion uint64, start, end return itr, nil } -func (itr *iterator) Close() { +func (itr *iterator) Close() (err error) { if itr.statement != nil { - _ = itr.statement.Close() + err = itr.statement.Close() } itr.valid = false itr.statement = nil itr.rows = nil + + return err } // Domain returns the domain of the iterator. The caller must not modify the @@ -143,14 +145,14 @@ func (itr *iterator) Valid() bool { return true } -func (itr *iterator) Next() bool { +func (itr *iterator) Next() { if itr.rows.Next() { itr.parseRow() - return itr.Valid() + return } itr.valid = false - return itr.valid + return } func (itr *iterator) Error() error { diff --git a/store/storage/storage_test_suite.go b/store/storage/storage_test_suite.go index 46551b2c3eba..7c7ea03e0c82 100644 --- a/store/storage/storage_test_suite.go +++ b/store/storage/storage_test_suite.go @@ -265,7 +265,6 @@ func (s *StorageTestSuite) TestDatabase_Iterator() { s.Require().NoError(itr.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr.Next()) s.Require().False(itr.Valid()) } @@ -288,7 +287,6 @@ func (s *StorageTestSuite) TestDatabase_Iterator() { s.Require().NoError(itr2.Error()) // seek past domain, which should make the iterator invalid and produce an error - s.Require().False(itr2.Next()) s.Require().False(itr2.Valid()) } diff --git a/store/storage/store.go b/store/storage/store.go index 3a6fed65db2d..a386bfe67752 100644 --- a/store/storage/store.go +++ b/store/storage/store.go @@ -3,6 +3,7 @@ package storage import ( "fmt" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2" "cosmossdk.io/store/v2/snapshots" ) @@ -74,12 +75,12 @@ func (ss *StorageStore) SetLatestVersion(version uint64) error { } // Iterator returns an iterator over the specified domain and prefix. -func (ss *StorageStore) Iterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (ss *StorageStore) Iterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { return ss.db.Iterator(storeKey, version, start, end) } // ReverseIterator returns an iterator over the specified domain and prefix in reverse. -func (ss *StorageStore) ReverseIterator(storeKey string, version uint64, start, end []byte) (store.Iterator, error) { +func (ss *StorageStore) ReverseIterator(storeKey string, version uint64, start, end []byte) (corestore.Iterator, error) { return ss.db.ReverseIterator(storeKey, version, start, end) } diff --git a/store/store.go b/store/store.go index 8bbeda7985ea..a682da8429b7 100644 --- a/store/store.go +++ b/store/store.go @@ -4,6 +4,7 @@ import ( "io" coreheader "cosmossdk.io/core/header" + corestore "cosmossdk.io/core/store" "cosmossdk.io/store/v2/metrics" ) @@ -148,11 +149,11 @@ type KVStore interface { // // CONTRACT: No writes may happen within a domain while an iterator exists over // it, with the exception of a branched/cached KVStore. - Iterator(start, end []byte) Iterator + Iterator(start, end []byte) corestore.Iterator // ReverseIterator creates a new reverse Iterator over the domain [start, end). // It has the some properties and contracts as Iterator. - ReverseIterator(start, end []byte) Iterator + ReverseIterator(start, end []byte) corestore.Iterator } // BranchedKVStore defines an interface for a branched a KVStore. It extends KVStore From 6a2329fc933847c5829ef698e4d709a10917b16f Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Mon, 8 Jan 2024 22:13:46 +0100 Subject: [PATCH 03/28] refactor(x/gov): log error when deposit refund error (#18976) --- x/gov/CHANGELOG.md | 1 + x/gov/abci.go | 14 ++++- x/gov/abci_test.go | 122 +++++++++++++++++----------------------- x/gov/keeper/deposit.go | 26 ++++----- x/gov/types/events.go | 16 +++--- 5 files changed, 88 insertions(+), 91 deletions(-) diff --git a/x/gov/CHANGELOG.md b/x/gov/CHANGELOG.md index a22fc538d9d4..c7f80a822a55 100644 --- a/x/gov/CHANGELOG.md +++ b/x/gov/CHANGELOG.md @@ -34,6 +34,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* [#18976](https://github.com/cosmos/cosmos-sdk/pull/18976) Log and send an event when a proposal deposit refund or burn has failed. * [#18856](https://github.com/cosmos/cosmos-sdk/pull/18856) Add `ProposalCancelMaxPeriod` for modifying how long a proposal can be cancelled after it has been submitted. * [#18445](https://github.com/cosmos/cosmos-sdk/pull/18445) Extend gov config. * [#18532](https://github.com/cosmos/cosmos-sdk/pull/18532) Repurpose `govcliutils.NormalizeProposalType` to work for gov v1 proposal types. diff --git a/x/gov/abci.go b/x/gov/abci.go index cc1fa9724774..70074849a4d5 100644 --- a/x/gov/abci.go +++ b/x/gov/abci.go @@ -137,7 +137,19 @@ func EndBlocker(ctx sdk.Context, keeper *keeper.Keeper) error { err = keeper.RefundAndDeleteDeposits(ctx, proposal.Id) } if err != nil { - return false, err + // in case of an error, log it and emit an event + // we do not want to halt the chain if the refund/burn fails + // as it could happen due to a governance mistake (governance has let a proposal pass that sends gov funds that were from proposal deposits) + + keeper.Logger(ctx).Error("failed to refund or burn deposits", "error", err) + ctx.EventManager().EmitEvent( + sdk.NewEvent( + types.EventTypeProposalDeposit, + sdk.NewAttribute(types.AttributeKeyProposalID, fmt.Sprintf("%d", proposal.Id)), + sdk.NewAttribute(types.AttributeKeyProposalDepositError, "failed to refund or burn deposits"), + sdk.NewAttribute("error", err.Error()), + ), + ) } if err = keeper.ActiveProposalsQueue.Remove(ctx, collections.Join(*proposal.VotingEndTime, proposal.Id)); err != nil { diff --git a/x/gov/abci_test.go b/x/gov/abci_test.go index e6106fc1ccfa..ac62edbc6413 100644 --- a/x/gov/abci_test.go +++ b/x/gov/abci_test.go @@ -41,8 +41,6 @@ func TestUnregisteredProposal_InactiveProposalFails(t *testing.T) { err = suite.GovKeeper.InactiveProposalsQueue.Set(ctx, collections.Join(endTime, proposal.Id), proposal.Id) require.NoError(t, err) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - err = gov.EndBlocker(ctx, suite.GovKeeper) require.NoError(t, err) @@ -71,8 +69,6 @@ func TestUnregisteredProposal_ActiveProposalFails(t *testing.T) { err = suite.GovKeeper.ActiveProposalsQueue.Set(ctx, collections.Join(endTime, proposal.Id), proposal.Id) require.NoError(t, err) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - err = gov.EndBlocker(ctx, suite.GovKeeper) require.NoError(t, err) @@ -89,8 +85,6 @@ func TestTickExpiredDepositPeriod(t *testing.T) { govMsgSvr := keeper.NewMsgServerImpl(suite.GovKeeper) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newProposalMsg, err := v1.NewMsgSubmitProposal( []sdk.Msg{mkTestLegacyContent(t)}, sdk.Coins{sdk.NewInt64Coin(sdk.DefaultBondDenom, 100000)}, @@ -106,25 +100,17 @@ func TestTickExpiredDepositPeriod(t *testing.T) { require.NoError(t, err) require.NotNil(t, res) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newHeader := ctx.HeaderInfo() newHeader.Time = ctx.HeaderInfo().Time.Add(time.Duration(1) * time.Second) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - params, _ := suite.GovKeeper.Params.Get(ctx) newHeader = ctx.HeaderInfo() newHeader.Time = ctx.HeaderInfo().Time.Add(*params.MaxDepositPeriod) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - err = gov.EndBlocker(ctx, suite.GovKeeper) require.NoError(t, err) - - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) } func TestTickMultipleExpiredDepositPeriod(t *testing.T) { @@ -134,8 +120,6 @@ func TestTickMultipleExpiredDepositPeriod(t *testing.T) { addrs := simtestutil.AddTestAddrs(suite.BankKeeper, suite.StakingKeeper, ctx, 10, valTokens) govMsgSvr := keeper.NewMsgServerImpl(suite.GovKeeper) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newProposalMsg, err := v1.NewMsgSubmitProposal( []sdk.Msg{mkTestLegacyContent(t)}, sdk.Coins{sdk.NewInt64Coin(sdk.DefaultBondDenom, 100000)}, @@ -151,14 +135,10 @@ func TestTickMultipleExpiredDepositPeriod(t *testing.T) { require.NoError(t, err) require.NotNil(t, res) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newHeader := ctx.HeaderInfo() newHeader.Time = ctx.HeaderInfo().Time.Add(time.Duration(2) * time.Second) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newProposalMsg2, err := v1.NewMsgSubmitProposal( []sdk.Msg{mkTestLegacyContent(t)}, sdk.Coins{sdk.NewInt64Coin(sdk.DefaultBondDenom, 100000)}, @@ -179,17 +159,12 @@ func TestTickMultipleExpiredDepositPeriod(t *testing.T) { newHeader.Time = ctx.HeaderInfo().Time.Add(*params.MaxDepositPeriod).Add(time.Duration(-1) * time.Second) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) require.NoError(t, gov.EndBlocker(ctx, suite.GovKeeper)) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) newHeader = ctx.HeaderInfo() newHeader.Time = ctx.HeaderInfo().Time.Add(time.Duration(5) * time.Second) ctx = ctx.WithHeaderInfo(newHeader) - - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) require.NoError(t, gov.EndBlocker(ctx, suite.GovKeeper)) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) } func TestTickPassedDepositPeriod(t *testing.T) { @@ -216,21 +191,68 @@ func TestTickPassedDepositPeriod(t *testing.T) { proposalID := res.ProposalId - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newHeader := ctx.HeaderInfo() newHeader.Time = ctx.HeaderInfo().Time.Add(time.Duration(1) * time.Second) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - newDepositMsg := v1.NewMsgDeposit(addrs[1], proposalID, sdk.Coins{sdk.NewInt64Coin(sdk.DefaultBondDenom, 100000)}) res1, err := govMsgSvr.Deposit(ctx, newDepositMsg) require.NoError(t, err) require.NotNil(t, res1) +} + +func TestProposalDepositRefundFailEndBlocker(t *testing.T) { + suite := createTestSuite(t) + app := suite.App + ctx := app.BaseApp.NewContext(false) + addrs := simtestutil.AddTestAddrs(suite.BankKeeper, suite.StakingKeeper, ctx, 10, valTokens) + govMsgSvr := keeper.NewMsgServerImpl(suite.GovKeeper) + + depositMultiplier := getDepositMultiplier(v1.ProposalType_PROPOSAL_TYPE_STANDARD) + proposalCoins := sdk.Coins{sdk.NewCoin(sdk.DefaultBondDenom, suite.StakingKeeper.TokensFromConsensusPower(ctx, 15*depositMultiplier))} + + // create a proposal that empties the gov module account + // which will cause the proposal deposit refund to fail + newProposalMsg, err := v1.NewMsgSubmitProposal( + []sdk.Msg{}, + proposalCoins, + addrs[0].String(), + "metadata", + "proposal", + "description of proposal", + v1.ProposalType_PROPOSAL_TYPE_STANDARD, + ) + require.NoError(t, err) + + res, err := govMsgSvr.SubmitProposal(ctx, newProposalMsg) + require.NoError(t, err) + require.NotNil(t, res) + + proposal, err := suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) + require.NoError(t, err) + require.Equal(t, v1.StatusVotingPeriod, proposal.Status) + + proposalID := res.ProposalId + err = suite.GovKeeper.AddVote(ctx, proposalID, addrs[0], v1.NewNonSplitVoteOption(v1.OptionYes), "metadata") + require.NoError(t, err) + + // empty the gov module account before the proposal ends + err = suite.BankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, addrs[1], proposalCoins) + require.NoError(t, err) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) + // fast forward to the end of the voting period + newHeader := ctx.HeaderInfo() + newHeader.Time = proposal.VotingEndTime.Add(time.Duration(100) * time.Second) + ctx = ctx.WithHeaderInfo(newHeader) + + err = gov.EndBlocker(ctx, suite.GovKeeper) + require.NoError(t, err) // no error, means does not halt the chain + + events := ctx.EventManager().Events() + attr, ok := events.GetAttributes(types.AttributeKeyProposalDepositError) + require.True(t, ok) + require.Contains(t, attr[0].Value, "failed to refund or burn deposits") } func TestTickPassedVotingPeriod(t *testing.T) { @@ -258,9 +280,6 @@ func TestTickPassedVotingPeriod(t *testing.T) { SortAddresses(addrs) govMsgSvr := keeper.NewMsgServerImpl(suite.GovKeeper) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposalCoins := sdk.Coins{sdk.NewCoin(sdk.DefaultBondDenom, suite.StakingKeeper.TokensFromConsensusPower(ctx, 5*depositMultiplier))} newProposalMsg, err := v1.NewMsgSubmitProposal([]sdk.Msg{mkTestLegacyContent(t)}, proposalCoins, addrs[0].String(), "", "Proposal", "description of proposal", tc.proposalType) require.NoError(t, err) @@ -291,9 +310,6 @@ func TestTickPassedVotingPeriod(t *testing.T) { newHeader.Time = ctx.HeaderInfo().Time.Add(*params.MaxDepositPeriod).Add(*votingPeriod) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposal, err := suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.NoError(t, err) require.Equal(t, v1.StatusVotingPeriod, proposal.Status) @@ -302,13 +318,10 @@ func TestTickPassedVotingPeriod(t *testing.T) { require.NoError(t, err) if tc.proposalType != v1.ProposalType_PROPOSAL_TYPE_EXPEDITED { - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) return } // If expedited, it should be converted to a regular proposal instead. - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposal, err = suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.Nil(t, err) require.Equal(t, v1.StatusVotingPeriod, proposal.Status) @@ -490,8 +503,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { createValidators(t, stakingMsgSvr, ctx, []sdk.ValAddress{valAddr}, []int64{10}) _, err = suite.StakingKeeper.EndBlocker(ctx) require.NoError(t, err) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) macc := suite.GovKeeper.GetGovernanceAccount(ctx) require.NotNil(t, macc) @@ -524,9 +535,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { newHeader.Time = ctx.HeaderInfo().Time.Add(*params.MaxDepositPeriod).Add(*params.ExpeditedVotingPeriod) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposal, err := suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.Nil(t, err) require.Equal(t, v1.StatusVotingPeriod, proposal.Status) @@ -541,8 +549,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { err = gov.EndBlocker(ctx, suite.GovKeeper) require.NoError(t, err) if tc.expeditedPasses { - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposal, err = suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.Nil(t, err) @@ -562,7 +568,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { } // Expedited proposal should be converted to a regular proposal instead. - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) proposal, err = suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.Nil(t, err) require.Equal(t, v1.StatusVotingPeriod, proposal.Status) @@ -583,9 +588,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { newHeader.Time = ctx.HeaderInfo().Time.Add(*params.MaxDepositPeriod).Add(*params.VotingPeriod) ctx = ctx.WithHeaderInfo(newHeader) - checkInactiveProposalsQueue(t, ctx, suite.GovKeeper) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - if tc.regularEventuallyPassing { // Validator votes YES, letting the converted regular proposal pass. err = suite.GovKeeper.AddVote(ctx, proposal.Id, addrs[0], v1.NewNonSplitVoteOption(v1.OptionYes), "metadata") @@ -602,8 +604,6 @@ func TestExpeditedProposal_PassAndConversionToRegular(t *testing.T) { submitterEventualBalance := suite.BankKeeper.GetAllBalances(ctx, addrs[0]) depositorEventualBalance := suite.BankKeeper.GetAllBalances(ctx, addrs[1]) - checkActiveProposalsQueue(t, ctx, suite.GovKeeper) - proposal, err = suite.GovKeeper.Proposals.Get(ctx, res.ProposalId) require.Nil(t, err) @@ -655,21 +655,3 @@ func getDepositMultiplier(proposalType v1.ProposalType) int64 { return 1 } } - -func checkActiveProposalsQueue(t *testing.T, ctx sdk.Context, k *keeper.Keeper) { - t.Helper() - err := k.ActiveProposalsQueue.Walk(ctx, collections.NewPrefixUntilPairRange[time.Time, uint64](ctx.HeaderInfo().Time), func(key collections.Pair[time.Time, uint64], value uint64) (stop bool, err error) { - return false, err - }) - - require.NoError(t, err) -} - -func checkInactiveProposalsQueue(t *testing.T, ctx sdk.Context, k *keeper.Keeper) { - t.Helper() - err := k.InactiveProposalsQueue.Walk(ctx, collections.NewPrefixUntilPairRange[time.Time, uint64](ctx.HeaderInfo().Time), func(key collections.Pair[time.Time, uint64], value uint64) (stop bool, err error) { - return false, err - }) - - require.NoError(t, err) -} diff --git a/x/gov/keeper/deposit.go b/x/gov/keeper/deposit.go index b0c6ed7926bf..be79f0826373 100644 --- a/x/gov/keeper/deposit.go +++ b/x/gov/keeper/deposit.go @@ -48,6 +48,19 @@ func (k Keeper) DeleteAndBurnDeposits(ctx context.Context, proposalID uint64) er return k.bankKeeper.BurnCoins(ctx, k.authKeeper.GetModuleAddress(types.ModuleName), coinsToBurn) } +// RefundAndDeleteDeposits refunds and deletes all the deposits on a specific proposal. +func (k Keeper) RefundAndDeleteDeposits(ctx context.Context, proposalID uint64) error { + return k.IterateDeposits(ctx, proposalID, func(key collections.Pair[uint64, sdk.AccAddress], deposit v1.Deposit) (bool, error) { + depositor := key.K2() + err := k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, depositor, deposit.Amount) + if err != nil { + return false, err + } + err = k.Deposits.Remove(ctx, key) + return false, err + }) +} + // IterateDeposits iterates over all the proposals deposits and performs a callback function func (k Keeper) IterateDeposits(ctx context.Context, proposalID uint64, cb func(key collections.Pair[uint64, sdk.AccAddress], value v1.Deposit) (bool, error)) error { rng := collections.NewPrefixedPairRange[uint64, sdk.AccAddress](proposalID) @@ -265,19 +278,6 @@ func (k Keeper) ChargeDeposit(ctx context.Context, proposalID uint64, destAddres return nil } -// RefundAndDeleteDeposits refunds and deletes all the deposits on a specific proposal. -func (k Keeper) RefundAndDeleteDeposits(ctx context.Context, proposalID uint64) error { - return k.IterateDeposits(ctx, proposalID, func(key collections.Pair[uint64, sdk.AccAddress], deposit v1.Deposit) (bool, error) { - depositor := key.K2() - err := k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, depositor, deposit.Amount) - if err != nil { - return false, err - } - err = k.Deposits.Remove(ctx, key) - return false, err - }) -} - // validateInitialDeposit validates if initial deposit is greater than or equal to the minimum // required at the time of proposal submission. This threshold amount is determined by // the deposit parameters. Returns nil on success, error otherwise. diff --git a/x/gov/types/events.go b/x/gov/types/events.go index 7b8261bb8ad8..2ca0fa8dbf9d 100644 --- a/x/gov/types/events.go +++ b/x/gov/types/events.go @@ -9,13 +9,15 @@ const ( EventTypeActiveProposal = "active_proposal" EventTypeCancelProposal = "cancel_proposal" - AttributeKeyProposalResult = "proposal_result" - AttributeKeyVoter = "voter" - AttributeKeyOption = "option" - AttributeKeyProposalID = "proposal_id" - AttributeKeyProposalMessages = "proposal_messages" // Msg type_urls in the proposal - AttributeKeyVotingPeriodStart = "voting_period_start" - AttributeKeyProposalLog = "proposal_log" // log of proposal execution + AttributeKeyProposalResult = "proposal_result" + AttributeKeyVoter = "voter" + AttributeKeyOption = "option" + AttributeKeyProposalID = "proposal_id" + AttributeKeyProposalMessages = "proposal_messages" // Msg type_urls in the proposal + AttributeKeyVotingPeriodStart = "voting_period_start" + AttributeKeyProposalLog = "proposal_log" // log of proposal execution + AttributeKeyProposalDepositError = "proposal_deposit_error" // error on proposal deposit refund/burn + AttributeValueProposalDropped = "proposal_dropped" // didn't meet min deposit AttributeValueProposalPassed = "proposal_passed" // met vote quorum AttributeValueProposalRejected = "proposal_rejected" // didn't meet vote quorum From b16aa35d146b9556c1f5220f043726ed3083fb6b Mon Sep 17 00:00:00 2001 From: atheeshp <59333759+atheeshp@users.noreply.github.com> Date: Tue, 9 Jan 2024 10:26:14 +0530 Subject: [PATCH 04/28] test: add tests for cons pubkey rotation (#18965) Co-authored-by: Aleksandr Bezobchuk --- log/logger_test.go | 3 +- .../evidence/keeper/infraction_test.go | 124 +++++++++- .../integration/staking/keeper/common_test.go | 2 + .../staking/keeper/msg_server_test.go | 217 ++++++++++++++++++ .../staking/simulation/operations_test.go | 35 +++ x/slashing/keeper/signing_info_test.go | 47 ++++ x/staking/keeper/cons_pubkey.go | 4 +- x/staking/keeper/msg_server.go | 2 +- x/staking/keeper/validator.go | 19 +- x/staking/keeper/validator_test.go | 69 ++++++ x/staking/simulation/operations.go | 116 ++++++++++ 11 files changed, 629 insertions(+), 9 deletions(-) diff --git a/log/logger_test.go b/log/logger_test.go index 9c877a0ca4ef..36c7bee3857b 100644 --- a/log/logger_test.go +++ b/log/logger_test.go @@ -6,9 +6,10 @@ import ( "strings" "testing" - "cosmossdk.io/log" "github.com/rs/zerolog" "gotest.tools/v3/assert" + + "cosmossdk.io/log" ) func TestLoggerOptionStackTrace(t *testing.T) { diff --git a/tests/integration/evidence/keeper/infraction_test.go b/tests/integration/evidence/keeper/infraction_test.go index 875e4b8b8704..176ae20b381f 100644 --- a/tests/integration/evidence/keeper/infraction_test.go +++ b/tests/integration/evidence/keeper/infraction_test.go @@ -1,6 +1,7 @@ package keeper_test import ( + "bytes" "context" "encoding/hex" "fmt" @@ -28,6 +29,7 @@ import ( "cosmossdk.io/x/evidence/keeper" evidencetypes "cosmossdk.io/x/evidence/types" minttypes "cosmossdk.io/x/mint/types" + pooltypes "cosmossdk.io/x/protocolpool/types" "cosmossdk.io/x/slashing" slashingkeeper "cosmossdk.io/x/slashing/keeper" "cosmossdk.io/x/slashing/testutil" @@ -94,6 +96,7 @@ func initFixture(tb testing.TB) *fixture { authority := authtypes.NewModuleAddress("gov") maccPerms := map[string][]string{ + pooltypes.ModuleName: {}, minttypes.ModuleName: {authtypes.Minter}, stakingtypes.BondedPoolName: {authtypes.Burner, authtypes.Staking}, stakingtypes.NotBondedPoolName: {authtypes.Burner, authtypes.Staking}, @@ -125,7 +128,9 @@ func initFixture(tb testing.TB) *fixture { slashingKeeper := slashingkeeper.NewKeeper(cdc, codec.NewLegacyAmino(), runtime.NewKVStoreService(keys[slashingtypes.StoreKey]), stakingKeeper, authority.String()) - evidenceKeeper := keeper.NewKeeper(cdc, runtime.NewKVStoreService(keys[evidencetypes.StoreKey]), stakingKeeper, slashingKeeper, addresscodec.NewBech32Codec("cosmos")) + stakingKeeper.SetHooks(stakingtypes.NewMultiStakingHooks(slashingKeeper.Hooks())) + + evidenceKeeper := keeper.NewKeeper(cdc, runtime.NewKVStoreService(keys[evidencetypes.StoreKey]), stakingKeeper, slashingKeeper, addresscodec.NewBech32Codec(sdk.Bech32PrefixAccAddr)) router := evidencetypes.NewRouter() router = router.AddRoute(evidencetypes.RouteEquivocation, testEquivocationHandler(evidenceKeeper)) evidenceKeeper.SetRouter(router) @@ -310,6 +315,123 @@ func TestHandleDoubleSign_TooOld(t *testing.T) { assert.Assert(t, f.slashingKeeper.IsTombstoned(ctx, sdk.ConsAddress(valpubkey.Address())) == false) } +func TestHandleDoubleSignAfterRotation(t *testing.T) { + t.Parallel() + f := initFixture(t) + + ctx := f.sdkCtx.WithIsCheckTx(false).WithBlockHeight(1).WithHeaderInfo(header.Info{Time: time.Now()}) + populateValidators(t, f) + + power := int64(100) + stakingParams, err := f.stakingKeeper.Params.Get(ctx) + assert.NilError(t, err) + + operatorAddr, valpubkey := valAddresses[0], pubkeys[0] + tstaking := stakingtestutil.NewHelper(t, ctx, f.stakingKeeper) + + selfDelegation := tstaking.CreateValidatorWithValPower(operatorAddr, valpubkey, power, true) + + // execute end-blocker and verify validator attributes + _, err = f.stakingKeeper.EndBlocker(ctx) + assert.NilError(t, err) + + assert.DeepEqual(t, + f.bankKeeper.GetAllBalances(ctx, sdk.AccAddress(operatorAddr)).String(), + sdk.NewCoins(sdk.NewCoin(stakingParams.BondDenom, initAmt.Sub(selfDelegation))).String(), + ) + + valInfo, err := f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + consAddrBeforeRotn, err := valInfo.GetConsAddr() + + assert.NilError(t, err) + assert.DeepEqual(t, selfDelegation, valInfo.GetBondedTokens()) + + NewConsPubkey := newPubKey("0B485CFC0EECC619440448436F8FC9DF40566F2369E72400281454CB552AFB53") + + msgServer := stakingkeeper.NewMsgServerImpl(f.stakingKeeper) + msg, err := stakingtypes.NewMsgRotateConsPubKey(operatorAddr.String(), NewConsPubkey) + assert.NilError(t, err) + _, err = msgServer.RotateConsPubKey(ctx, msg) + assert.NilError(t, err) + + // execute end-blocker and verify validator attributes + _, err = f.stakingKeeper.EndBlocker(ctx) + assert.NilError(t, err) + + valInfo, err = f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + consAddrAfterRotn, err := valInfo.GetConsAddr() + assert.NilError(t, err) + assert.Equal(t, bytes.Equal(consAddrBeforeRotn, consAddrAfterRotn), false) + + // handle a signature to set signing info + err = f.slashingKeeper.HandleValidatorSignature(ctx, NewConsPubkey.Address().Bytes(), selfDelegation.Int64(), comet.BlockIDFlagCommit) + assert.NilError(t, err) + + // double sign less than max age + valInfo, err = f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + oldTokens := valInfo.GetTokens() + nci := comet.Info{ + Evidence: []comet.Evidence{{ + Validator: comet.Validator{Address: valpubkey.Address(), Power: power}, + Type: comet.MisbehaviorType(abci.MisbehaviorType_DUPLICATE_VOTE), + Time: time.Unix(0, 0), + Height: 0, + }}, + } + + err = f.evidenceKeeper.BeginBlocker(ctx.WithCometInfo(nci)) + assert.NilError(t, err) + + // should be jailed and tombstoned + valInfo, err = f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + assert.Assert(t, valInfo.IsJailed()) + assert.Assert(t, f.slashingKeeper.IsTombstoned(ctx, sdk.ConsAddress(NewConsPubkey.Address()))) + + // tokens should be decreased + valInfo, err = f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + newTokens := valInfo.GetTokens() + assert.Assert(t, newTokens.LT(oldTokens)) + + // submit duplicate evidence + err = f.evidenceKeeper.BeginBlocker(ctx.WithCometInfo(nci)) + assert.NilError(t, err) + + // tokens should be the same (capped slash) + valInfo, err = f.stakingKeeper.Validator(ctx, operatorAddr) + assert.NilError(t, err) + assert.Assert(t, valInfo.GetTokens().Equal(newTokens)) + + // jump to past the unbonding period + ctx = ctx.WithHeaderInfo(header.Info{Time: time.Unix(1, 0).Add(stakingParams.UnbondingTime)}) + + // require we cannot unjail + assert.Error(t, f.slashingKeeper.Unjail(ctx, operatorAddr), slashingtypes.ErrValidatorJailed.Error()) + + // require we be able to unbond now + ctx = ctx.WithBlockHeight(ctx.BlockHeight() + 1) + del, _ := f.stakingKeeper.Delegations.Get(ctx, collections.Join(sdk.AccAddress(operatorAddr), operatorAddr)) + validator, _ := f.stakingKeeper.GetValidator(ctx, operatorAddr) + totalBond := validator.TokensFromShares(del.GetShares()).TruncateInt() + tstaking.Ctx = ctx + tstaking.Denom = stakingParams.BondDenom + tstaking.Undelegate(sdk.AccAddress(operatorAddr), operatorAddr, totalBond, true) + + // query evidence from store + var evidences []exported.Evidence + assert.NilError(t, f.evidenceKeeper.Evidences.Walk(ctx, nil, func(key []byte, value exported.Evidence) (stop bool, err error) { + evidences = append(evidences, value) + return false, nil + })) + // evidences, err := f.evidenceKeeper.GetAllEvidence(ctx) + assert.NilError(t, err) + assert.Assert(t, len(evidences) == 1) +} + func populateValidators(t assert.TestingT, f *fixture) { // add accounts and set total supply totalSupplyAmt := initAmt.MulRaw(int64(len(valAddresses))) diff --git a/tests/integration/staking/keeper/common_test.go b/tests/integration/staking/keeper/common_test.go index f26884a5a50e..da294ed4e6e5 100644 --- a/tests/integration/staking/keeper/common_test.go +++ b/tests/integration/staking/keeper/common_test.go @@ -18,6 +18,7 @@ import ( bankkeeper "cosmossdk.io/x/bank/keeper" banktypes "cosmossdk.io/x/bank/types" minttypes "cosmossdk.io/x/mint/types" + pooltypes "cosmossdk.io/x/protocolpool/types" "cosmossdk.io/x/staking" stakingkeeper "cosmossdk.io/x/staking/keeper" "cosmossdk.io/x/staking/testutil" @@ -107,6 +108,7 @@ func initFixture(tb testing.TB) *fixture { authority := authtypes.NewModuleAddress("gov") maccPerms := map[string][]string{ + pooltypes.ModuleName: {}, minttypes.ModuleName: {authtypes.Minter}, types.ModuleName: {authtypes.Minter}, types.BondedPoolName: {authtypes.Burner, authtypes.Staking}, diff --git a/tests/integration/staking/keeper/msg_server_test.go b/tests/integration/staking/keeper/msg_server_test.go index 5f6c3760397e..eadd352b8a7b 100644 --- a/tests/integration/staking/keeper/msg_server_test.go +++ b/tests/integration/staking/keeper/msg_server_test.go @@ -6,12 +6,15 @@ import ( "gotest.tools/v3/assert" + "cosmossdk.io/core/header" "cosmossdk.io/math" "cosmossdk.io/x/bank/testutil" + pooltypes "cosmossdk.io/x/protocolpool/types" "cosmossdk.io/x/staking/keeper" "cosmossdk.io/x/staking/types" "github.com/cosmos/cosmos-sdk/codec/address" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -175,3 +178,217 @@ func TestCancelUnbondingDelegation(t *testing.T) { }) } } + +func TestRotateConsPubKey(t *testing.T) { + t.Parallel() + f := initFixture(t) + + ctx := f.sdkCtx + stakingKeeper := f.stakingKeeper + bankKeeper := f.bankKeeper + accountKeeper := f.accountKeeper + + msgServer := keeper.NewMsgServerImpl(stakingKeeper) + bondDenom, err := stakingKeeper.BondDenom(ctx) + assert.NilError(t, err) + + params, err := stakingKeeper.Params.Get(ctx) + assert.NilError(t, err) + + params.KeyRotationFee = sdk.NewInt64Coin(bondDenom, 10) + err = stakingKeeper.Params.Set(ctx, params) + assert.NilError(t, err) + + addrs := simtestutil.AddTestAddrsIncremental(bankKeeper, stakingKeeper, ctx, 5, stakingKeeper.TokensFromConsensusPower(ctx, 100)) + valAddrs := simtestutil.ConvertAddrsToValAddrs(addrs) + + // create 5 validators + for i := 0; i < 5; i++ { + comm := types.NewCommissionRates(math.LegacyNewDec(0), math.LegacyNewDec(0), math.LegacyNewDec(0)) + + msg, err := types.NewMsgCreateValidator(valAddrs[i].String(), PKs[i], sdk.NewCoin(sdk.DefaultBondDenom, stakingKeeper.TokensFromConsensusPower(ctx, 30)), + types.Description{Moniker: "NewVal"}, comm, math.OneInt()) + assert.NilError(t, err) + _, err = msgServer.CreateValidator(ctx, msg) + assert.NilError(t, err) + } + + // call endblocker to update the validator state + _, err = stakingKeeper.EndBlocker(ctx.WithBlockHeight(ctx.BlockHeader().Height + 1)) + assert.NilError(t, err) + + params, err = stakingKeeper.Params.Get(ctx) + assert.NilError(t, err) + + validators, err := stakingKeeper.GetAllValidators(ctx) + assert.NilError(t, err) + assert.Equal(t, len(validators) >= 5, true) + + testCases := []struct { + name string + malleate func() sdk.Context + pass bool + validator string + newPubKey cryptotypes.PubKey + expErrMsg string + expHistoryObjs int + fees sdk.Coin + }{ + { + name: "successful consensus pubkey rotation", + malleate: func() sdk.Context { + return ctx + }, + validator: validators[0].GetOperator(), + newPubKey: PKs[499], + pass: true, + expHistoryObjs: 1, + fees: params.KeyRotationFee, + }, + { + name: "non existing validator check", + malleate: func() sdk.Context { + return ctx + }, + validator: sdk.ValAddress("non_existing_val").String(), + newPubKey: PKs[498], + pass: false, + expErrMsg: "validator does not exist", + }, + { + name: "pubkey already associated with another validator", + malleate: func() sdk.Context { + return ctx + }, + validator: validators[0].GetOperator(), + newPubKey: validators[1].ConsensusPubkey.GetCachedValue().(cryptotypes.PubKey), + pass: false, + expErrMsg: "consensus pubkey is already used for a validator", + }, + { + name: "consensus pubkey rotation limit check", + malleate: func() sdk.Context { + params, err := stakingKeeper.Params.Get(ctx) + assert.NilError(t, err) + + params.KeyRotationFee = sdk.NewInt64Coin(bondDenom, 10) + err = stakingKeeper.Params.Set(ctx, params) + assert.NilError(t, err) + + msg, err := types.NewMsgRotateConsPubKey( + validators[1].GetOperator(), + PKs[498], + ) + assert.NilError(t, err) + _, err = msgServer.RotateConsPubKey(ctx, msg) + assert.NilError(t, err) + + return ctx + }, + validator: validators[1].GetOperator(), + newPubKey: PKs[497], + pass: false, + expErrMsg: "exceeding maximum consensus pubkey rotations within unbonding period", + }, + { + name: "limit reached, but should rotate after the unbonding period", + malleate: func() sdk.Context { + params, err := stakingKeeper.Params.Get(ctx) + assert.NilError(t, err) + + params.KeyRotationFee = sdk.NewInt64Coin(bondDenom, 10) + err = stakingKeeper.Params.Set(ctx, params) + assert.NilError(t, err) + + msg, err := types.NewMsgRotateConsPubKey( + validators[3].GetOperator(), + PKs[495], + ) + + assert.NilError(t, err) + _, err = msgServer.RotateConsPubKey(ctx, msg) + assert.NilError(t, err) + ctx = ctx.WithBlockHeight(ctx.BlockHeight() + 1) + + // this shouldn't remove the existing keys from waiting queue since unbonding time isn't reached + _, err = stakingKeeper.EndBlocker(ctx) + assert.NilError(t, err) + // stakingKeeper.UpdateAllMaturedConsKeyRotatedKeys(ctx, ctx.BlockHeader().Time) + + msg, err = types.NewMsgRotateConsPubKey( + validators[3].GetOperator(), + PKs[494], + ) + + assert.NilError(t, err) + _, err = msgServer.RotateConsPubKey(ctx, msg) + assert.Error(t, err, "exceeding maximum consensus pubkey rotations within unbonding period") + + ctx = ctx.WithBlockHeight(ctx.BlockHeight() + 1) + + newCtx := ctx.WithHeaderInfo(header.Info{Time: ctx.HeaderInfo().Time.Add(params.UnbondingTime)}) + newCtx = newCtx.WithBlockHeight(newCtx.BlockHeight() + 1) + // this should remove keys from waiting queue since unbonding time is reached + _, err = stakingKeeper.EndBlocker(newCtx) + assert.NilError(t, err) + // stakingKeeper.UpdateAllMaturedConsKeyRotatedKeys(newCtx, newCtx.BlockHeader().Time) + + return newCtx + }, + validator: validators[3].GetOperator(), + newPubKey: PKs[494], + pass: true, + expErrMsg: "", + expHistoryObjs: 2, + fees: params.KeyRotationFee, + }, + } + + for _, testCase := range testCases { + t.Run(testCase.name, func(t *testing.T) { + newCtx := testCase.malleate() + oldDistrBalance := bankKeeper.GetBalance(newCtx, accountKeeper.GetModuleAddress(pooltypes.ModuleName), bondDenom) + msg, err := types.NewMsgRotateConsPubKey( + testCase.validator, + testCase.newPubKey, + ) + assert.NilError(t, err) + + _, err = msgServer.RotateConsPubKey(newCtx, msg) + + if testCase.pass { + assert.NilError(t, err) + + _, err = stakingKeeper.EndBlocker(newCtx) + assert.NilError(t, err) + + // rotation fee payment from sender to distrtypes + newDistrBalance := bankKeeper.GetBalance(newCtx, accountKeeper.GetModuleAddress(pooltypes.ModuleName), bondDenom) + assert.DeepEqual(t, newDistrBalance, oldDistrBalance.Add(testCase.fees)) + + valBytes, err := stakingKeeper.ValidatorAddressCodec().StringToBytes(testCase.validator) + assert.NilError(t, err) + + // validator consensus pubkey update check + validator, err := stakingKeeper.GetValidator(newCtx, valBytes) + assert.NilError(t, err) + + consAddr, err := validator.GetConsAddr() + assert.NilError(t, err) + assert.DeepEqual(t, consAddr, testCase.newPubKey.Address().Bytes()) + + // consensus rotation history set check + historyObjects, err := stakingKeeper.GetValidatorConsPubKeyRotationHistory(newCtx, valBytes) + assert.NilError(t, err) + assert.Equal(t, len(historyObjects), testCase.expHistoryObjs) + + historyObjects, err = stakingKeeper.GetBlockConsPubKeyRotationHistory(newCtx) + assert.NilError(t, err) + assert.Equal(t, len(historyObjects), 1) + + } else { + assert.ErrorContains(t, err, testCase.expErrMsg) + } + }) + } +} diff --git a/tests/integration/staking/simulation/operations_test.go b/tests/integration/staking/simulation/operations_test.go index c581db3d120e..a5340acee22c 100644 --- a/tests/integration/staking/simulation/operations_test.go +++ b/tests/integration/staking/simulation/operations_test.go @@ -146,6 +146,7 @@ func (s *SimTestSuite) TestWeightedOperations() { {simulation.DefaultWeightMsgUndelegate, types.ModuleName, sdk.MsgTypeURL(&types.MsgUndelegate{})}, {simulation.DefaultWeightMsgBeginRedelegate, types.ModuleName, sdk.MsgTypeURL(&types.MsgBeginRedelegate{})}, {simulation.DefaultWeightMsgCancelUnbondingDelegation, types.ModuleName, sdk.MsgTypeURL(&types.MsgCancelUnbondingDelegation{})}, + {simulation.DefaultWeightMsgRotateConsPubKey, types.ModuleName, sdk.MsgTypeURL(&types.MsgRotateConsPubKey{})}, } for i, w := range weightedOps { @@ -367,6 +368,32 @@ func (s *SimTestSuite) TestSimulateMsgBeginRedelegate() { require.Len(futureOperations, 0) } +func (s *SimTestSuite) TestSimulateRotateConsPubKey() { + require := s.Require() + blockTime := time.Now().UTC() + ctx := s.ctx.WithHeaderInfo(header.Info{Time: blockTime}) + + _ = s.getTestingValidator2(ctx) + + // begin a new block + _, err := s.app.FinalizeBlock(&abci.RequestFinalizeBlock{Height: s.app.LastBlockHeight() + 1, Hash: s.app.LastCommitID().Hash, Time: blockTime}) + require.NoError(err) + + // execute operation + op := simulation.SimulateMsgRotateConsPubKey(s.txConfig, s.accountKeeper, s.bankKeeper, s.stakingKeeper) + operationMsg, futureOperations, err := op(s.r, s.app.BaseApp, ctx, s.accounts, "") + require.NoError(err) + + var msg types.MsgRotateConsPubKey + err = proto.Unmarshal(operationMsg.Msg, &msg) + require.NoError(err) + + require.True(operationMsg.OK) + require.Equal(sdk.MsgTypeURL(&types.MsgRotateConsPubKey{}), sdk.MsgTypeURL(&msg)) + require.Equal("cosmosvaloper1p8wcgrjr4pjju90xg6u9cgq55dxwq8j7epjs3u", msg.ValidatorAddress) + require.Len(futureOperations, 0) +} + func (s *SimTestSuite) getTestingValidator0(ctx sdk.Context) types.Validator { commission0 := types.NewCommission(math.LegacyZeroDec(), math.LegacyOneDec(), math.LegacyOneDec()) return s.getTestingValidator(ctx, commission0, 1) @@ -393,6 +420,14 @@ func (s *SimTestSuite) getTestingValidator(ctx sdk.Context, commission types.Com return validator } +func (s *SimTestSuite) getTestingValidator2(ctx sdk.Context) types.Validator { + val := s.getTestingValidator0(ctx) + val.Status = types.Bonded + s.Require().NoError(s.stakingKeeper.SetValidator(ctx, val)) + s.Require().NoError(s.stakingKeeper.SetValidatorByConsAddr(ctx, val)) + return val +} + func (s *SimTestSuite) setupValidatorRewards(ctx sdk.Context, valAddress sdk.ValAddress) { decCoins := sdk.DecCoins{sdk.NewDecCoinFromDec(sdk.DefaultBondDenom, math.LegacyOneDec())} historicalRewards := distrtypes.NewValidatorHistoricalRewards(decCoins, 2) diff --git a/x/slashing/keeper/signing_info_test.go b/x/slashing/keeper/signing_info_test.go index 13d88ca4cf78..6b779c49a44e 100644 --- a/x/slashing/keeper/signing_info_test.go +++ b/x/slashing/keeper/signing_info_test.go @@ -8,6 +8,7 @@ import ( "cosmossdk.io/x/slashing/testutil" slashingtypes "cosmossdk.io/x/slashing/types" + simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -111,3 +112,49 @@ func (s *KeeperTestSuite) TestValidatorMissedBlockBitmap_SmallWindow() { require.Len(missedBlocks, int(params.SignedBlocksWindow)-1) } } + +func (s *KeeperTestSuite) TestPerformConsensusPubKeyUpdate() { + ctx, slashingKeeper := s.ctx, s.slashingKeeper + + require := s.Require() + + pks := simtestutil.CreateTestPubKeys(500) + + oldConsAddr := sdk.ConsAddress(pks[0].Address()) + newConsAddr := sdk.ConsAddress(pks[1].Address()) + + newInfo := slashingtypes.NewValidatorSigningInfo( + oldConsAddr.String(), + int64(4), + int64(3), + time.Unix(2, 0).UTC(), + false, + int64(10), + ) + + err := slashingKeeper.ValidatorSigningInfo.Set(ctx, oldConsAddr, newInfo) + require.NoError(err) + + s.stakingKeeper.EXPECT().ValidatorIdentifier(gomock.Any(), oldConsAddr).Return(oldConsAddr, nil) + err = slashingKeeper.SetMissedBlockBitmapValue(ctx, oldConsAddr, 10, true) + require.NoError(err) + + err = slashingKeeper.Hooks().AfterConsensusPubKeyUpdate(ctx, pks[0], pks[1], sdk.Coin{}) + require.NoError(err) + + // check pubkey relation is set properly + savedPubKey, err := slashingKeeper.GetPubkey(ctx, newConsAddr.Bytes()) + require.NoError(err) + require.Equal(savedPubKey, pks[1]) + + // check validator SigningInfo is set properly to new consensus pubkey + signingInfo, err := slashingKeeper.ValidatorSigningInfo.Get(ctx, newConsAddr) + require.NoError(err) + require.Equal(signingInfo, newInfo) + + // missed blocks maps to old cons key only since there is a identifier added to get the missed blocks using the new cons key. + missedBlocks, err := slashingKeeper.GetValidatorMissedBlocks(ctx, oldConsAddr) + require.NoError(err) + + require.Len(missedBlocks, 1) +} diff --git a/x/staking/keeper/cons_pubkey.go b/x/staking/keeper/cons_pubkey.go index c6a9763df328..03e41f226186 100644 --- a/x/staking/keeper/cons_pubkey.go +++ b/x/staking/keeper/cons_pubkey.go @@ -131,8 +131,8 @@ func (k Keeper) ValidatorIdentifier(ctx context.Context, newPk sdk.ConsAddress) return pk, nil } -// exceedsMaxRotations returns true if the key rotations exceed the limit, currently we are limiting one rotation for unbonding period. -func (k Keeper) exceedsMaxRotations(ctx context.Context, valAddr sdk.ValAddress) error { +// ExceedsMaxRotations returns true if the key rotations exceed the limit, currently we are limiting one rotation for unbonding period. +func (k Keeper) ExceedsMaxRotations(ctx context.Context, valAddr sdk.ValAddress) error { count := 0 rng := collections.NewPrefixedPairRange[[]byte, time.Time](valAddr) diff --git a/x/staking/keeper/msg_server.go b/x/staking/keeper/msg_server.go index 0814e4b56bf9..b45b81099a4d 100644 --- a/x/staking/keeper/msg_server.go +++ b/x/staking/keeper/msg_server.go @@ -655,7 +655,7 @@ func (k msgServer) RotateConsPubKey(ctx context.Context, msg *types.MsgRotateCon // Check if the validator is exceeding parameter MaxConsPubKeyRotations within the // unbonding period by iterating ConsPubKeyRotationHistory. - err = k.exceedsMaxRotations(ctx, valAddr) + err = k.ExceedsMaxRotations(ctx, valAddr) if err != nil { return nil, err } diff --git a/x/staking/keeper/validator.go b/x/staking/keeper/validator.go index ca3f0391fa8f..0fd4fb1a072f 100644 --- a/x/staking/keeper/validator.go +++ b/x/staking/keeper/validator.go @@ -37,18 +37,29 @@ func (k Keeper) GetValidator(ctx context.Context, addr sdk.ValAddress) (validato // GetValidatorByConsAddr gets a single validator by consensus address func (k Keeper) GetValidatorByConsAddr(ctx context.Context, consAddr sdk.ConsAddress) (validator types.Validator, err error) { opAddr, err := k.ValidatorByConsensusAddress.Get(ctx, consAddr) - if err != nil && !errors.Is(err, collections.ErrNotFound) { - // if the validator not found try to find it in the map of `OldToNewConsKeyMap`` because validator may've rotated it's key. + if err != nil { + // if the validator not found try to find it in the map of `OldToNewConsKeyMap` because validator may've rotated it's key. if !errors.Is(err, collections.ErrNotFound) { return types.Validator{}, err } - newConsAddr, err := k.OldToNewConsKeyMap.Get(ctx, consAddr) + newConsAddr, err := k.OldToNewConsKeyMap.Get(ctx, consAddr.Bytes()) + if err != nil { + if errors.Is(err, collections.ErrNotFound) { + return types.Validator{}, types.ErrNoValidatorFound + } + return types.Validator{}, err + } + + operatorAddr, err := k.ValidatorByConsensusAddress.Get(ctx, newConsAddr) if err != nil { + if errors.Is(err, collections.ErrNotFound) { + return types.Validator{}, types.ErrNoValidatorFound + } return types.Validator{}, err } - opAddr = newConsAddr + opAddr = operatorAddr } if opAddr == nil { diff --git a/x/staking/keeper/validator_test.go b/x/staking/keeper/validator_test.go index 948b9d671ecb..d3bc3316f46a 100644 --- a/x/staking/keeper/validator_test.go +++ b/x/staking/keeper/validator_test.go @@ -9,6 +9,7 @@ import ( "cosmossdk.io/collections" "cosmossdk.io/core/header" "cosmossdk.io/math" + authtypes "cosmossdk.io/x/auth/types" stakingkeeper "cosmossdk.io/x/staking/keeper" "cosmossdk.io/x/staking/testutil" stakingtypes "cosmossdk.io/x/staking/types" @@ -442,3 +443,71 @@ func (s *KeeperTestSuite) TestUnbondingValidator() { require.NoError(err) require.Equal(stakingtypes.Unbonded, validator.Status) } + +func (s *KeeperTestSuite) TestValidatorConsPubKeyUpdate() { + ctx, keeper, msgServer, bk, ak := s.ctx, s.stakingKeeper, s.msgServer, s.bankKeeper, s.accountKeeper + require := s.Require() + + powers := []int64{10, 20} + var validators [2]stakingtypes.Validator + + bonedPool := authtypes.NewEmptyModuleAccount(stakingtypes.BondedPoolName) + ak.EXPECT().GetModuleAccount(gomock.Any(), stakingtypes.BondedPoolName).Return(bonedPool).AnyTimes() + bk.EXPECT().GetBalance(gomock.Any(), bonedPool.GetAddress(), sdk.DefaultBondDenom).Return(sdk.NewInt64Coin(sdk.DefaultBondDenom, 1000000)).AnyTimes() + + for i, power := range powers { + valAddr := sdk.ValAddress(PKs[i].Address().Bytes()) + validators[i] = testutil.NewValidator(s.T(), valAddr, PKs[i]) + tokens := keeper.TokensFromConsensusPower(ctx, power) + + validators[i], _ = validators[i].AddTokensFromDel(tokens) + require.NoError(keeper.SetValidator(ctx, validators[i])) + require.NoError(keeper.SetValidatorByPowerIndex(ctx, validators[i])) + require.NoError(keeper.SetValidatorByConsAddr(ctx, validators[i])) + + s.bankKeeper.EXPECT().SendCoinsFromModuleToModule(gomock.Any(), stakingtypes.NotBondedPoolName, stakingtypes.BondedPoolName, gomock.Any()) + updates := s.applyValidatorSetUpdates(ctx, keeper, 1) + validator, err := keeper.GetValidator(ctx, valAddr) + require.NoError(err) + require.Equal(validator.ABCIValidatorUpdate(keeper.PowerReduction(ctx)), updates[0]) + } + + params, err := keeper.Params.Get(ctx) + require.NoError(err) + + params.KeyRotationFee = sdk.NewInt64Coin(sdk.DefaultBondDenom, 1000) + err = keeper.Params.Set(ctx, params) + require.NoError(err) + + valAddr1 := sdk.ValAddress(PKs[0].Address().Bytes()) + + valStr, err := keeper.ValidatorAddressCodec().BytesToString(valAddr1) + require.NoError(err) + + msg, err := stakingtypes.NewMsgRotateConsPubKey( + valStr, + PKs[499], // taking the last element from PKs + ) + + require.NoError(err) + + bk.EXPECT().SendCoinsFromAccountToModule(ctx, sdk.AccAddress(valAddr1), gomock.Any(), gomock.Any()).AnyTimes() + _, err = msgServer.RotateConsPubKey(ctx, msg) + require.NoError(err) + + updates := s.applyValidatorSetUpdates(ctx, keeper, 2) + + originalPubKey, err := validators[0].CmtConsPublicKey() + require.NoError(err) + + validator, err := keeper.GetValidator(ctx, valAddr1) + require.NoError(err) + + newPubKey, err := validator.CmtConsPublicKey() + require.NoError(err) + + require.Equal(int64(0), updates[0].Power) + require.Equal(originalPubKey, updates[0].PubKey) + require.Equal(int64(10), updates[1].Power) + require.Equal(newPubKey, updates[1].PubKey) +} diff --git a/x/staking/simulation/operations.go b/x/staking/simulation/operations.go index 7fca2e8d8d25..9193fd5522fe 100644 --- a/x/staking/simulation/operations.go +++ b/x/staking/simulation/operations.go @@ -26,6 +26,7 @@ const ( DefaultWeightMsgUndelegate int = 100 DefaultWeightMsgBeginRedelegate int = 100 DefaultWeightMsgCancelUnbondingDelegation int = 100 + DefaultWeightMsgRotateConsPubKey int = 100 OpWeightMsgCreateValidator = "op_weight_msg_create_validator" OpWeightMsgEditValidator = "op_weight_msg_edit_validator" @@ -33,6 +34,7 @@ const ( OpWeightMsgUndelegate = "op_weight_msg_undelegate" OpWeightMsgBeginRedelegate = "op_weight_msg_begin_redelegate" OpWeightMsgCancelUnbondingDelegation = "op_weight_msg_cancel_unbonding_delegation" + OpWeightMsgRotateConsPubKey = "op_weight_msg_rotate_cons_pubkey" ) // WeightedOperations returns all the operations from the module with their respective weights @@ -51,6 +53,7 @@ func WeightedOperations( weightMsgUndelegate int weightMsgBeginRedelegate int weightMsgCancelUnbondingDelegation int + weightMsgRotateConsPubKey int ) appParams.GetOrGenerate(OpWeightMsgCreateValidator, &weightMsgCreateValidator, nil, func(_ *rand.Rand) { @@ -77,6 +80,10 @@ func WeightedOperations( weightMsgCancelUnbondingDelegation = DefaultWeightMsgCancelUnbondingDelegation }) + appParams.GetOrGenerate(OpWeightMsgRotateConsPubKey, &weightMsgRotateConsPubKey, nil, func(_ *rand.Rand) { + weightMsgRotateConsPubKey = DefaultWeightMsgRotateConsPubKey + }) + return simulation.WeightedOperations{ simulation.NewWeightedOperation( weightMsgCreateValidator, @@ -102,6 +109,10 @@ func WeightedOperations( weightMsgCancelUnbondingDelegation, SimulateMsgCancelUnbondingDelegate(txGen, ak, bk, k), ), + simulation.NewWeightedOperation( + weightMsgRotateConsPubKey, + SimulateMsgRotateConsPubKey(txGen, ak, bk, k), + ), } } @@ -126,6 +137,12 @@ func SimulateMsgCreateValidator( return simtypes.NoOpMsg(types.ModuleName, msgType, "validator already exists"), nil, nil } + consPubKey := sdk.GetConsAddress(simAccount.ConsKey.PubKey()) + _, err = k.GetValidatorByConsAddr(ctx, consPubKey) + if err == nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "cons key already used"), nil, nil + } + denom, err := k.BondDenom(ctx) if err != nil { return simtypes.NoOpMsg(types.ModuleName, msgType, "bond denom not found"), nil, err @@ -705,3 +722,102 @@ func SimulateMsgBeginRedelegate( return simulation.GenAndDeliverTxWithRandFees(txCtx) } } + +func SimulateMsgRotateConsPubKey(txGen client.TxConfig, ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation { + return func( + r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accs []simtypes.Account, chainID string, + ) (simtypes.OperationMsg, []simtypes.FutureOperation, error) { + msgType := sdk.MsgTypeURL(&types.MsgRotateConsPubKey{}) + + vals, err := k.GetAllValidators(ctx) + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "unable to get validators"), nil, err + } + + if len(vals) == 0 { + return simtypes.NoOpMsg(types.ModuleName, msgType, "number of validators equal zero"), nil, nil + } + + val, ok := testutil.RandSliceElem(r, vals) + if !ok { + return simtypes.NoOpMsg(types.ModuleName, msgType, "unable to pick a validator"), nil, nil + } + + if val.Status != types.Bonded || val.ConsensusPower(sdk.DefaultPowerReduction) == 0 { + return simtypes.NoOpMsg(types.ModuleName, msgType, "validator not bonded."), nil, nil + } + + valAddr := val.GetOperator() + valBytes, err := k.ValidatorAddressCodec().StringToBytes(valAddr) + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "error getting validator address bytes"), nil, err + } + + simAccount, found := simtypes.FindAccount(accs, sdk.AccAddress(valBytes)) + if !found { + return simtypes.NoOpMsg(types.ModuleName, msgType, "unable to find account"), nil, fmt.Errorf("validator %s not found", val.GetOperator()) + } + + cons, err := val.GetConsAddr() + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "cannot get conskey"), nil, err + } + + acc, _ := simtypes.RandomAcc(r, accs) + if sdk.ConsAddress(cons).String() == sdk.ConsAddress(acc.ConsKey.PubKey().Address()).String() { + return simtypes.NoOpMsg(types.ModuleName, msgType, "new pubkey and current pubkey should be different"), nil, nil + } + + account := ak.GetAccount(ctx, simAccount.Address) + if account == nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "unable to find account"), nil, nil + } + + spendable := bk.SpendableCoins(ctx, account.GetAddress()) + params, err := k.Params.Get(ctx) + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "cannot get params"), nil, err + } + + if !spendable.IsAllGTE(sdk.NewCoins(params.KeyRotationFee)) { + return simtypes.NoOpMsg(types.ModuleName, msgType, "not enough balance to pay fee"), nil, nil + } + + if err := k.ExceedsMaxRotations(ctx, valBytes); err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "rotations limit reached within unbonding period"), nil, nil + } + + _, err = k.GetValidatorByConsAddr(ctx, cons) + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "cannot get validator"), nil, err + } + + // check whether the new cons key associated with another validator + newConsAddr := sdk.ConsAddress(acc.ConsKey.PubKey().Address()) + _, err = k.GetValidatorByConsAddr(ctx, newConsAddr) + if err == nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "cons key already used"), nil, nil + } + + msg, err := types.NewMsgRotateConsPubKey(valAddr, acc.ConsKey.PubKey()) + if err != nil { + return simtypes.NoOpMsg(types.ModuleName, msgType, "unable to build msg"), nil, err + } + + txCtx := simulation.OperationInput{ + R: r, + App: app, + TxGen: txGen, + Cdc: nil, + Msg: msg, + Context: ctx, + SimAccount: simAccount, + AccountKeeper: ak, + Bankkeeper: bk, + ModuleName: types.ModuleName, + CoinsSpentInMsg: spendable, + } + + return simulation.GenAndDeliverTxWithRandFees(txCtx) + } +} From 23bea3ea7708512bea63e6333634cf631a280ee5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 10:31:44 +0100 Subject: [PATCH 05/28] build(deps): Bump golang.org/x/crypto from 0.17.0 to 0.18.0 (#18982) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> --- client/v2/go.mod | 6 +++--- client/v2/go.sum | 12 ++++++------ go.mod | 6 +++--- go.sum | 12 ++++++------ simapp/go.mod | 6 +++--- simapp/go.sum | 12 ++++++------ simapp/gomod2nix.toml | 12 ++++++------ store/go.mod | 5 ++--- store/go.sum | 11 +++++------ tests/go.mod | 6 +++--- tests/go.sum | 12 ++++++------ tests/starship/tests/go.mod | 6 +++--- tests/starship/tests/go.sum | 12 ++++++------ tools/confix/go.mod | 6 +++--- tools/confix/go.sum | 12 ++++++------ tools/cosmovisor/go.mod | 6 +++--- tools/cosmovisor/go.sum | 12 ++++++------ tools/hubl/go.mod | 6 +++--- tools/hubl/go.sum | 12 ++++++------ x/accounts/go.mod | 6 +++--- x/accounts/go.sum | 12 ++++++------ x/auth/go.mod | 6 +++--- x/auth/go.sum | 12 ++++++------ x/authz/go.mod | 6 +++--- x/authz/go.sum | 12 ++++++------ x/bank/go.mod | 6 +++--- x/bank/go.sum | 12 ++++++------ x/circuit/go.mod | 6 +++--- x/circuit/go.sum | 12 ++++++------ x/distribution/go.mod | 6 +++--- x/distribution/go.sum | 12 ++++++------ x/evidence/go.mod | 6 +++--- x/evidence/go.sum | 12 ++++++------ x/feegrant/go.mod | 6 +++--- x/feegrant/go.sum | 12 ++++++------ x/gov/go.mod | 6 +++--- x/gov/go.sum | 12 ++++++------ x/group/go.mod | 6 +++--- x/group/go.sum | 12 ++++++------ x/mint/go.mod | 6 +++--- x/mint/go.sum | 12 ++++++------ x/nft/go.mod | 6 +++--- x/nft/go.sum | 12 ++++++------ x/params/go.mod | 6 +++--- x/params/go.sum | 12 ++++++------ x/protocolpool/go.mod | 6 +++--- x/protocolpool/go.sum | 12 ++++++------ x/slashing/go.mod | 6 +++--- x/slashing/go.sum | 12 ++++++------ x/staking/go.mod | 6 +++--- x/staking/go.sum | 12 ++++++------ x/upgrade/go.mod | 6 +++--- x/upgrade/go.sum | 12 ++++++------ 53 files changed, 238 insertions(+), 240 deletions(-) diff --git a/client/v2/go.mod b/client/v2/go.mod index ec21e84e47ae..fda712d75bfe 100644 --- a/client/v2/go.mod +++ b/client/v2/go.mod @@ -147,13 +147,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/client/v2/go.sum b/client/v2/go.sum index aa8a920b3c3d..0a913cb49f9b 100644 --- a/client/v2/go.sum +++ b/client/v2/go.sum @@ -759,8 +759,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -880,12 +880,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/go.mod b/go.mod index dba471f0bca0..68e457662fc0 100644 --- a/go.mod +++ b/go.mod @@ -54,7 +54,7 @@ require ( github.com/stretchr/testify v1.8.4 github.com/tendermint/go-amino v0.16.0 gitlab.com/yawning/secp256k1-voi v0.0.0-20230925100816-f2616030848b - golang.org/x/crypto v0.17.0 + golang.org/x/crypto v0.18.0 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b golang.org/x/sync v0.6.0 google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f @@ -159,8 +159,8 @@ require ( go.uber.org/multierr v1.11.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/go.sum b/go.sum index 50930a951c89..ae1d53ed0d9a 100644 --- a/go.sum +++ b/go.sum @@ -768,8 +768,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -899,15 +899,15 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/simapp/go.mod b/simapp/go.mod index cf2c868ed1e4..b47ec9ca820b 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -193,14 +193,14 @@ require ( go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/oauth2 v0.15.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect diff --git a/simapp/go.sum b/simapp/go.sum index 63c247c3ec8d..4863ae871b14 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -1076,8 +1076,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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= @@ -1327,16 +1327,16 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= 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= diff --git a/simapp/gomod2nix.toml b/simapp/gomod2nix.toml index 249f2d76444a..967ec3dbfdf8 100644 --- a/simapp/gomod2nix.toml +++ b/simapp/gomod2nix.toml @@ -487,8 +487,8 @@ schema = 3 version = "v1.11.0" hash = "sha256-Lb6rHHfR62Ozg2j2JZy3MKOMKdsfzd1IYTR57r3Mhp0=" [mod."golang.org/x/crypto"] - version = "v0.17.0" - hash = "sha256-/vzBaeD/Ymyc7cpjBvSfJfuZ57zWa9LOaZM7b33eIx0=" + version = "v0.18.0" + hash = "sha256-BuMVUxOIyfLo8MOhqYt+uQ8NDN6P2KdblKyfPxINzQ4=" [mod."golang.org/x/exp"] version = "v0.0.0-20231226003508-02704c960a9b" hash = "sha256-K35MT3O16IlvqhDZBVBF4lJZIM7T/15PxOmeyGYv01A=" @@ -505,11 +505,11 @@ schema = 3 version = "v0.6.0" hash = "sha256-LLims/wjDZtIqlYCVHREewcUOX4hwRwplEuZKPOJ/HI=" [mod."golang.org/x/sys"] - version = "v0.15.0" - hash = "sha256-n7TlABF6179RzGq3gctPDKDPRtDfnwPdjNCMm8ps2KY=" + version = "v0.16.0" + hash = "sha256-ZkGclbp2S7NQYhbuGji6XokCn2Qi1BJy8dwyAOTV8sY=" [mod."golang.org/x/term"] - version = "v0.15.0" - hash = "sha256-rsvtsE7sKmBwtR+mhJ8iUq93ZT8fV2LU+Pd69sh2es8=" + version = "v0.16.0" + hash = "sha256-9qlHcsCI1sa7ZI4Q+fJbOp3mG5Y+uV16e+pGmG+MQe0=" [mod."golang.org/x/text"] version = "v0.14.0" hash = "sha256-yh3B0tom1RfzQBf1RNmfdNWF1PtiqxV41jW1GVS6JAg=" diff --git a/store/go.mod b/store/go.mod index 2f657cb22282..ce1e8ecea20e 100644 --- a/store/go.mod +++ b/store/go.mod @@ -58,15 +58,14 @@ require ( github.com/sasha-s/go-deadlock v0.3.1 // indirect github.com/spf13/cast v1.5.1 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/net v0.19.0 // indirect - golang.org/x/sys v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect google.golang.org/grpc v1.60.1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - gotest.tools/v3 v3.5.1 // indirect ) replace cosmossdk.io/core => ../core diff --git a/store/go.sum b/store/go.sum index f35dc6089c13..8d4086be9ef3 100644 --- a/store/go.sum +++ b/store/go.sum @@ -1,5 +1,3 @@ -cosmossdk.io/core v0.12.0 h1:aFuvkG6eDv0IQC+UDjx86wxNWVAxdCFk7OABJ1Vh4RU= -cosmossdk.io/core v0.12.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= @@ -235,8 +233,8 @@ golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnf golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= golang.org/x/exp v0.0.0-20231226003508-02704c960a9b h1:kLiC65FbiHWFAOu+lxwNPujcsl8VYyTYYEZnsOO1WK4= golang.org/x/exp v0.0.0-20231226003508-02704c960a9b/go.mod h1:iRJReGqOEeBhDZGkGbynYwcHlctCvnjTYIamk7uXpHI= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= @@ -285,8 +283,8 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -335,5 +333,6 @@ gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= diff --git a/tests/go.mod b/tests/go.mod index f56175e45015..256f1f9e3ca8 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -189,14 +189,14 @@ require ( go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/oauth2 v0.15.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect diff --git a/tests/go.sum b/tests/go.sum index 5dc3eec9cfcb..36cbb203601a 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -1067,8 +1067,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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= @@ -1317,16 +1317,16 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= 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= diff --git a/tests/starship/tests/go.mod b/tests/starship/tests/go.mod index cb3164048fdf..c35871ac4bde 100644 --- a/tests/starship/tests/go.mod +++ b/tests/starship/tests/go.mod @@ -215,14 +215,14 @@ require ( go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/oauth2 v0.15.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect diff --git a/tests/starship/tests/go.sum b/tests/starship/tests/go.sum index af972af11bd5..02f8526d6e78 100644 --- a/tests/starship/tests/go.sum +++ b/tests/starship/tests/go.sum @@ -1072,8 +1072,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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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= @@ -1320,13 +1320,13 @@ golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBc 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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= 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= diff --git a/tools/confix/go.mod b/tools/confix/go.mod index fccee1332449..cbd1311baec0 100644 --- a/tools/confix/go.mod +++ b/tools/confix/go.mod @@ -138,11 +138,11 @@ require ( github.com/zondax/ledger-go v0.14.3 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect diff --git a/tools/confix/go.sum b/tools/confix/go.sum index fcae0d00c1c3..1f1ce37aeae2 100644 --- a/tools/confix/go.sum +++ b/tools/confix/go.sum @@ -759,8 +759,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -879,12 +879,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/tools/cosmovisor/go.mod b/tools/cosmovisor/go.mod index d8aeb32c8d6d..a02ab83ab01a 100644 --- a/tools/cosmovisor/go.mod +++ b/tools/cosmovisor/go.mod @@ -152,13 +152,13 @@ require ( go.etcd.io/bbolt v1.3.8 // indirect go.opencensus.io v0.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231214170342-aacd6d4b4611 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/oauth2 v0.15.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect diff --git a/tools/cosmovisor/go.sum b/tools/cosmovisor/go.sum index df3b5751f78d..7dbf07acefce 100644 --- a/tools/cosmovisor/go.sum +++ b/tools/cosmovisor/go.sum @@ -1031,8 +1031,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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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= @@ -1270,13 +1270,13 @@ golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBc 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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= 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= diff --git a/tools/hubl/go.mod b/tools/hubl/go.mod index 4bb33ec4785f..d161c24b66f4 100644 --- a/tools/hubl/go.mod +++ b/tools/hubl/go.mod @@ -137,12 +137,12 @@ require ( github.com/zondax/ledger-go v0.14.3 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect diff --git a/tools/hubl/go.sum b/tools/hubl/go.sum index 69a150d2c779..8bfd7863d23d 100644 --- a/tools/hubl/go.sum +++ b/tools/hubl/go.sum @@ -758,8 +758,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -876,12 +876,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/accounts/go.mod b/x/accounts/go.mod index 32d99885c126..10db0942b84f 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -137,12 +137,12 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/accounts/go.sum b/x/accounts/go.sum index 10ecd8dd7169..40a03db614c8 100644 --- a/x/accounts/go.sum +++ b/x/accounts/go.sum @@ -723,8 +723,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -840,12 +840,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/auth/go.mod b/x/auth/go.mod index 6a34013d0eb6..98730c511089 100644 --- a/x/auth/go.mod +++ b/x/auth/go.mod @@ -147,12 +147,12 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/auth/go.sum b/x/auth/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/auth/go.sum +++ b/x/auth/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/authz/go.mod b/x/authz/go.mod index 345dad31254f..41cf7be7f757 100644 --- a/x/authz/go.mod +++ b/x/authz/go.mod @@ -148,13 +148,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/authz/go.sum b/x/authz/go.sum index a818346678e1..12fdb7432932 100644 --- a/x/authz/go.sum +++ b/x/authz/go.sum @@ -757,8 +757,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -878,12 +878,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/bank/go.mod b/x/bank/go.mod index 11ac8f5216f4..d450ebf3aa3a 100644 --- a/x/bank/go.mod +++ b/x/bank/go.mod @@ -142,13 +142,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/bank/go.sum b/x/bank/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/bank/go.sum +++ b/x/bank/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/circuit/go.mod b/x/circuit/go.mod index 9527e1e8df40..474060ba6abc 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -142,13 +142,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/circuit/go.sum b/x/circuit/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/distribution/go.mod b/x/distribution/go.mod index 2fad0f6dc664..fb1d08e7d8f0 100644 --- a/x/distribution/go.mod +++ b/x/distribution/go.mod @@ -145,13 +145,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/distribution/go.sum b/x/distribution/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/distribution/go.sum +++ b/x/distribution/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/evidence/go.mod b/x/evidence/go.mod index 8eb753e1bc62..e9dadaaf1f4f 100644 --- a/x/evidence/go.mod +++ b/x/evidence/go.mod @@ -145,13 +145,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/evidence/go.sum b/x/evidence/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/evidence/go.sum +++ b/x/evidence/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/feegrant/go.mod b/x/feegrant/go.mod index 0f975e57c59b..6aa36cacbbdb 100644 --- a/x/feegrant/go.mod +++ b/x/feegrant/go.mod @@ -148,13 +148,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/feegrant/go.sum b/x/feegrant/go.sum index aa8a920b3c3d..0a913cb49f9b 100644 --- a/x/feegrant/go.sum +++ b/x/feegrant/go.sum @@ -759,8 +759,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -880,12 +880,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/gov/go.mod b/x/gov/go.mod index f98ef7577d5d..7d82c8fb0b36 100644 --- a/x/gov/go.mod +++ b/x/gov/go.mod @@ -148,12 +148,12 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/gov/go.sum b/x/gov/go.sum index a818346678e1..12fdb7432932 100644 --- a/x/gov/go.sum +++ b/x/gov/go.sum @@ -757,8 +757,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -878,12 +878,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/group/go.mod b/x/group/go.mod index b369a3b8f945..7fec2fc9b458 100644 --- a/x/group/go.mod +++ b/x/group/go.mod @@ -151,12 +151,12 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/group/go.sum b/x/group/go.sum index c89ba3732fc5..468ae76a8a8e 100644 --- a/x/group/go.sum +++ b/x/group/go.sum @@ -759,8 +759,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -879,12 +879,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/mint/go.mod b/x/mint/go.mod index e7bed665f1c6..9c66386da001 100644 --- a/x/mint/go.mod +++ b/x/mint/go.mod @@ -143,13 +143,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/mint/go.sum b/x/mint/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/mint/go.sum +++ b/x/mint/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/nft/go.mod b/x/nft/go.mod index b0e81a7af709..451da701f726 100644 --- a/x/nft/go.mod +++ b/x/nft/go.mod @@ -143,13 +143,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/nft/go.sum b/x/nft/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/nft/go.sum +++ b/x/nft/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/params/go.mod b/x/params/go.mod index cdf15bbed280..35874b5f3e5b 100644 --- a/x/params/go.mod +++ b/x/params/go.mod @@ -143,13 +143,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/params/go.sum b/x/params/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/params/go.sum +++ b/x/params/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/protocolpool/go.mod b/x/protocolpool/go.mod index afb847dafe0b..53e092ecd1c9 100644 --- a/x/protocolpool/go.mod +++ b/x/protocolpool/go.mod @@ -146,13 +146,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/protocolpool/go.sum b/x/protocolpool/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/protocolpool/go.sum +++ b/x/protocolpool/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/slashing/go.mod b/x/slashing/go.mod index c85fa5580afd..21e660eb5df5 100644 --- a/x/slashing/go.mod +++ b/x/slashing/go.mod @@ -148,13 +148,13 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/slashing/go.sum b/x/slashing/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/slashing/go.sum +++ b/x/slashing/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/staking/go.mod b/x/staking/go.mod index 324c7f778be3..243e228399cb 100644 --- a/x/staking/go.mod +++ b/x/staking/go.mod @@ -149,12 +149,12 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect diff --git a/x/staking/go.sum b/x/staking/go.sum index 1bd6a4773dba..ff10a22331dd 100644 --- a/x/staking/go.sum +++ b/x/staking/go.sum @@ -751,8 +751,8 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 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.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= @@ -871,12 +871,12 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20221010170243-090e33056c14/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.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= diff --git a/x/upgrade/go.mod b/x/upgrade/go.mod index 8cf3a32592fa..b6e1f77fdc75 100644 --- a/x/upgrade/go.mod +++ b/x/upgrade/go.mod @@ -166,14 +166,14 @@ require ( go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect golang.org/x/oauth2 v0.15.0 // indirect golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect + golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect diff --git a/x/upgrade/go.sum b/x/upgrade/go.sum index 18a33d05983b..ea3ac7a1d998 100644 --- a/x/upgrade/go.sum +++ b/x/upgrade/go.sum @@ -1067,8 +1067,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= 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= @@ -1318,16 +1318,16 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= +golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= 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= From 7ecdbd08146bff0ddaac062688497deb4e51ddb6 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Tue, 9 Jan 2024 14:49:05 +0100 Subject: [PATCH 06/28] chore(testutil): use correct address codec (#18985) --- testutil/network/network.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testutil/network/network.go b/testutil/network/network.go index d7342d79cb66..eed00af89868 100644 --- a/testutil/network/network.go +++ b/testutil/network/network.go @@ -557,7 +557,7 @@ func New(l Logger, baseDir string, cfg Config) (NetworkI, error) { WithAccountRetriever(cfg.AccountRetriever). WithAddressCodec(cfg.AddressCodec). WithValidatorAddressCodec(cfg.ValidatorAddressCodec). - WithConsensusAddressCodec(cfg.ValidatorAddressCodec). + WithConsensusAddressCodec(cfg.ConsensusAddressCodec). WithNodeURI(cmtCfg.RPC.ListenAddress) // Provide ChainID here since we can't modify it in the Comet config. From f431a5039cecd04c3d66f0c43b9df75b89d88037 Mon Sep 17 00:00:00 2001 From: testinginprod <98415576+testinginprod@users.noreply.github.com> Date: Tue, 9 Jan 2024 15:02:43 +0100 Subject: [PATCH 07/28] feat(accounts): Add Query to simulate a UserOperation (#18979) Co-authored-by: unknown unknown --- api/cosmos/accounts/v1/query.pulsar.go | 1529 ++++++++++++++--- api/cosmos/accounts/v1/query_grpc.pb.go | 45 +- proto/cosmos/accounts/v1/query.proto | 20 + .../e2e/accounts/account_abstraction_test.go | 41 + x/accounts/query_server.go | 24 + x/accounts/v1/query.pb.go | 522 +++++- 6 files changed, 1924 insertions(+), 257 deletions(-) diff --git a/api/cosmos/accounts/v1/query.pulsar.go b/api/cosmos/accounts/v1/query.pulsar.go index d4a0ff1370d1..73f12ef52015 100644 --- a/api/cosmos/accounts/v1/query.pulsar.go +++ b/api/cosmos/accounts/v1/query.pulsar.go @@ -2100,7 +2100,7 @@ func (x *SchemaResponse_Handler) ProtoReflect() protoreflect.Message { } func (x *SchemaResponse_Handler) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3402,178 +3402,1112 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods } } -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.27.0 -// protoc (unknown) -// source: cosmos/accounts/v1/query.proto - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +var ( + md_SimulateUserOperationRequest protoreflect.MessageDescriptor + fd_SimulateUserOperationRequest_bundler protoreflect.FieldDescriptor + fd_SimulateUserOperationRequest_user_operation protoreflect.FieldDescriptor ) -// AccountQueryRequest is the request type for the Query/AccountQuery RPC -type AccountQueryRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields +func init() { + file_cosmos_accounts_v1_query_proto_init() + md_SimulateUserOperationRequest = File_cosmos_accounts_v1_query_proto.Messages().ByName("SimulateUserOperationRequest") + fd_SimulateUserOperationRequest_bundler = md_SimulateUserOperationRequest.Fields().ByName("bundler") + fd_SimulateUserOperationRequest_user_operation = md_SimulateUserOperationRequest.Fields().ByName("user_operation") +} - // target defines the account to be queried. - Target string `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"` - // request defines the query message being sent to the account. - Request *anypb.Any `protobuf:"bytes,2,opt,name=request,proto3" json:"request,omitempty"` +var _ protoreflect.Message = (*fastReflection_SimulateUserOperationRequest)(nil) + +type fastReflection_SimulateUserOperationRequest SimulateUserOperationRequest + +func (x *SimulateUserOperationRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_SimulateUserOperationRequest)(x) } -func (x *AccountQueryRequest) Reset() { - *x = AccountQueryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[0] +func (x *SimulateUserOperationRequest) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms } + return mi.MessageOf(x) } -func (x *AccountQueryRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} +var _fastReflection_SimulateUserOperationRequest_messageType fastReflection_SimulateUserOperationRequest_messageType +var _ protoreflect.MessageType = fastReflection_SimulateUserOperationRequest_messageType{} -func (*AccountQueryRequest) ProtoMessage() {} +type fastReflection_SimulateUserOperationRequest_messageType struct{} -// Deprecated: Use AccountQueryRequest.ProtoReflect.Descriptor instead. -func (*AccountQueryRequest) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{0} +func (x fastReflection_SimulateUserOperationRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_SimulateUserOperationRequest)(nil) } - -func (x *AccountQueryRequest) GetTarget() string { - if x != nil { - return x.Target - } - return "" +func (x fastReflection_SimulateUserOperationRequest_messageType) New() protoreflect.Message { + return new(fastReflection_SimulateUserOperationRequest) } - -func (x *AccountQueryRequest) GetRequest() *anypb.Any { - if x != nil { - return x.Request - } - return nil +func (x fastReflection_SimulateUserOperationRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SimulateUserOperationRequest } -// AccountQueryResponse is the response type for the Query/AccountQuery RPC method. -type AccountQueryResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // response defines the query response of the account. - Response *anypb.Any `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SimulateUserOperationRequest) Descriptor() protoreflect.MessageDescriptor { + return md_SimulateUserOperationRequest } -func (x *AccountQueryResponse) Reset() { - *x = AccountQueryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SimulateUserOperationRequest) Type() protoreflect.MessageType { + return _fastReflection_SimulateUserOperationRequest_messageType } -func (x *AccountQueryResponse) String() string { - return protoimpl.X.MessageStringOf(x) +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SimulateUserOperationRequest) New() protoreflect.Message { + return new(fastReflection_SimulateUserOperationRequest) } -func (*AccountQueryResponse) ProtoMessage() {} - -// Deprecated: Use AccountQueryResponse.ProtoReflect.Descriptor instead. -func (*AccountQueryResponse) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{1} +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SimulateUserOperationRequest) Interface() protoreflect.ProtoMessage { + return (*SimulateUserOperationRequest)(x) } -func (x *AccountQueryResponse) GetResponse() *anypb.Any { - if x != nil { - return x.Response +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SimulateUserOperationRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Bundler != "" { + value := protoreflect.ValueOfString(x.Bundler) + if !f(fd_SimulateUserOperationRequest_bundler, value) { + return + } + } + if x.UserOperation != nil { + value := protoreflect.ValueOfMessage(x.UserOperation.ProtoReflect()) + if !f(fd_SimulateUserOperationRequest_user_operation, value) { + return + } } - return nil -} - -// SchemaResponse is the response type for the Query/Schema RPC method. -type SchemaRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // account_type defines the account type to query the schema for. - AccountType string `protobuf:"bytes,1,opt,name=account_type,json=accountType,proto3" json:"account_type,omitempty"` } -func (x *SchemaRequest) Reset() { - *x = SchemaRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SimulateUserOperationRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + return x.Bundler != "" + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + return x.UserOperation != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", fd.FullName())) } } -func (x *SchemaRequest) String() string { - return protoimpl.X.MessageStringOf(x) +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + x.Bundler = "" + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + x.UserOperation = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", fd.FullName())) + } } -func (*SchemaRequest) ProtoMessage() {} - -// Deprecated: Use SchemaRequest.ProtoReflect.Descriptor instead. -func (*SchemaRequest) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{2} +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SimulateUserOperationRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + value := x.Bundler + return protoreflect.ValueOfString(value) + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + value := x.UserOperation + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", descriptor.FullName())) + } } -func (x *SchemaRequest) GetAccountType() string { - if x != nil { - return x.AccountType +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + x.Bundler = value.Interface().(string) + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + x.UserOperation = value.Message().Interface().(*UserOperation) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", fd.FullName())) } - return "" } -// SchemaResponse is the response type for the Query/Schema RPC method. -type SchemaResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // init_schema defines the schema descriptor for the Init account method. - InitSchema *SchemaResponse_Handler `protobuf:"bytes,1,opt,name=init_schema,json=initSchema,proto3" json:"init_schema,omitempty"` - // execute_handlers defines the schema descriptor for the Execute account method. - ExecuteHandlers []*SchemaResponse_Handler `protobuf:"bytes,2,rep,name=execute_handlers,json=executeHandlers,proto3" json:"execute_handlers,omitempty"` - // query_handlers defines the schema descriptor for the Query account method. - QueryHandlers []*SchemaResponse_Handler `protobuf:"bytes,3,rep,name=query_handlers,json=queryHandlers,proto3" json:"query_handlers,omitempty"` +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + if x.UserOperation == nil { + x.UserOperation = new(UserOperation) + } + return protoreflect.ValueOfMessage(x.UserOperation.ProtoReflect()) + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + panic(fmt.Errorf("field bundler of message cosmos.accounts.v1.SimulateUserOperationRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", fd.FullName())) + } } -func (x *SchemaResponse) Reset() { - *x = SchemaResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SimulateUserOperationRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationRequest.bundler": + return protoreflect.ValueOfString("") + case "cosmos.accounts.v1.SimulateUserOperationRequest.user_operation": + m := new(UserOperation) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationRequest does not contain field %s", fd.FullName())) } } -func (x *SchemaResponse) String() string { - return protoimpl.X.MessageStringOf(x) +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SimulateUserOperationRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.SimulateUserOperationRequest", d.FullName())) + } + panic("unreachable") } -func (*SchemaResponse) ProtoMessage() {} - -// Deprecated: Use SchemaResponse.ProtoReflect.Descriptor instead. -func (*SchemaResponse) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{3} +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SimulateUserOperationRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields } -func (x *SchemaResponse) GetInitSchema() *SchemaResponse_Handler { - if x != nil { - return x.InitSchema - } - return nil +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SimulateUserOperationRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SimulateUserOperationRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SimulateUserOperationRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Bundler) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.UserOperation != nil { + l = options.Size(x.UserOperation) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SimulateUserOperationRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.UserOperation != nil { + encoded, err := options.Marshal(x.UserOperation) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Bundler) > 0 { + i -= len(x.Bundler) + copy(dAtA[i:], x.Bundler) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Bundler))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SimulateUserOperationRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SimulateUserOperationRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SimulateUserOperationRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bundler", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bundler = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field UserOperation", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.UserOperation == nil { + x.UserOperation = &UserOperation{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.UserOperation); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_SimulateUserOperationResponse protoreflect.MessageDescriptor + fd_SimulateUserOperationResponse_user_operation_response protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_accounts_v1_query_proto_init() + md_SimulateUserOperationResponse = File_cosmos_accounts_v1_query_proto.Messages().ByName("SimulateUserOperationResponse") + fd_SimulateUserOperationResponse_user_operation_response = md_SimulateUserOperationResponse.Fields().ByName("user_operation_response") +} + +var _ protoreflect.Message = (*fastReflection_SimulateUserOperationResponse)(nil) + +type fastReflection_SimulateUserOperationResponse SimulateUserOperationResponse + +func (x *SimulateUserOperationResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_SimulateUserOperationResponse)(x) +} + +func (x *SimulateUserOperationResponse) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_SimulateUserOperationResponse_messageType fastReflection_SimulateUserOperationResponse_messageType +var _ protoreflect.MessageType = fastReflection_SimulateUserOperationResponse_messageType{} + +type fastReflection_SimulateUserOperationResponse_messageType struct{} + +func (x fastReflection_SimulateUserOperationResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_SimulateUserOperationResponse)(nil) +} +func (x fastReflection_SimulateUserOperationResponse_messageType) New() protoreflect.Message { + return new(fastReflection_SimulateUserOperationResponse) +} +func (x fastReflection_SimulateUserOperationResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SimulateUserOperationResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SimulateUserOperationResponse) Descriptor() protoreflect.MessageDescriptor { + return md_SimulateUserOperationResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SimulateUserOperationResponse) Type() protoreflect.MessageType { + return _fastReflection_SimulateUserOperationResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SimulateUserOperationResponse) New() protoreflect.Message { + return new(fastReflection_SimulateUserOperationResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SimulateUserOperationResponse) Interface() protoreflect.ProtoMessage { + return (*SimulateUserOperationResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SimulateUserOperationResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.UserOperationResponse != nil { + value := protoreflect.ValueOfMessage(x.UserOperationResponse.ProtoReflect()) + if !f(fd_SimulateUserOperationResponse_user_operation_response, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SimulateUserOperationResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + return x.UserOperationResponse != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + x.UserOperationResponse = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SimulateUserOperationResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + value := x.UserOperationResponse + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + x.UserOperationResponse = value.Message().Interface().(*UserOperationResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + if x.UserOperationResponse == nil { + x.UserOperationResponse = new(UserOperationResponse) + } + return protoreflect.ValueOfMessage(x.UserOperationResponse.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SimulateUserOperationResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response": + m := new(UserOperationResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.SimulateUserOperationResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.SimulateUserOperationResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SimulateUserOperationResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.SimulateUserOperationResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SimulateUserOperationResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SimulateUserOperationResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SimulateUserOperationResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SimulateUserOperationResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SimulateUserOperationResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.UserOperationResponse != nil { + l = options.Size(x.UserOperationResponse) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SimulateUserOperationResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.UserOperationResponse != nil { + encoded, err := options.Marshal(x.UserOperationResponse) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SimulateUserOperationResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SimulateUserOperationResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SimulateUserOperationResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field UserOperationResponse", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.UserOperationResponse == nil { + x.UserOperationResponse = &UserOperationResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.UserOperationResponse); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: cosmos/accounts/v1/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// AccountQueryRequest is the request type for the Query/AccountQuery RPC +type AccountQueryRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // target defines the account to be queried. + Target string `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"` + // request defines the query message being sent to the account. + Request *anypb.Any `protobuf:"bytes,2,opt,name=request,proto3" json:"request,omitempty"` +} + +func (x *AccountQueryRequest) Reset() { + *x = AccountQueryRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AccountQueryRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AccountQueryRequest) ProtoMessage() {} + +// Deprecated: Use AccountQueryRequest.ProtoReflect.Descriptor instead. +func (*AccountQueryRequest) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{0} +} + +func (x *AccountQueryRequest) GetTarget() string { + if x != nil { + return x.Target + } + return "" +} + +func (x *AccountQueryRequest) GetRequest() *anypb.Any { + if x != nil { + return x.Request + } + return nil +} + +// AccountQueryResponse is the response type for the Query/AccountQuery RPC method. +type AccountQueryResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // response defines the query response of the account. + Response *anypb.Any `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` +} + +func (x *AccountQueryResponse) Reset() { + *x = AccountQueryResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AccountQueryResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AccountQueryResponse) ProtoMessage() {} + +// Deprecated: Use AccountQueryResponse.ProtoReflect.Descriptor instead. +func (*AccountQueryResponse) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{1} +} + +func (x *AccountQueryResponse) GetResponse() *anypb.Any { + if x != nil { + return x.Response + } + return nil +} + +// SchemaResponse is the response type for the Query/Schema RPC method. +type SchemaRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // account_type defines the account type to query the schema for. + AccountType string `protobuf:"bytes,1,opt,name=account_type,json=accountType,proto3" json:"account_type,omitempty"` +} + +func (x *SchemaRequest) Reset() { + *x = SchemaRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SchemaRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SchemaRequest) ProtoMessage() {} + +// Deprecated: Use SchemaRequest.ProtoReflect.Descriptor instead. +func (*SchemaRequest) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{2} +} + +func (x *SchemaRequest) GetAccountType() string { + if x != nil { + return x.AccountType + } + return "" +} + +// SchemaResponse is the response type for the Query/Schema RPC method. +type SchemaResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // init_schema defines the schema descriptor for the Init account method. + InitSchema *SchemaResponse_Handler `protobuf:"bytes,1,opt,name=init_schema,json=initSchema,proto3" json:"init_schema,omitempty"` + // execute_handlers defines the schema descriptor for the Execute account method. + ExecuteHandlers []*SchemaResponse_Handler `protobuf:"bytes,2,rep,name=execute_handlers,json=executeHandlers,proto3" json:"execute_handlers,omitempty"` + // query_handlers defines the schema descriptor for the Query account method. + QueryHandlers []*SchemaResponse_Handler `protobuf:"bytes,3,rep,name=query_handlers,json=queryHandlers,proto3" json:"query_handlers,omitempty"` +} + +func (x *SchemaResponse) Reset() { + *x = SchemaResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SchemaResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SchemaResponse) ProtoMessage() {} + +// Deprecated: Use SchemaResponse.ProtoReflect.Descriptor instead. +func (*SchemaResponse) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{3} +} + +func (x *SchemaResponse) GetInitSchema() *SchemaResponse_Handler { + if x != nil { + return x.InitSchema + } + return nil } func (x *SchemaResponse) GetExecuteHandlers() []*SchemaResponse_Handler { @@ -3664,6 +4598,92 @@ func (x *AccountTypeResponse) GetAccountType() string { return "" } +// SimulateUserOperationRequest is the query request used to simulate a +// UserOperation. +type SimulateUserOperationRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // bundler can be filled to simulate the address of the bundler. + Bundler string `protobuf:"bytes,1,opt,name=bundler,proto3" json:"bundler,omitempty"` + // user_operation defines the user operation that we want to simulate. + // Gas limit fields are ignored. + UserOperation *UserOperation `protobuf:"bytes,2,opt,name=user_operation,json=userOperation,proto3" json:"user_operation,omitempty"` +} + +func (x *SimulateUserOperationRequest) Reset() { + *x = SimulateUserOperationRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SimulateUserOperationRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SimulateUserOperationRequest) ProtoMessage() {} + +// Deprecated: Use SimulateUserOperationRequest.ProtoReflect.Descriptor instead. +func (*SimulateUserOperationRequest) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{6} +} + +func (x *SimulateUserOperationRequest) GetBundler() string { + if x != nil { + return x.Bundler + } + return "" +} + +func (x *SimulateUserOperationRequest) GetUserOperation() *UserOperation { + if x != nil { + return x.UserOperation + } + return nil +} + +// SimulateUserOperationResponse is the query response returned by the simulation. +// It will populate the gas limits fields. +type SimulateUserOperationResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // UserOperationResponse is the response of the simulation. + UserOperationResponse *UserOperationResponse `protobuf:"bytes,1,opt,name=user_operation_response,json=userOperationResponse,proto3" json:"user_operation_response,omitempty"` +} + +func (x *SimulateUserOperationResponse) Reset() { + *x = SimulateUserOperationResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SimulateUserOperationResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SimulateUserOperationResponse) ProtoMessage() {} + +// Deprecated: Use SimulateUserOperationResponse.ProtoReflect.Descriptor instead. +func (*SimulateUserOperationResponse) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{7} +} + +func (x *SimulateUserOperationResponse) GetUserOperationResponse() *UserOperationResponse { + if x != nil { + return x.UserOperationResponse + } + return nil +} + // Handler defines a schema descriptor for a handler. // Where request and response are names that can be used to lookup the // reflection descriptor. @@ -3681,7 +4701,7 @@ type SchemaResponse_Handler struct { func (x *SchemaResponse_Handler) Reset() { *x = SchemaResponse_Handler{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3719,79 +4739,107 @@ var file_cosmos_accounts_v1_query_proto_rawDesc = []byte{ 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, - 0x5d, 0x0a, 0x13, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x12, 0x2e, - 0x0a, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x48, - 0x0a, 0x14, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x30, 0x0a, 0x08, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, - 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x32, 0x0a, 0x0d, 0x53, 0x63, 0x68, 0x65, - 0x6d, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x61, 0x63, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x22, 0xc8, 0x02, 0x0a, - 0x0e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x4b, 0x0a, 0x0b, 0x69, 0x6e, 0x69, 0x74, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x2c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x62, 0x73, 0x74, + 0x72, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x5d, 0x0a, + 0x13, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x12, 0x2e, 0x0a, 0x07, + 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x41, 0x6e, 0x79, 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x48, 0x0a, 0x14, + 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x30, 0x0a, 0x08, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, 0x72, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x32, 0x0a, 0x0d, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x22, 0xc8, 0x02, 0x0a, 0x0e, 0x53, + 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4b, 0x0a, + 0x0b, 0x69, 0x6e, 0x69, 0x74, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x52, 0x0a, + 0x69, 0x6e, 0x69, 0x74, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x55, 0x0a, 0x10, 0x65, 0x78, + 0x65, 0x63, 0x75, 0x74, 0x65, 0x5f, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x73, 0x18, 0x02, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x52, 0x0a, 0x69, 0x6e, 0x69, 0x74, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x55, 0x0a, 0x10, - 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x5f, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x73, - 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, - 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x52, 0x0f, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x48, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x73, 0x12, 0x51, 0x0a, 0x0e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, - 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, - 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x52, 0x0d, 0x71, 0x75, 0x65, 0x72, 0x79, 0x48, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x73, 0x1a, 0x3f, 0x0a, 0x07, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x72, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x0a, 0x12, 0x41, 0x63, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, - 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x38, 0x0a, 0x13, 0x41, 0x63, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x21, - 0x0a, 0x0c, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, - 0x65, 0x32, 0xa1, 0x02, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x63, 0x0a, 0x0c, 0x41, - 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x27, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, - 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, - 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, - 0x12, 0x51, 0x0a, 0x06, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x21, 0x2e, 0x63, 0x6f, 0x73, + 0x52, 0x0f, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, + 0x73, 0x12, 0x51, 0x0a, 0x0e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x68, 0x61, 0x6e, 0x64, 0x6c, + 0x65, 0x72, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, + 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x61, + 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x52, 0x0d, 0x71, 0x75, 0x65, 0x72, 0x79, 0x48, 0x61, 0x6e, 0x64, + 0x6c, 0x65, 0x72, 0x73, 0x1a, 0x3f, 0x0a, 0x07, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x12, + 0x18, 0x0a, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x0a, 0x12, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x38, 0x0a, 0x13, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x21, 0x0a, 0x0c, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x22, + 0x82, 0x01, 0x0a, 0x1c, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, + 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x18, 0x0a, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x12, 0x48, 0x0a, 0x0e, 0x75, 0x73, + 0x65, 0x72, 0x5f, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0d, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x82, 0x01, 0x0a, 0x1d, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, + 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x61, 0x0a, 0x17, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x6f, + 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x73, 0x65, + 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x52, 0x15, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0xa1, 0x03, 0x0a, 0x05, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x12, 0x63, 0x0a, 0x0c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, + 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x06, 0x53, 0x63, 0x68, 0x65, + 0x6d, 0x61, 0x12, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, + 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0b, 0x41, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, - 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, - 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0b, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, + 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, - 0x79, 0x70, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, - 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0xbe, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, - 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, - 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, - 0x2f, 0x76, 0x31, 0x3b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x76, 0x31, 0xa2, 0x02, - 0x03, 0x43, 0x41, 0x58, 0xaa, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, - 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, - 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, - 0x02, 0x14, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, - 0x74, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, + 0x15, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x30, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x6d, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, + 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0xbe, 0x01, + 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x41, 0x58, 0xaa, 0x02, 0x12, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56, + 0x31, 0xca, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, + 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x14, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x3a, 0x3a, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3806,34 +4854,42 @@ func file_cosmos_accounts_v1_query_proto_rawDescGZIP() []byte { return file_cosmos_accounts_v1_query_proto_rawDescData } -var file_cosmos_accounts_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 7) +var file_cosmos_accounts_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 9) var file_cosmos_accounts_v1_query_proto_goTypes = []interface{}{ - (*AccountQueryRequest)(nil), // 0: cosmos.accounts.v1.AccountQueryRequest - (*AccountQueryResponse)(nil), // 1: cosmos.accounts.v1.AccountQueryResponse - (*SchemaRequest)(nil), // 2: cosmos.accounts.v1.SchemaRequest - (*SchemaResponse)(nil), // 3: cosmos.accounts.v1.SchemaResponse - (*AccountTypeRequest)(nil), // 4: cosmos.accounts.v1.AccountTypeRequest - (*AccountTypeResponse)(nil), // 5: cosmos.accounts.v1.AccountTypeResponse - (*SchemaResponse_Handler)(nil), // 6: cosmos.accounts.v1.SchemaResponse.Handler - (*anypb.Any)(nil), // 7: google.protobuf.Any + (*AccountQueryRequest)(nil), // 0: cosmos.accounts.v1.AccountQueryRequest + (*AccountQueryResponse)(nil), // 1: cosmos.accounts.v1.AccountQueryResponse + (*SchemaRequest)(nil), // 2: cosmos.accounts.v1.SchemaRequest + (*SchemaResponse)(nil), // 3: cosmos.accounts.v1.SchemaResponse + (*AccountTypeRequest)(nil), // 4: cosmos.accounts.v1.AccountTypeRequest + (*AccountTypeResponse)(nil), // 5: cosmos.accounts.v1.AccountTypeResponse + (*SimulateUserOperationRequest)(nil), // 6: cosmos.accounts.v1.SimulateUserOperationRequest + (*SimulateUserOperationResponse)(nil), // 7: cosmos.accounts.v1.SimulateUserOperationResponse + (*SchemaResponse_Handler)(nil), // 8: cosmos.accounts.v1.SchemaResponse.Handler + (*anypb.Any)(nil), // 9: google.protobuf.Any + (*UserOperation)(nil), // 10: cosmos.accounts.v1.UserOperation + (*UserOperationResponse)(nil), // 11: cosmos.accounts.v1.UserOperationResponse } var file_cosmos_accounts_v1_query_proto_depIdxs = []int32{ - 7, // 0: cosmos.accounts.v1.AccountQueryRequest.request:type_name -> google.protobuf.Any - 7, // 1: cosmos.accounts.v1.AccountQueryResponse.response:type_name -> google.protobuf.Any - 6, // 2: cosmos.accounts.v1.SchemaResponse.init_schema:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 6, // 3: cosmos.accounts.v1.SchemaResponse.execute_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 6, // 4: cosmos.accounts.v1.SchemaResponse.query_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 0, // 5: cosmos.accounts.v1.Query.AccountQuery:input_type -> cosmos.accounts.v1.AccountQueryRequest - 2, // 6: cosmos.accounts.v1.Query.Schema:input_type -> cosmos.accounts.v1.SchemaRequest - 4, // 7: cosmos.accounts.v1.Query.AccountType:input_type -> cosmos.accounts.v1.AccountTypeRequest - 1, // 8: cosmos.accounts.v1.Query.AccountQuery:output_type -> cosmos.accounts.v1.AccountQueryResponse - 3, // 9: cosmos.accounts.v1.Query.Schema:output_type -> cosmos.accounts.v1.SchemaResponse - 5, // 10: cosmos.accounts.v1.Query.AccountType:output_type -> cosmos.accounts.v1.AccountTypeResponse - 8, // [8:11] is the sub-list for method output_type - 5, // [5:8] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name + 9, // 0: cosmos.accounts.v1.AccountQueryRequest.request:type_name -> google.protobuf.Any + 9, // 1: cosmos.accounts.v1.AccountQueryResponse.response:type_name -> google.protobuf.Any + 8, // 2: cosmos.accounts.v1.SchemaResponse.init_schema:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 8, // 3: cosmos.accounts.v1.SchemaResponse.execute_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 8, // 4: cosmos.accounts.v1.SchemaResponse.query_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 10, // 5: cosmos.accounts.v1.SimulateUserOperationRequest.user_operation:type_name -> cosmos.accounts.v1.UserOperation + 11, // 6: cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response:type_name -> cosmos.accounts.v1.UserOperationResponse + 0, // 7: cosmos.accounts.v1.Query.AccountQuery:input_type -> cosmos.accounts.v1.AccountQueryRequest + 2, // 8: cosmos.accounts.v1.Query.Schema:input_type -> cosmos.accounts.v1.SchemaRequest + 4, // 9: cosmos.accounts.v1.Query.AccountType:input_type -> cosmos.accounts.v1.AccountTypeRequest + 6, // 10: cosmos.accounts.v1.Query.SimulateUserOperation:input_type -> cosmos.accounts.v1.SimulateUserOperationRequest + 1, // 11: cosmos.accounts.v1.Query.AccountQuery:output_type -> cosmos.accounts.v1.AccountQueryResponse + 3, // 12: cosmos.accounts.v1.Query.Schema:output_type -> cosmos.accounts.v1.SchemaResponse + 5, // 13: cosmos.accounts.v1.Query.AccountType:output_type -> cosmos.accounts.v1.AccountTypeResponse + 7, // 14: cosmos.accounts.v1.Query.SimulateUserOperation:output_type -> cosmos.accounts.v1.SimulateUserOperationResponse + 11, // [11:15] is the sub-list for method output_type + 7, // [7:11] is the sub-list for method input_type + 7, // [7:7] is the sub-list for extension type_name + 7, // [7:7] is the sub-list for extension extendee + 0, // [0:7] is the sub-list for field type_name } func init() { file_cosmos_accounts_v1_query_proto_init() } @@ -3841,6 +4897,7 @@ func file_cosmos_accounts_v1_query_proto_init() { if File_cosmos_accounts_v1_query_proto != nil { return } + file_cosmos_accounts_v1_account_abstraction_proto_init() if !protoimpl.UnsafeEnabled { file_cosmos_accounts_v1_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*AccountQueryRequest); i { @@ -3915,6 +4972,30 @@ func file_cosmos_accounts_v1_query_proto_init() { } } file_cosmos_accounts_v1_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SimulateUserOperationRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_accounts_v1_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SimulateUserOperationResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_accounts_v1_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*SchemaResponse_Handler); i { case 0: return &v.state @@ -3933,7 +5014,7 @@ func file_cosmos_accounts_v1_query_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_accounts_v1_query_proto_rawDesc, NumEnums: 0, - NumMessages: 7, + NumMessages: 9, NumExtensions: 0, NumServices: 1, }, diff --git a/api/cosmos/accounts/v1/query_grpc.pb.go b/api/cosmos/accounts/v1/query_grpc.pb.go index e4cec71717ed..7e1b2d97e814 100644 --- a/api/cosmos/accounts/v1/query_grpc.pb.go +++ b/api/cosmos/accounts/v1/query_grpc.pb.go @@ -19,9 +19,10 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - Query_AccountQuery_FullMethodName = "/cosmos.accounts.v1.Query/AccountQuery" - Query_Schema_FullMethodName = "/cosmos.accounts.v1.Query/Schema" - Query_AccountType_FullMethodName = "/cosmos.accounts.v1.Query/AccountType" + Query_AccountQuery_FullMethodName = "/cosmos.accounts.v1.Query/AccountQuery" + Query_Schema_FullMethodName = "/cosmos.accounts.v1.Query/Schema" + Query_AccountType_FullMethodName = "/cosmos.accounts.v1.Query/AccountType" + Query_SimulateUserOperation_FullMethodName = "/cosmos.accounts.v1.Query/SimulateUserOperation" ) // QueryClient is the client API for Query service. @@ -34,6 +35,8 @@ type QueryClient interface { Schema(ctx context.Context, in *SchemaRequest, opts ...grpc.CallOption) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(ctx context.Context, in *AccountTypeRequest, opts ...grpc.CallOption) (*AccountTypeResponse, error) + // SimulateUserOperation simulates a user operation. + SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) } type queryClient struct { @@ -71,6 +74,15 @@ func (c *queryClient) AccountType(ctx context.Context, in *AccountTypeRequest, o return out, nil } +func (c *queryClient) SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) { + out := new(SimulateUserOperationResponse) + err := c.cc.Invoke(ctx, Query_SimulateUserOperation_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // QueryServer is the server API for Query service. // All implementations must embed UnimplementedQueryServer // for forward compatibility @@ -81,6 +93,8 @@ type QueryServer interface { Schema(context.Context, *SchemaRequest) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) + // SimulateUserOperation simulates a user operation. + SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) mustEmbedUnimplementedQueryServer() } @@ -97,6 +111,9 @@ func (UnimplementedQueryServer) Schema(context.Context, *SchemaRequest) (*Schema func (UnimplementedQueryServer) AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method AccountType not implemented") } +func (UnimplementedQueryServer) SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SimulateUserOperation not implemented") +} func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} // UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. @@ -164,6 +181,24 @@ func _Query_AccountType_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_SimulateUserOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SimulateUserOperationRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).SimulateUserOperation(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_SimulateUserOperation_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).SimulateUserOperation(ctx, req.(*SimulateUserOperationRequest)) + } + return interceptor(ctx, in, info, handler) +} + // Query_ServiceDesc is the grpc.ServiceDesc for Query service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -183,6 +218,10 @@ var Query_ServiceDesc = grpc.ServiceDesc{ MethodName: "AccountType", Handler: _Query_AccountType_Handler, }, + { + MethodName: "SimulateUserOperation", + Handler: _Query_SimulateUserOperation_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "cosmos/accounts/v1/query.proto", diff --git a/proto/cosmos/accounts/v1/query.proto b/proto/cosmos/accounts/v1/query.proto index d2b5d55ccfae..7e779d130870 100644 --- a/proto/cosmos/accounts/v1/query.proto +++ b/proto/cosmos/accounts/v1/query.proto @@ -5,6 +5,7 @@ package cosmos.accounts.v1; option go_package = "cosmossdk.io/x/accounts/v1"; import "google/protobuf/any.proto"; +import "cosmos/accounts/v1/account_abstraction.proto"; // Query defines the Query service for the x/accounts module. service Query { @@ -14,6 +15,8 @@ service Query { rpc Schema(SchemaRequest) returns (SchemaResponse) {}; // AccountType returns the account type for an address. rpc AccountType(AccountTypeRequest) returns (AccountTypeResponse) {}; + // SimulateUserOperation simulates a user operation. + rpc SimulateUserOperation(SimulateUserOperationRequest) returns (SimulateUserOperationResponse) {}; } // AccountQueryRequest is the request type for the Query/AccountQuery RPC @@ -66,3 +69,20 @@ message AccountTypeResponse { // account_type defines the account type for the address. string account_type = 1; } + +// SimulateUserOperationRequest is the query request used to simulate a +// UserOperation. +message SimulateUserOperationRequest { + // bundler can be filled to simulate the address of the bundler. + string bundler = 1; + // user_operation defines the user operation that we want to simulate. + // Gas limit fields are ignored. + UserOperation user_operation = 2; +} + +// SimulateUserOperationResponse is the query response returned by the simulation. +// It will populate the gas limits fields. +message SimulateUserOperationResponse { + // UserOperationResponse is the response of the simulation. + UserOperationResponse user_operation_response = 1; +} \ No newline at end of file diff --git a/tests/e2e/accounts/account_abstraction_test.go b/tests/e2e/accounts/account_abstraction_test.go index 5ddf5043ad61..7a04c91305f8 100644 --- a/tests/e2e/accounts/account_abstraction_test.go +++ b/tests/e2e/accounts/account_abstraction_test.go @@ -327,6 +327,47 @@ func TestAccountAbstraction(t *testing.T) { }) require.Empty(t, resp.Error) // no error }) + + t.Run("Simulate - OK", func(t *testing.T) { + queryServer := accounts.NewQueryServer(ak) + + // gas in unspecified + op := &accountsv1.UserOperation{ + Sender: aaAddrStr, + AuthenticationMethod: "secp256k1", + AuthenticationData: mockSignature, + BundlerPaymentMessages: intoAny(t, &banktypes.MsgSend{ + FromAddress: aaAddrStr, + ToAddress: bundlerAddrStr, + Amount: coins(t, "1stake"), + }), + ExecutionMessages: intoAny(t, &banktypes.MsgSend{ + FromAddress: aaAddrStr, + ToAddress: aliceAddrStr, + Amount: coins(t, "2000stake"), + }), + } + queryResp, err := queryServer.SimulateUserOperation(ctx, &accountsv1.SimulateUserOperationRequest{ + Bundler: bundlerAddrStr, + UserOperation: op, + }) + require.NoError(t, err) + + resp := queryResp.UserOperationResponse + require.Empty(t, resp.Error) // no error + require.Len(t, resp.BundlerPaymentResponses, 1) + require.Len(t, resp.ExecutionResponses, 1) + // assess gas is filled + require.NotZero(t, resp.ExecutionGasUsed) + require.NotZero(t, resp.BundlerPaymentGasUsed) + require.NotZero(t, resp.AuthenticationGasUsed) + }) + + t.Run("Simulate - Fail empty user operation", func(t *testing.T) { + queryServer := accounts.NewQueryServer(ak) + _, err := queryServer.SimulateUserOperation(ctx, &accountsv1.SimulateUserOperationRequest{}) + require.Error(t, err) + }) } func intoAny(t *testing.T, msgs ...gogoproto.Message) (anys []*codectypes.Any) { diff --git a/x/accounts/query_server.go b/x/accounts/query_server.go index cd5930fa808a..8f0ea2e79b2e 100644 --- a/x/accounts/query_server.go +++ b/x/accounts/query_server.go @@ -71,3 +71,27 @@ func (q queryServer) AccountType(ctx context.Context, request *v1.AccountTypeReq AccountType: accType, }, nil } + +const ( + SimulateAuthenticateGasLimit = 1_000_000 + SimulateBundlerPaymentGasLimit = SimulateAuthenticateGasLimit + ExecuteGasLimit = SimulateAuthenticateGasLimit +) + +func (q queryServer) SimulateUserOperation(ctx context.Context, request *v1.SimulateUserOperationRequest) (*v1.SimulateUserOperationResponse, error) { + _, err := q.k.addressCodec.StringToBytes(request.Bundler) + if err != nil { + return nil, err + } + + if request.UserOperation == nil { + return nil, fmt.Errorf("nil user operation") + } + + request.UserOperation.AuthenticationGasLimit = SimulateAuthenticateGasLimit + request.UserOperation.BundlerPaymentGasLimit = SimulateBundlerPaymentGasLimit + request.UserOperation.ExecutionGasLimit = ExecuteGasLimit + + resp := q.k.ExecuteUserOperation(ctx, request.Bundler, request.UserOperation) + return &v1.SimulateUserOperationResponse{UserOperationResponse: resp}, nil +} diff --git a/x/accounts/v1/query.pb.go b/x/accounts/v1/query.pb.go index 5e65ffc45f9a..70aa10ff7a4f 100644 --- a/x/accounts/v1/query.pb.go +++ b/x/accounts/v1/query.pb.go @@ -388,6 +388,110 @@ func (m *AccountTypeResponse) GetAccountType() string { return "" } +// SimulateUserOperationRequest is the query request used to simulate a +// UserOperation. +type SimulateUserOperationRequest struct { + // bundler can be filled to simulate the address of the bundler. + Bundler string `protobuf:"bytes,1,opt,name=bundler,proto3" json:"bundler,omitempty"` + // user_operation defines the user operation that we want to simulate. + // Gas limit fields are ignored. + UserOperation *UserOperation `protobuf:"bytes,2,opt,name=user_operation,json=userOperation,proto3" json:"user_operation,omitempty"` +} + +func (m *SimulateUserOperationRequest) Reset() { *m = SimulateUserOperationRequest{} } +func (m *SimulateUserOperationRequest) String() string { return proto.CompactTextString(m) } +func (*SimulateUserOperationRequest) ProtoMessage() {} +func (*SimulateUserOperationRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_16ad14c22e3080d2, []int{6} +} +func (m *SimulateUserOperationRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SimulateUserOperationRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SimulateUserOperationRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SimulateUserOperationRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SimulateUserOperationRequest.Merge(m, src) +} +func (m *SimulateUserOperationRequest) XXX_Size() int { + return m.Size() +} +func (m *SimulateUserOperationRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SimulateUserOperationRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SimulateUserOperationRequest proto.InternalMessageInfo + +func (m *SimulateUserOperationRequest) GetBundler() string { + if m != nil { + return m.Bundler + } + return "" +} + +func (m *SimulateUserOperationRequest) GetUserOperation() *UserOperation { + if m != nil { + return m.UserOperation + } + return nil +} + +// SimulateUserOperationResponse is the query response returned by the simulation. +// It will populate the gas limits fields. +type SimulateUserOperationResponse struct { + // UserOperationResponse is the response of the simulation. + UserOperationResponse *UserOperationResponse `protobuf:"bytes,1,opt,name=user_operation_response,json=userOperationResponse,proto3" json:"user_operation_response,omitempty"` +} + +func (m *SimulateUserOperationResponse) Reset() { *m = SimulateUserOperationResponse{} } +func (m *SimulateUserOperationResponse) String() string { return proto.CompactTextString(m) } +func (*SimulateUserOperationResponse) ProtoMessage() {} +func (*SimulateUserOperationResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_16ad14c22e3080d2, []int{7} +} +func (m *SimulateUserOperationResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SimulateUserOperationResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SimulateUserOperationResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SimulateUserOperationResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SimulateUserOperationResponse.Merge(m, src) +} +func (m *SimulateUserOperationResponse) XXX_Size() int { + return m.Size() +} +func (m *SimulateUserOperationResponse) XXX_DiscardUnknown() { + xxx_messageInfo_SimulateUserOperationResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_SimulateUserOperationResponse proto.InternalMessageInfo + +func (m *SimulateUserOperationResponse) GetUserOperationResponse() *UserOperationResponse { + if m != nil { + return m.UserOperationResponse + } + return nil +} + func init() { proto.RegisterType((*AccountQueryRequest)(nil), "cosmos.accounts.v1.AccountQueryRequest") proto.RegisterType((*AccountQueryResponse)(nil), "cosmos.accounts.v1.AccountQueryResponse") @@ -396,41 +500,50 @@ func init() { proto.RegisterType((*SchemaResponse_Handler)(nil), "cosmos.accounts.v1.SchemaResponse.Handler") proto.RegisterType((*AccountTypeRequest)(nil), "cosmos.accounts.v1.AccountTypeRequest") proto.RegisterType((*AccountTypeResponse)(nil), "cosmos.accounts.v1.AccountTypeResponse") + proto.RegisterType((*SimulateUserOperationRequest)(nil), "cosmos.accounts.v1.SimulateUserOperationRequest") + proto.RegisterType((*SimulateUserOperationResponse)(nil), "cosmos.accounts.v1.SimulateUserOperationResponse") } func init() { proto.RegisterFile("cosmos/accounts/v1/query.proto", fileDescriptor_16ad14c22e3080d2) } var fileDescriptor_16ad14c22e3080d2 = []byte{ - // 453 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0xbf, 0x8e, 0xd3, 0x40, - 0x10, 0xc6, 0x6d, 0x9f, 0x48, 0x60, 0x7c, 0x77, 0xa0, 0xe5, 0x84, 0x8c, 0x0b, 0x2b, 0xe7, 0x82, - 0x8b, 0x28, 0xd6, 0x5c, 0xa0, 0xa0, 0x43, 0xa1, 0x3a, 0x89, 0x2a, 0x06, 0x1a, 0x24, 0x14, 0x7c, - 0xf6, 0x92, 0x8b, 0xb8, 0x78, 0x1d, 0xef, 0x3a, 0x8a, 0xdf, 0x82, 0x57, 0xe0, 0x6d, 0x52, 0xa6, - 0xa4, 0x44, 0xc9, 0x8b, 0xa0, 0xec, 0x9f, 0xd8, 0x11, 0x21, 0x56, 0x3a, 0xcf, 0xce, 0xb7, 0xbf, - 0xd9, 0x99, 0x6f, 0x12, 0xf0, 0x62, 0xca, 0x26, 0x94, 0x05, 0x51, 0x1c, 0xd3, 0x22, 0xe5, 0x2c, - 0x98, 0x5d, 0x07, 0xd3, 0x82, 0xe4, 0x25, 0xce, 0x72, 0xca, 0x29, 0x42, 0x32, 0x8f, 0x75, 0x1e, - 0xcf, 0xae, 0xdd, 0xe7, 0x23, 0x4a, 0x47, 0xf7, 0x24, 0x10, 0x8a, 0xdb, 0xe2, 0x7b, 0x10, 0xa5, - 0x4a, 0xee, 0x7f, 0x85, 0xa7, 0x7d, 0xa9, 0x1c, 0x6c, 0x20, 0x21, 0x99, 0x16, 0x84, 0x71, 0xf4, - 0x0c, 0x5a, 0x3c, 0xca, 0x47, 0x84, 0x3b, 0x66, 0xc7, 0xec, 0x3e, 0x0a, 0x55, 0x84, 0x30, 0xb4, - 0x73, 0x29, 0x71, 0xac, 0x8e, 0xd9, 0xb5, 0x7b, 0x17, 0x58, 0xb2, 0xb1, 0x66, 0xe3, 0x7e, 0x5a, - 0x86, 0x5a, 0xe4, 0xdf, 0xc0, 0xc5, 0x2e, 0x9e, 0x65, 0x34, 0x65, 0x04, 0xbd, 0x82, 0x87, 0xb9, - 0xfa, 0x16, 0x15, 0xfe, 0x07, 0xda, 0xaa, 0xfc, 0x1e, 0x9c, 0x7d, 0x8c, 0xef, 0xc8, 0x24, 0xd2, - 0x4f, 0xbc, 0x84, 0x53, 0xd5, 0xe3, 0x90, 0x97, 0x19, 0x51, 0x0f, 0xb5, 0xd5, 0xd9, 0xa7, 0x32, - 0x23, 0xfe, 0xc2, 0x82, 0x73, 0x7d, 0x49, 0x15, 0xfe, 0x00, 0xf6, 0x38, 0x1d, 0xf3, 0x21, 0x13, - 0xc7, 0xaa, 0xf6, 0x4b, 0xfc, 0xef, 0xd0, 0xf0, 0xee, 0x45, 0x7c, 0x13, 0xa5, 0xc9, 0x3d, 0xc9, - 0x43, 0xd8, 0x5c, 0x97, 0x39, 0xf4, 0x19, 0x9e, 0x90, 0x39, 0x89, 0x0b, 0x4e, 0x86, 0x77, 0x32, - 0xcd, 0x1c, 0xab, 0x73, 0x72, 0x24, 0xf1, 0xb1, 0x62, 0xa8, 0x98, 0xa1, 0x01, 0x9c, 0x0b, 0x47, - 0x2b, 0xe8, 0xc9, 0xd1, 0xd0, 0x33, 0x41, 0xd0, 0x48, 0xf7, 0x1d, 0xb4, 0xd5, 0x37, 0x72, 0x2a, - 0x0b, 0xe5, 0xc8, 0x74, 0x88, 0xdc, 0x9a, 0x29, 0x96, 0x48, 0x55, 0xe3, 0xc7, 0x80, 0xfa, 0xd5, - 0x64, 0xb5, 0x07, 0x0e, 0xb4, 0xa3, 0x24, 0xc9, 0x09, 0x63, 0x9a, 0xa5, 0x42, 0xff, 0xed, 0x76, - 0xaf, 0xa4, 0x5e, 0x8d, 0xbf, 0xd9, 0xb4, 0xde, 0x2f, 0x0b, 0x1e, 0x88, 0x65, 0x41, 0x31, 0x9c, - 0xd6, 0x97, 0x07, 0x5d, 0xed, 0xeb, 0x7f, 0xcf, 0xf6, 0xba, 0xdd, 0x66, 0xa1, 0x6a, 0xcb, 0x40, - 0x03, 0x68, 0x29, 0x37, 0x2f, 0x0f, 0x8d, 0x57, 0x82, 0xfd, 0x66, 0x07, 0x7c, 0x03, 0x7d, 0x03, - 0xbb, 0xd6, 0x3b, 0x7a, 0x71, 0xe0, 0x35, 0xb5, 0x61, 0xba, 0x57, 0x8d, 0x3a, 0x5d, 0xe1, 0xfd, - 0x9b, 0xc5, 0xca, 0x33, 0x97, 0x2b, 0xcf, 0xfc, 0xb3, 0xf2, 0xcc, 0x9f, 0x6b, 0xcf, 0x58, 0xae, - 0x3d, 0xe3, 0xf7, 0xda, 0x33, 0xbe, 0xb8, 0x92, 0xc1, 0x92, 0x1f, 0x78, 0x4c, 0x83, 0x79, 0xfd, - 0x6f, 0xe2, 0xb6, 0x25, 0x7e, 0x5a, 0xaf, 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0x95, 0x18, 0x10, - 0x13, 0x43, 0x04, 0x00, 0x00, + // 563 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0xcd, 0x8e, 0x12, 0x41, + 0x10, 0x66, 0xd8, 0x08, 0x5a, 0x2c, 0x68, 0xda, 0x5d, 0xc5, 0x89, 0x4e, 0x60, 0x0e, 0x2e, 0x1a, + 0xd3, 0xb3, 0xa0, 0x07, 0x6f, 0x06, 0x4f, 0x24, 0x1e, 0x0c, 0xac, 0x7b, 0x31, 0x31, 0xd8, 0x0c, + 0x2d, 0x4b, 0x84, 0x69, 0xb6, 0x7f, 0x36, 0xcb, 0xc5, 0x83, 0x4f, 0xe0, 0x2b, 0xf8, 0x36, 0x7b, + 0xdc, 0xa3, 0x47, 0x03, 0x2f, 0x62, 0x98, 0xee, 0x86, 0x41, 0x67, 0x41, 0x6e, 0x53, 0x5d, 0x5f, + 0x7d, 0x5f, 0x75, 0xd5, 0xd7, 0x03, 0x5e, 0xc8, 0xc4, 0x98, 0x89, 0x80, 0x84, 0x21, 0x53, 0x91, + 0x14, 0xc1, 0x45, 0x3d, 0x38, 0x57, 0x94, 0x4f, 0xf1, 0x84, 0x33, 0xc9, 0x10, 0xd2, 0x79, 0x6c, + 0xf3, 0xf8, 0xa2, 0xee, 0x3e, 0x1a, 0x30, 0x36, 0x18, 0xd1, 0x20, 0x46, 0xf4, 0xd4, 0x97, 0x80, + 0x44, 0x06, 0xee, 0xbe, 0x48, 0xa1, 0x33, 0xdf, 0x5d, 0xd2, 0x13, 0x92, 0x93, 0x50, 0x0e, 0x59, + 0xa4, 0xd1, 0xfe, 0x27, 0xb8, 0xdf, 0xd4, 0xc9, 0xf6, 0x42, 0xb2, 0x43, 0xcf, 0x15, 0x15, 0x12, + 0x3d, 0x80, 0x9c, 0x24, 0x7c, 0x40, 0x65, 0xd9, 0xa9, 0x38, 0xb5, 0x3b, 0x1d, 0x13, 0x21, 0x0c, + 0x79, 0xae, 0x21, 0xe5, 0x6c, 0xc5, 0xa9, 0x15, 0x1a, 0x07, 0x58, 0x77, 0x82, 0x6d, 0x27, 0xb8, + 0x19, 0x4d, 0x3b, 0x16, 0xe4, 0xb7, 0xe0, 0x60, 0x9d, 0x5e, 0x4c, 0x58, 0x24, 0x28, 0x3a, 0x86, + 0xdb, 0xdc, 0x7c, 0xc7, 0x0a, 0x37, 0x11, 0x2d, 0x51, 0x7e, 0x03, 0x8a, 0x27, 0xe1, 0x19, 0x1d, + 0x13, 0xdb, 0x62, 0x15, 0xf6, 0xed, 0xb5, 0xe4, 0x74, 0x42, 0x4d, 0xa3, 0x05, 0x73, 0xf6, 0x61, + 0x3a, 0xa1, 0xfe, 0x55, 0x16, 0x4a, 0xb6, 0xc8, 0x08, 0xbf, 0x83, 0xc2, 0x30, 0x1a, 0xca, 0xae, + 0x88, 0x8f, 0x8d, 0xf6, 0x73, 0xfc, 0xef, 0x88, 0xf1, 0x7a, 0x21, 0x6e, 0x91, 0xa8, 0x3f, 0xa2, + 0xbc, 0x03, 0x8b, 0x72, 0x9d, 0x43, 0xa7, 0x70, 0x8f, 0x5e, 0xd2, 0x50, 0x49, 0xda, 0x3d, 0xd3, + 0x69, 0x51, 0xce, 0x56, 0xf6, 0x76, 0x64, 0xbc, 0x6b, 0x38, 0x4c, 0x2c, 0x50, 0x1b, 0x4a, 0xf1, + 0xfe, 0x57, 0xa4, 0x7b, 0x3b, 0x93, 0x16, 0x63, 0x06, 0x4b, 0xe9, 0xbe, 0x81, 0xbc, 0xf9, 0x46, + 0xe5, 0xd5, 0x0a, 0xf5, 0xc8, 0x6c, 0x88, 0xdc, 0xc4, 0x52, 0xb2, 0x71, 0x6a, 0x35, 0x7e, 0x0c, + 0xa8, 0xb9, 0x9a, 0xac, 0xdd, 0x41, 0x19, 0xf2, 0xa4, 0xdf, 0xe7, 0x54, 0x08, 0xcb, 0x65, 0x42, + 0xff, 0xf5, 0xd2, 0x57, 0x1a, 0x6f, 0xc6, 0xff, 0x1f, 0x4b, 0xfb, 0xee, 0xc0, 0xe3, 0x93, 0xe1, + 0x58, 0x8d, 0x88, 0xa4, 0xa7, 0x82, 0xf2, 0xf7, 0x13, 0xca, 0xc9, 0xc2, 0xb1, 0x09, 0xd1, 0x9e, + 0x8a, 0xef, 0x62, 0x45, 0x4d, 0x88, 0x5a, 0x50, 0x52, 0x82, 0xf2, 0x2e, 0xb3, 0x25, 0xc6, 0xa4, + 0xd5, 0xb4, 0xc1, 0xad, 0x73, 0x17, 0x55, 0x32, 0x5c, 0x34, 0xf1, 0xe4, 0x86, 0x26, 0xcc, 0x4d, + 0x08, 0x3c, 0x5c, 0xd7, 0xea, 0xfe, 0x65, 0xe8, 0x67, 0xdb, 0x45, 0x4d, 0x41, 0xe7, 0x50, 0xa5, + 0x1d, 0x37, 0x7e, 0xee, 0xc1, 0xad, 0xf8, 0xd9, 0xa0, 0x10, 0xf6, 0x93, 0xcf, 0x08, 0x1d, 0xa5, + 0x71, 0xa7, 0xbc, 0x63, 0xb7, 0xb6, 0x1d, 0x68, 0x16, 0x9c, 0x41, 0x6d, 0xc8, 0x19, 0x5f, 0x57, + 0x37, 0x19, 0x4d, 0x13, 0xfb, 0xdb, 0xbd, 0xe8, 0x67, 0xd0, 0x67, 0x28, 0x24, 0x5c, 0x80, 0x9e, + 0x6e, 0xe8, 0x26, 0x61, 0x2b, 0xf7, 0x68, 0x2b, 0x6e, 0xa9, 0xf0, 0x0d, 0x0e, 0x53, 0xf7, 0x84, + 0x8e, 0x53, 0x1b, 0xdc, 0xe0, 0x2b, 0xb7, 0xbe, 0x43, 0x85, 0xd5, 0x7f, 0xfb, 0xea, 0x6a, 0xe6, + 0x39, 0xd7, 0x33, 0xcf, 0xf9, 0x3d, 0xf3, 0x9c, 0x1f, 0x73, 0x2f, 0x73, 0x3d, 0xf7, 0x32, 0xbf, + 0xe6, 0x5e, 0xe6, 0xa3, 0xab, 0xd9, 0x44, 0xff, 0x2b, 0x1e, 0xb2, 0xe0, 0x32, 0xf9, 0x3f, 0xee, + 0xe5, 0xe2, 0x9f, 0xdc, 0xcb, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x77, 0xb6, 0x2c, 0xc3, 0xfb, + 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -451,6 +564,8 @@ type QueryClient interface { Schema(ctx context.Context, in *SchemaRequest, opts ...grpc.CallOption) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(ctx context.Context, in *AccountTypeRequest, opts ...grpc.CallOption) (*AccountTypeResponse, error) + // SimulateUserOperation simulates a user operation. + SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) } type queryClient struct { @@ -488,6 +603,15 @@ func (c *queryClient) AccountType(ctx context.Context, in *AccountTypeRequest, o return out, nil } +func (c *queryClient) SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) { + out := new(SimulateUserOperationResponse) + err := c.cc.Invoke(ctx, "/cosmos.accounts.v1.Query/SimulateUserOperation", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // QueryServer is the server API for Query service. type QueryServer interface { // AccountQuery runs an account query. @@ -496,6 +620,8 @@ type QueryServer interface { Schema(context.Context, *SchemaRequest) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) + // SimulateUserOperation simulates a user operation. + SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. @@ -511,6 +637,9 @@ func (*UnimplementedQueryServer) Schema(ctx context.Context, req *SchemaRequest) func (*UnimplementedQueryServer) AccountType(ctx context.Context, req *AccountTypeRequest) (*AccountTypeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method AccountType not implemented") } +func (*UnimplementedQueryServer) SimulateUserOperation(ctx context.Context, req *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SimulateUserOperation not implemented") +} func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) @@ -570,6 +699,24 @@ func _Query_AccountType_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_SimulateUserOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SimulateUserOperationRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).SimulateUserOperation(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cosmos.accounts.v1.Query/SimulateUserOperation", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).SimulateUserOperation(ctx, req.(*SimulateUserOperationRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cosmos.accounts.v1.Query", HandlerType: (*QueryServer)(nil), @@ -586,6 +733,10 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "AccountType", Handler: _Query_AccountType_Handler, }, + { + MethodName: "SimulateUserOperation", + Handler: _Query_SimulateUserOperation_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "cosmos/accounts/v1/query.proto", @@ -858,6 +1009,83 @@ func (m *AccountTypeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *SimulateUserOperationRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SimulateUserOperationRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SimulateUserOperationRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.UserOperation != nil { + { + size, err := m.UserOperation.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.Bundler) > 0 { + i -= len(m.Bundler) + copy(dAtA[i:], m.Bundler) + i = encodeVarintQuery(dAtA, i, uint64(len(m.Bundler))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *SimulateUserOperationResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SimulateUserOperationResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SimulateUserOperationResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.UserOperationResponse != nil { + { + size, err := m.UserOperationResponse.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset @@ -980,6 +1208,36 @@ func (m *AccountTypeResponse) Size() (n int) { return n } +func (m *SimulateUserOperationRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Bundler) + if l > 0 { + n += 1 + l + sovQuery(uint64(l)) + } + if m.UserOperation != nil { + l = m.UserOperation.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + +func (m *SimulateUserOperationResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.UserOperationResponse != nil { + l = m.UserOperationResponse.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -1704,6 +1962,210 @@ func (m *AccountTypeResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *SimulateUserOperationRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SimulateUserOperationRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SimulateUserOperationRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Bundler", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Bundler = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UserOperation", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.UserOperation == nil { + m.UserOperation = &UserOperation{} + } + if err := m.UserOperation.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SimulateUserOperationResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SimulateUserOperationResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SimulateUserOperationResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UserOperationResponse", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.UserOperationResponse == nil { + m.UserOperationResponse = &UserOperationResponse{} + } + if err := m.UserOperationResponse.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 From bde7eb1a4dd73c0aead4a918829400edb93221ff Mon Sep 17 00:00:00 2001 From: Marko Date: Tue, 9 Jan 2024 16:14:36 +0100 Subject: [PATCH 08/28] refactor(core)!: cleanup dependency graph (#18866) Co-authored-by: Likhita Polavarapu <78951027+likhita-809@users.noreply.github.com> --- Dockerfile | 1 + UPGRADING.md | 4 + baseapp/utils_test.go | 2 +- client/v2/go.mod | 1 + client/v2/go.sum | 2 - contrib/images/simd-env/Dockerfile | 1 + core/CHANGELOG.md | 1 + core/appmodule/README.md | 232 +----------------- core/appmodule/module.go | 4 - core/go.mod | 18 +- core/go.sum | 67 +---- core/intermodule/client.go | 32 --- {core => depinject}/appconfig/config.go | 2 +- {core => depinject}/appconfig/config_test.go | 8 +- {core => depinject}/appconfig/doc.go | 0 depinject/appmodule/README.md | 232 ++++++++++++++++++ {core => depinject}/appmodule/option.go | 2 +- {core => depinject}/appmodule/register.go | 2 +- depinject/go.mod | 10 +- depinject/go.sum | 25 +- .../internal/appconfig}/buf.gen.yaml | 0 .../internal/appconfig}/buf.yaml | 0 .../internal/appconfig}/registry.go | 0 .../internal/appconfig}/testpb/test.proto | 0 .../internal/appconfig}/testpb/test.pulsar.go | 0 docs/build/building-modules/15-depinject.md | 28 ++- go.mod | 1 + go.sum | 2 - orm/go.mod | 2 + orm/go.sum | 2 - orm/model/ormdb/module_test.go | 8 +- orm/orm.go | 6 +- runtime/app.go | 4 +- runtime/module.go | 7 +- simapp/app_config.go | 2 +- simapp/go.mod | 1 + simapp/go.sum | 2 - simapp/gomod2nix.toml | 3 - tests/go.mod | 1 + tests/go.sum | 2 - tests/starship/tests/go.mod | 1 + tests/starship/tests/go.sum | 2 - testutil/configurator/configurator.go | 2 +- x/accounts/go.mod | 1 + x/accounts/go.sum | 2 - x/auth/go.mod | 1 + x/auth/go.sum | 2 - x/auth/module.go | 6 +- x/auth/tx/config/config.go | 2 +- x/auth/vesting/module.go | 8 +- x/authz/go.mod | 1 + x/authz/go.sum | 2 - x/authz/module/module.go | 6 +- x/bank/go.mod | 1 + x/bank/go.sum | 2 - x/bank/module.go | 6 +- x/circuit/go.mod | 1 + x/circuit/go.sum | 2 - x/circuit/module.go | 5 +- x/consensus/module.go | 8 +- x/counter/module.go | 8 +- x/crisis/module.go | 5 +- x/distribution/go.mod | 1 + x/distribution/go.sum | 2 - x/distribution/module.go | 6 +- x/evidence/go.mod | 1 + x/evidence/go.sum | 2 - x/evidence/module.go | 6 +- x/feegrant/go.mod | 1 + x/feegrant/go.sum | 2 - x/feegrant/module/module.go | 6 +- x/genutil/module.go | 5 +- x/gov/go.mod | 1 + x/gov/go.sum | 2 - x/gov/module.go | 7 +- x/group/go.mod | 1 + x/group/go.sum | 2 - x/group/module/module.go | 6 +- x/mint/go.mod | 1 + x/mint/go.sum | 2 - x/mint/module.go | 6 +- x/nft/go.mod | 1 + x/nft/go.sum | 2 - x/nft/module/module.go | 8 +- x/params/go.mod | 1 + x/params/go.sum | 2 - x/params/module.go | 6 +- x/protocolpool/go.mod | 1 + x/protocolpool/go.sum | 2 - x/protocolpool/module.go | 5 +- x/slashing/go.mod | 1 + x/slashing/go.sum | 2 - x/slashing/module.go | 5 +- x/staking/go.mod | 1 + x/staking/go.sum | 2 - x/staking/module.go | 8 +- x/upgrade/go.mod | 1 + x/upgrade/go.sum | 2 - x/upgrade/module.go | 7 +- 99 files changed, 432 insertions(+), 476 deletions(-) delete mode 100644 core/intermodule/client.go rename {core => depinject}/appconfig/config.go (98%) rename {core => depinject}/appconfig/config_test.go (96%) rename {core => depinject}/appconfig/doc.go (100%) create mode 100644 depinject/appmodule/README.md rename {core => depinject}/appmodule/option.go (96%) rename {core => depinject}/appmodule/register.go (94%) rename {core/internal => depinject/internal/appconfig}/buf.gen.yaml (100%) rename {core/internal => depinject/internal/appconfig}/buf.yaml (100%) rename {core/internal => depinject/internal/appconfig}/registry.go (100%) rename {core/internal => depinject/internal/appconfig}/testpb/test.proto (100%) rename {core/internal => depinject/internal/appconfig}/testpb/test.pulsar.go (100%) diff --git a/Dockerfile b/Dockerfile index d59d084de3f6..1f03e2fbe97a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -38,6 +38,7 @@ COPY x/auth/go.mod x/auth/go.sum ./x/auth/ COPY x/authz/go.mod x/authz/go.sum ./x/authz/ COPY x/bank/go.mod x/bank/go.sum ./x/bank/ COPY x/mint/go.mod x/mint/go.sum ./x/mint/ +COPY depinject/go.mod depinject/go.sum ./depinject/ RUN go mod download # Add source files diff --git a/UPGRADING.md b/UPGRADING.md index 326bee2c9a90..8713095acb3c 100644 --- a/UPGRADING.md +++ b/UPGRADING.md @@ -116,6 +116,10 @@ Refer to SimApp `root_v2.go` and `root.go` for an example with an app v2 and a l #### `**all**` +##### Dependency Injection + +Previously `cosmossdk.io/core` held functions `Invoke`, `Provide` and `Register` were moved to `cosmossdk.io/depinject/appmodule`. All modules using dependency injection must update their imports. + ##### Genesis Interface All genesis interfaces have been migrated to take context.Context instead of sdk.Context. diff --git a/baseapp/utils_test.go b/baseapp/utils_test.go index cece72c3d99a..160ecac8a98d 100644 --- a/baseapp/utils_test.go +++ b/baseapp/utils_test.go @@ -21,8 +21,8 @@ import ( runtimev1alpha1 "cosmossdk.io/api/cosmos/app/runtime/v1alpha1" appv1alpha1 "cosmossdk.io/api/cosmos/app/v1alpha1" "cosmossdk.io/core/address" - "cosmossdk.io/core/appconfig" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appconfig" errorsmod "cosmossdk.io/errors" "cosmossdk.io/math" storetypes "cosmossdk.io/store/types" diff --git a/client/v2/go.mod b/client/v2/go.mod index fda712d75bfe..6d281f99275a 100644 --- a/client/v2/go.mod +++ b/client/v2/go.mod @@ -168,6 +168,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ./../../ replace ( + cosmossdk.io/depinject => ./../../depinject cosmossdk.io/x/auth => ./../../x/auth cosmossdk.io/x/bank => ./../../x/bank cosmossdk.io/x/distribution => ./../../x/distribution diff --git a/client/v2/go.sum b/client/v2/go.sum index 0a913cb49f9b..3cfefc2a7f0f 100644 --- a/client/v2/go.sum +++ b/client/v2/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/contrib/images/simd-env/Dockerfile b/contrib/images/simd-env/Dockerfile index e7f78db0983f..0ed920028f58 100644 --- a/contrib/images/simd-env/Dockerfile +++ b/contrib/images/simd-env/Dockerfile @@ -9,6 +9,7 @@ COPY api/go.mod api/go.sum /work/api/ COPY core/go.mod core/go.sum /work/core/ COPY collections/go.mod collections/go.sum /work/collections/ COPY store/go.mod store/go.sum /work/store/ +COPY store/go.mod store/go.sum /work/depinject/ COPY x/tx/go.mod x/tx/go.sum /work/x/tx/ COPY x/protocolpool/go.mod x/protocolpool/go.sum /work/x/protocolpool/ COPY x/gov/go.mod x/gov/go.sum /work/x/gov/ diff --git a/core/CHANGELOG.md b/core/CHANGELOG.md index 71e06fa3727f..1af2b0fc308b 100644 --- a/core/CHANGELOG.md +++ b/core/CHANGELOG.md @@ -45,6 +45,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [#18857](https://github.com/cosmos/cosmos-sdk/pull/18857) Moved `FormatCoins` to `x/tx`. * [#18861](httpes://github.com/cosmos/cosmos-sdk/pull/18861) Moved `coin.ParseCoin` to `client/v2/internal`. +* [#18866](https://github.com/cosmos/cosmos-sdk/pull/18866) All items related to depinject have been moved to `cosmossdk.io/depinject` (`Provide`, `Invoke`, `Register`) ## [v0.12.0](https://github.com/cosmos/cosmos-sdk/releases/tag/core%2Fv0.11.0) diff --git a/core/appmodule/README.md b/core/appmodule/README.md index ebcdeaf74c3e..5d02cc25bdb3 100644 --- a/core/appmodule/README.md +++ b/core/appmodule/README.md @@ -1,232 +1,8 @@ -# Wiring up app modules for use with appconfig +# Appmodule -The `appconfig` framework allows Cosmos SDK modules to be composed declaratively using a configuration file without -requiring the app developer to understand the details of inter-module dependencies. + -## 1. Create a module config protobuf message +This package defines what is needed for an module to be used in the Cosmos SDK. -The first step in creating a module that works with `appconfig`, is to create a protobuf message for the module configuration. The best practices for defining the module configuration message are: -* Use a dedicated protobuf package for the module configuration message instead of placing it in the API protobuf package. For example, the module configuration for bank would go in `cosmos.bank.module.v1` instead of just `cosmos.bank.v1`. This decouples the state machine version from the API version. -* The module configuration message is usually called simply `Module`, ex. `cosmos.bank.module.v1.Module`. -* Create a new protobuf package and configuration message for each state machine breaking version of the module, ex. `cosmos.bank.module.v2.Module`, etc. - -The module configuration message should include any parameters which should be initialized at application startup. For example, the auth module needs to know the bech32 prefix of the app and the permissions of module accounts. - -In the future, it may be possible to update the app config through a governance proposal at runtime. - -All module configuration messages should define a module descriptor, using the `cosmos.app.v1alpha1.module` message option. - -Here is an example module configuration message for the `auth` module: - -```protobuf -package cosmos.auth.module.v1; - -import "cosmos/app/v1alpha1/module.proto"; - -message Module { - option (cosmos.app.v1alpha1.module) = { - go_import: "cosmossdk.io/x/auth" - }; - string bech32_prefix = 1; - repeated ModuleAccountPermission module_account_permissions = 2; -} -``` - -## 2. Register module depinject providers and invokers - -Once we have a module config object, we need to register depinject providers and invokers for the module using the `cosmossdk.io/core/appmodule` package. - -At the most basic level, we must define an `init` function in the package listed as the `go_import` in the module descriptor. This `init` function must call `appmodule.Register` with an empty instance of the config object and some options for initializing the module, ex: - -```go -func init() { - appmodule.Register(&modulev1.Module{}, - // options - ) -} -``` - -### `depinject` Provider and Invoker Basics - -A `depinject` "provider" is a function which takes dependencies from other modules as inputs and returns outputs for -other modules to use as dependencies. A `depinject` "invoker" is function which takes optional dependencies as inputs, -returns no outputs, and is run at the end of initializing the dependency graph. Providers are much more common than -invokers and should be the preferred method of wiring up modules when possible. Providers and invokers can be registered -for modules by using `appmodule.Provide` and `appmodule.Invoke` to create options which get passed -to `appmodule.Register` in the module `init` function, ex: - -```go -func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(provideSomething, provideSomethingElse), - appmodule.Invoke(invokeSomething), - ) -} -``` - -### `depinject` Types - -`depinject` constructor functions support these classes of input and output parameter types: - -* regular golang types (with special treatment of interface types as input parameters) -* structs with `depinject.In` and `depinject.Out` embedded -* `depinject.OnePerModuleType`s -* `depinject.ManyPerContainerType`s -* `depinject.ModuleKey` (which can only be defined as an input type) -* `error` (which gets special treatment as an output type) - -#### Regular Golang Types - -Regular golang types (besides the special cases described above) can be provided as both input and output parameters -to providers and invokers. For `depinject` to match an output parameter of one provider to an input parameter of -another, there must be an exact match for the type unless the input parameter is an input type. For instance, if -a provider defines a dependency on `Foo` and some module provides `*Foo`, these two types will not match and there -will be an error. - -#### Interface Input Types - -When interfaces are used as input parameters to providers and invokers, `depinject` will search the container for -all types that implement this interface. If there is an unambiguously matching type, then this type will be used -to satisfy that interface. If there is a conflict between two types matching the interface, the app developer -can use `golang_bindings` options in their app config in order to resolve the conflict. - -#### Structs with embedded `depinject.In` and `depinject.Out` - -Structs that have `depinject.In` or `depinject.Out` as an embedded field are treated specially by `depinject`, where -all of these structs fields are treated as input or output parameters, respectively. These structs allow custom options -to be defined using struct field tags. Currently, the only supported custom option is `optional:"true"` which marks -a field as optional. - -#### `depinject.OnePerModuleType`s - -Any type which implements the `depinject.OnePerModuleType` interface can be provided at most once by every module. -These types can be collected as an input parameter to some provider or invoker by defining an input parameter which -is a map of module names as strings to this parameter type. For example if `Foo` is a `OnePerModuleType`, then -`map[string]Foo` can be declared as an input parameter by some provider (which obviously cannot provide an instance of -`Foo` itself because that would cause a circular dependency). - -`OnePerModuleType`s should be used whenever different modules may provide the type *and* there is a need to provide -an ordering of these types based on the module name. Generally, in blockchains there is always a need for deterministic -orderings so using module names to provide that ordering is generally a good strategy for this use case. Ordering based -on module names can either be done implicitly by sorting the module names or explicitly as a parameter in the module -configuration object. - -#### `depinject.ManyPerContainerType`s - -`ManyPerContainerType`s can be provided by as many providers in as many modules as the user would like. If a type `Bar` -is a `ManyPerContainerType`, a provider may define an output parameter of `Bar` or `[]Bar` to provide `Bar` instances -to the container. A provider may define an input parameter of `[]Bar` to get all of the `Bar` instances in the -container (such a provider may not also return `Bar` as that would cause a circular dependency). The ordering of `Bar` -instances in the `[]Bar` input type should be assumed to be deterministic. - -`ManyPerContainerType`s should be used only when 1) ordering is unimportant or 2) the ordering can be defined by -some parameter on the type. For instance, if `Bar` had a field `Name string`, that is supposed to be unique in the -container then that could be used to provide an ordering. An example of a type that could work as a -`ManyPerContainerType` in this way is a wrapper around `*cobra.Command`, ex. -`type QueryCommand struct {*cobra.Command}`. This could be used to collect all the query commands in an app and then -cobra would take care of ordering. If this type of ordering is not available, a `OnePerModuleType` is probably a better -bet. - -#### Module-scoped Providers/`depinject.ModuleKey` as an input - -If `depinject.ModuleKey` is used as input parameter for a provider, the provider function will be treated as a -"module-scoped provider" which means that the provider function will be called exactly once every time -one of its outputs is needed by a module so that the provider can provide a unique instance of the dependency to -each module. - -Module-scoped dependencies should be used to provide dependencies which are private and unique to each module. Examples -of these are store keys and param subspaces. - -#### `error` as an output parameter - -`error` can be used as the last output parameter on any provider or invoker. If a provider or invoker with an `error` -parameter returns a non-nil value for `error`, `depinject` will fail and propagate this error up to the caller. - -### Provider Invocation Details - -Providers are called lazily as they are needed and will be invoked at most once (except for "module-scoped providers" -described above) if and only if at least one of their outputs is needed somewhere in the dependency graph. Providers -will only get called if all of their non-optional inputs can successfully be resolved by some other module, otherwise an -error will occur. Modules should proactively mark dependencies as `optional` if the module can still be successfully -built without this dependency. - -### Invoker Invocation Details - -Invokers are called at the end of container initialization after all providers that were needed to build the graph -were called. All the dependencies of invokers are automatically marked as optional so invokers should `nil` check -every input parameter. Invokers may cause additional providers to get run if they have a dependency that wasn't built -yet. But if a dependency to an invoker cannot be provided for some reason, the invoker will still get called but with -`nil` for that input. This allows invokers to still work with the lazy invocation model of providers which only -builds things which are actually necessary as a dependency for some module or the caller. - -Invokers should generally be used sparingly to perform some initialization logic which can't be done in the initial -provider, usually because of a circular dependency, and which may be optional. - -### Best practices - -* make dependencies `optional` whenever possible! -* interface types should be used whenever possible to avoid tight couplings between two modules. -* `OnePerModuleType`s should be used when there is something occurs at most once per module and the module name is a -convenient way for providing a deterministic order. -* `ManyPerContainerType`s should be used only when there is an obvious way to create an ordering from the types or -when ordering *really* doesn't matter (which is rare). -* module-scoped providers should be used for private, module-scoped dependencies -* use different providers for unrelated or loosely components or to resolve circular dependencies (see below) -* use invokers sparingly and always `nil`-check the inputs. - -### Resolving Circular Dependencies - -Circular dependencies are inevitable to crop up and there are ways to avoid them. While `depinject` cannot handle -circular dependency graphs of providers, many of the above tools are designed to enable satisfying circular dependencies -between modules. - -One of the key tactics for resolving circular dependencies is to use different providers and/or invokers to allow a -circular dependency between components. For example, say the slashing keeper depends on the keeper module but the -staking keeper also depends on the staking module indirectly (in the form of "staking hooks"). The slashing module -can declare a dependency directly on the staking keeper (using an interface to avoid actually importing the staking -keeper package). It can also provide an instance of the slashing keeper wrapped as staking hooks in a `OnePerModuleType` -we'll call `StakingHooksWrapper`. Now, if the staking module directly depended on the staking hooks wrappers -(`map[string]StakingHooksWrapper`) we would have a circular dependency graph and `depinject` would fail. To fix this, -the staking module can define an invoker which depends on `map[string]StakingHooksWrapper` and the staking keeper -(which was provided by the staking module already in a separate provided). In this way `depinject` will be able to -satisfy this dependency graph which allows staking and slashing to depend on each other in this order: - -* provide staking keeper -> slashing keeper -* provide slashing keeper wrapped as `StakingHooksWrapper` -* get `map[string]StakingHooksWrapper` and the staking keeper and wire them together - -## 3. Testing and Debugging The Module - -In order to test and debug the module configuration, we need to build an app config, generally defined in a YAML file. -This configuration should be passed first to `appconfig.LoadYAML` to get an `depinject.Config` instance.Then the -`depinject.Config` can be passed to `depinject.Inject` and we can try to resolve dependencies in the app config. -Alternatively, the `depinject.Config` can be created via [pure Go code](https://github.com/cosmos/cosmos-sdk/blob/v0.47.0-rc1/simapp/app_config.go). - -Ex: - -```go -//go:embed app.yaml -var appConfig []byte - -var AppConfig = appconfig.LoadYAML(appConfig) - -func TestModule(t *testing.T) { - var keeper Keeper - assert.NilError(t, depinject.Inject(AppConfig, &keeper)) -} -``` - -### Debugging `depinject` Graphs - -Whenever there is an error in a `depinject` graph, by default `depinject` will dump a bunch of logging output to the -console, print the error message, and save the dependency graph in [GraphViz](https://graphviz.org) DOT format to -the file `debug_container.dot`. Inspecting the GraphViz output by converting it to an SVG and viewing it in a web -browser or using some other GraphViz tool is *highly recommended*. - -If `depinject` does not return an error but there is still some weird issue wiring up modules, inspecting the GraphViz -and logging output is still *highly recommended* and can be done using `depinject.InjectDebug` with the debug option -`depinject.Debug`. - -App developers should attempt to familiarize themselves with the GraphViz graph of their app to see which modules -depend on which other modules. +If you are looking at integrating Dependency injection into your module please see [depinject appmodule documentation](../../depinject/appmodule/README.md) diff --git a/core/appmodule/module.go b/core/appmodule/module.go index 4d31ae0a268d..ff28987b1728 100644 --- a/core/appmodule/module.go +++ b/core/appmodule/module.go @@ -4,8 +4,6 @@ import ( "context" "google.golang.org/grpc" - - "cosmossdk.io/depinject" ) // AppModule is a tag interface for app module implementations to use as a basis @@ -13,8 +11,6 @@ import ( // type that all valid app modules should provide so that they can be identified // by other modules (usually via depinject) as app modules. type AppModule interface { - depinject.OnePerModuleType - // IsAppModule is a dummy method to tag a struct as implementing an AppModule. IsAppModule() } diff --git a/core/go.mod b/core/go.mod index 5623e6ba3e10..87cdcf5c381a 100644 --- a/core/go.mod +++ b/core/go.mod @@ -3,34 +3,22 @@ module cosmossdk.io/core go 1.20 require ( - cosmossdk.io/api v0.7.2 - cosmossdk.io/depinject v1.0.0-alpha.4 - github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/stretchr/testify v1.8.4 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 - gotest.tools/v3 v3.5.1 - sigs.k8s.io/yaml v1.4.0 ) require ( - github.com/cockroachdb/errors v1.11.1 // indirect - github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/redact v1.1.5 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/getsentry/sentry-go v0.23.0 // indirect - github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.3 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/kr/pretty v0.3.1 // indirect - github.com/kr/text v0.2.0 // indirect - github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/rogpeppe/go-internal v1.11.0 // indirect - golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect - golang.org/x/net v0.19.0 // indirect + golang.org/x/net v0.17.0 // indirect golang.org/x/sys v0.15.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect + gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/core/go.sum b/core/go.sum index 12ea1612fc97..dcb075db3402 100644 --- a/core/go.sum +++ b/core/go.sum @@ -1,40 +1,20 @@ -cosmossdk.io/api v0.7.2 h1:BO3i5fvKMKvfaUiMkCznxViuBEfyWA/k6w2eAF6q1C4= -cosmossdk.io/api v0.7.2/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= -github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= -github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= -github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= -github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= -github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cosmos/cosmos-proto v1.0.0-beta.3 h1:VitvZ1lPORTVxkmF2fAp3IiA61xVwArQYKXTdEcpW6o= -github.com/cosmos/cosmos-proto v1.0.0-beta.3/go.mod h1:t8IASdLaAq+bbHbjq4p960BvcTqtwuAxid3b/2rOD6I= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/getsentry/sentry-go v0.23.0 h1:dn+QRCeJv4pPt9OjVXiMcGIBIefaTJPw/h0bZWO05nE= -github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= -github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= -github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= -github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= -github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= +github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= +github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= @@ -42,43 +22,15 @@ github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDN github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/exp v0.0.0-20231006140011-7918f672742d h1:jtJma62tbqLibJ5sFQz8bKtEM8rJBtfilJ2qTU199MI= -golang.org/x/exp v0.0.0-20231006140011-7918f672742d/go.mod h1:ldy0pHrwJyGW56pPQzzkH36rKxoZW1tw7ZJpeKx+hdo= -golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= -golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= -golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= +golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c h1:jHkCUWkseRf+W+edG5hMzr/Uh1xkDREY4caybAq4dpY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= google.golang.org/grpc v1.60.1 h1:26+wFr+cNqSGFcOXcabYC0lUVJVRa2Sb2ortSK7VrEU= google.golang.org/grpc v1.60.1/go.mod h1:OlCHIeLYqSSsLi6i49B5QGdzaMZK9+M7LXN2FKz4eGM= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= @@ -87,9 +39,6 @@ google.golang.org/protobuf v1.32.0 h1:pPC6BG5ex8PDFnkbrGU3EixyhKcQ2aDuBS36lqK/C7 google.golang.org/protobuf v1.32.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= -gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= -sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= -sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/core/intermodule/client.go b/core/intermodule/client.go deleted file mode 100644 index 0c6d5f33a4a2..000000000000 --- a/core/intermodule/client.go +++ /dev/null @@ -1,32 +0,0 @@ -package intermodule - -import ( - "context" - - "google.golang.org/grpc" -) - -// Client is an inter-module client as specified in ADR-033. It -// allows one module to send msg's and queries to other modules provided -// that the request is valid and can be properly authenticated. -type Client interface { - grpc.ClientConnInterface - - // InvokerByMethod resolves an invoker for the provided method or returns an error. - InvokerByMethod(method string) (Invoker, error) - - // InvokerByRequest resolves an invoker for the provided request type or returns an error. - // This only works for Msg's as they are routed based on type name in transactions already. - // For queries use InvokerByMethod instead. - InvokerByRequest(request any) (Invoker, error) - - // DerivedClient returns an inter-module client for the ADR-028 derived - // module address for the provided key. - DerivedClient(key []byte) Client - - // Address is the ADR-028 address of this client against which messages will be authenticated. - Address() []byte -} - -// Invoker is an inter-module invoker that has already been resolved to a specific method route. -type Invoker func(ctx context.Context, request any, opts ...grpc.CallOption) (res any, err error) diff --git a/core/appconfig/config.go b/depinject/appconfig/config.go similarity index 98% rename from core/appconfig/config.go rename to depinject/appconfig/config.go index 779eecee9853..4bc44f6ace0b 100644 --- a/core/appconfig/config.go +++ b/depinject/appconfig/config.go @@ -13,8 +13,8 @@ import ( "sigs.k8s.io/yaml" appv1alpha1 "cosmossdk.io/api/cosmos/app/v1alpha1" - "cosmossdk.io/core/internal" "cosmossdk.io/depinject" + internal "cosmossdk.io/depinject/internal/appconfig" ) // LoadJSON loads an app config in JSON format. diff --git a/core/appconfig/config_test.go b/depinject/appconfig/config_test.go similarity index 96% rename from core/appconfig/config_test.go rename to depinject/appconfig/config_test.go index 0e13f0b4c657..8595f96b5722 100644 --- a/core/appconfig/config_test.go +++ b/depinject/appconfig/config_test.go @@ -10,11 +10,11 @@ import ( "gotest.tools/v3/assert" - "cosmossdk.io/core/appconfig" - "cosmossdk.io/core/appmodule" - "cosmossdk.io/core/internal" - "cosmossdk.io/core/internal/testpb" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appconfig" + "cosmossdk.io/depinject/appmodule" + internal "cosmossdk.io/depinject/internal/appconfig" + "cosmossdk.io/depinject/internal/appconfig/testpb" ) func expectContainerErrorContains(t *testing.T, option depinject.Config, contains string) { diff --git a/core/appconfig/doc.go b/depinject/appconfig/doc.go similarity index 100% rename from core/appconfig/doc.go rename to depinject/appconfig/doc.go diff --git a/depinject/appmodule/README.md b/depinject/appmodule/README.md new file mode 100644 index 000000000000..ebcdeaf74c3e --- /dev/null +++ b/depinject/appmodule/README.md @@ -0,0 +1,232 @@ +# Wiring up app modules for use with appconfig + +The `appconfig` framework allows Cosmos SDK modules to be composed declaratively using a configuration file without +requiring the app developer to understand the details of inter-module dependencies. + +## 1. Create a module config protobuf message + +The first step in creating a module that works with `appconfig`, is to create a protobuf message for the module configuration. The best practices for defining the module configuration message are: + +* Use a dedicated protobuf package for the module configuration message instead of placing it in the API protobuf package. For example, the module configuration for bank would go in `cosmos.bank.module.v1` instead of just `cosmos.bank.v1`. This decouples the state machine version from the API version. +* The module configuration message is usually called simply `Module`, ex. `cosmos.bank.module.v1.Module`. +* Create a new protobuf package and configuration message for each state machine breaking version of the module, ex. `cosmos.bank.module.v2.Module`, etc. + +The module configuration message should include any parameters which should be initialized at application startup. For example, the auth module needs to know the bech32 prefix of the app and the permissions of module accounts. + +In the future, it may be possible to update the app config through a governance proposal at runtime. + +All module configuration messages should define a module descriptor, using the `cosmos.app.v1alpha1.module` message option. + +Here is an example module configuration message for the `auth` module: + +```protobuf +package cosmos.auth.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import: "cosmossdk.io/x/auth" + }; + string bech32_prefix = 1; + repeated ModuleAccountPermission module_account_permissions = 2; +} +``` + +## 2. Register module depinject providers and invokers + +Once we have a module config object, we need to register depinject providers and invokers for the module using the `cosmossdk.io/core/appmodule` package. + +At the most basic level, we must define an `init` function in the package listed as the `go_import` in the module descriptor. This `init` function must call `appmodule.Register` with an empty instance of the config object and some options for initializing the module, ex: + +```go +func init() { + appmodule.Register(&modulev1.Module{}, + // options + ) +} +``` + +### `depinject` Provider and Invoker Basics + +A `depinject` "provider" is a function which takes dependencies from other modules as inputs and returns outputs for +other modules to use as dependencies. A `depinject` "invoker" is function which takes optional dependencies as inputs, +returns no outputs, and is run at the end of initializing the dependency graph. Providers are much more common than +invokers and should be the preferred method of wiring up modules when possible. Providers and invokers can be registered +for modules by using `appmodule.Provide` and `appmodule.Invoke` to create options which get passed +to `appmodule.Register` in the module `init` function, ex: + +```go +func init() { + appmodule.Register(&modulev1.Module{}, + appmodule.Provide(provideSomething, provideSomethingElse), + appmodule.Invoke(invokeSomething), + ) +} +``` + +### `depinject` Types + +`depinject` constructor functions support these classes of input and output parameter types: + +* regular golang types (with special treatment of interface types as input parameters) +* structs with `depinject.In` and `depinject.Out` embedded +* `depinject.OnePerModuleType`s +* `depinject.ManyPerContainerType`s +* `depinject.ModuleKey` (which can only be defined as an input type) +* `error` (which gets special treatment as an output type) + +#### Regular Golang Types + +Regular golang types (besides the special cases described above) can be provided as both input and output parameters +to providers and invokers. For `depinject` to match an output parameter of one provider to an input parameter of +another, there must be an exact match for the type unless the input parameter is an input type. For instance, if +a provider defines a dependency on `Foo` and some module provides `*Foo`, these two types will not match and there +will be an error. + +#### Interface Input Types + +When interfaces are used as input parameters to providers and invokers, `depinject` will search the container for +all types that implement this interface. If there is an unambiguously matching type, then this type will be used +to satisfy that interface. If there is a conflict between two types matching the interface, the app developer +can use `golang_bindings` options in their app config in order to resolve the conflict. + +#### Structs with embedded `depinject.In` and `depinject.Out` + +Structs that have `depinject.In` or `depinject.Out` as an embedded field are treated specially by `depinject`, where +all of these structs fields are treated as input or output parameters, respectively. These structs allow custom options +to be defined using struct field tags. Currently, the only supported custom option is `optional:"true"` which marks +a field as optional. + +#### `depinject.OnePerModuleType`s + +Any type which implements the `depinject.OnePerModuleType` interface can be provided at most once by every module. +These types can be collected as an input parameter to some provider or invoker by defining an input parameter which +is a map of module names as strings to this parameter type. For example if `Foo` is a `OnePerModuleType`, then +`map[string]Foo` can be declared as an input parameter by some provider (which obviously cannot provide an instance of +`Foo` itself because that would cause a circular dependency). + +`OnePerModuleType`s should be used whenever different modules may provide the type *and* there is a need to provide +an ordering of these types based on the module name. Generally, in blockchains there is always a need for deterministic +orderings so using module names to provide that ordering is generally a good strategy for this use case. Ordering based +on module names can either be done implicitly by sorting the module names or explicitly as a parameter in the module +configuration object. + +#### `depinject.ManyPerContainerType`s + +`ManyPerContainerType`s can be provided by as many providers in as many modules as the user would like. If a type `Bar` +is a `ManyPerContainerType`, a provider may define an output parameter of `Bar` or `[]Bar` to provide `Bar` instances +to the container. A provider may define an input parameter of `[]Bar` to get all of the `Bar` instances in the +container (such a provider may not also return `Bar` as that would cause a circular dependency). The ordering of `Bar` +instances in the `[]Bar` input type should be assumed to be deterministic. + +`ManyPerContainerType`s should be used only when 1) ordering is unimportant or 2) the ordering can be defined by +some parameter on the type. For instance, if `Bar` had a field `Name string`, that is supposed to be unique in the +container then that could be used to provide an ordering. An example of a type that could work as a +`ManyPerContainerType` in this way is a wrapper around `*cobra.Command`, ex. +`type QueryCommand struct {*cobra.Command}`. This could be used to collect all the query commands in an app and then +cobra would take care of ordering. If this type of ordering is not available, a `OnePerModuleType` is probably a better +bet. + +#### Module-scoped Providers/`depinject.ModuleKey` as an input + +If `depinject.ModuleKey` is used as input parameter for a provider, the provider function will be treated as a +"module-scoped provider" which means that the provider function will be called exactly once every time +one of its outputs is needed by a module so that the provider can provide a unique instance of the dependency to +each module. + +Module-scoped dependencies should be used to provide dependencies which are private and unique to each module. Examples +of these are store keys and param subspaces. + +#### `error` as an output parameter + +`error` can be used as the last output parameter on any provider or invoker. If a provider or invoker with an `error` +parameter returns a non-nil value for `error`, `depinject` will fail and propagate this error up to the caller. + +### Provider Invocation Details + +Providers are called lazily as they are needed and will be invoked at most once (except for "module-scoped providers" +described above) if and only if at least one of their outputs is needed somewhere in the dependency graph. Providers +will only get called if all of their non-optional inputs can successfully be resolved by some other module, otherwise an +error will occur. Modules should proactively mark dependencies as `optional` if the module can still be successfully +built without this dependency. + +### Invoker Invocation Details + +Invokers are called at the end of container initialization after all providers that were needed to build the graph +were called. All the dependencies of invokers are automatically marked as optional so invokers should `nil` check +every input parameter. Invokers may cause additional providers to get run if they have a dependency that wasn't built +yet. But if a dependency to an invoker cannot be provided for some reason, the invoker will still get called but with +`nil` for that input. This allows invokers to still work with the lazy invocation model of providers which only +builds things which are actually necessary as a dependency for some module or the caller. + +Invokers should generally be used sparingly to perform some initialization logic which can't be done in the initial +provider, usually because of a circular dependency, and which may be optional. + +### Best practices + +* make dependencies `optional` whenever possible! +* interface types should be used whenever possible to avoid tight couplings between two modules. +* `OnePerModuleType`s should be used when there is something occurs at most once per module and the module name is a +convenient way for providing a deterministic order. +* `ManyPerContainerType`s should be used only when there is an obvious way to create an ordering from the types or +when ordering *really* doesn't matter (which is rare). +* module-scoped providers should be used for private, module-scoped dependencies +* use different providers for unrelated or loosely components or to resolve circular dependencies (see below) +* use invokers sparingly and always `nil`-check the inputs. + +### Resolving Circular Dependencies + +Circular dependencies are inevitable to crop up and there are ways to avoid them. While `depinject` cannot handle +circular dependency graphs of providers, many of the above tools are designed to enable satisfying circular dependencies +between modules. + +One of the key tactics for resolving circular dependencies is to use different providers and/or invokers to allow a +circular dependency between components. For example, say the slashing keeper depends on the keeper module but the +staking keeper also depends on the staking module indirectly (in the form of "staking hooks"). The slashing module +can declare a dependency directly on the staking keeper (using an interface to avoid actually importing the staking +keeper package). It can also provide an instance of the slashing keeper wrapped as staking hooks in a `OnePerModuleType` +we'll call `StakingHooksWrapper`. Now, if the staking module directly depended on the staking hooks wrappers +(`map[string]StakingHooksWrapper`) we would have a circular dependency graph and `depinject` would fail. To fix this, +the staking module can define an invoker which depends on `map[string]StakingHooksWrapper` and the staking keeper +(which was provided by the staking module already in a separate provided). In this way `depinject` will be able to +satisfy this dependency graph which allows staking and slashing to depend on each other in this order: + +* provide staking keeper -> slashing keeper +* provide slashing keeper wrapped as `StakingHooksWrapper` +* get `map[string]StakingHooksWrapper` and the staking keeper and wire them together + +## 3. Testing and Debugging The Module + +In order to test and debug the module configuration, we need to build an app config, generally defined in a YAML file. +This configuration should be passed first to `appconfig.LoadYAML` to get an `depinject.Config` instance.Then the +`depinject.Config` can be passed to `depinject.Inject` and we can try to resolve dependencies in the app config. +Alternatively, the `depinject.Config` can be created via [pure Go code](https://github.com/cosmos/cosmos-sdk/blob/v0.47.0-rc1/simapp/app_config.go). + +Ex: + +```go +//go:embed app.yaml +var appConfig []byte + +var AppConfig = appconfig.LoadYAML(appConfig) + +func TestModule(t *testing.T) { + var keeper Keeper + assert.NilError(t, depinject.Inject(AppConfig, &keeper)) +} +``` + +### Debugging `depinject` Graphs + +Whenever there is an error in a `depinject` graph, by default `depinject` will dump a bunch of logging output to the +console, print the error message, and save the dependency graph in [GraphViz](https://graphviz.org) DOT format to +the file `debug_container.dot`. Inspecting the GraphViz output by converting it to an SVG and viewing it in a web +browser or using some other GraphViz tool is *highly recommended*. + +If `depinject` does not return an error but there is still some weird issue wiring up modules, inspecting the GraphViz +and logging output is still *highly recommended* and can be done using `depinject.InjectDebug` with the debug option +`depinject.Debug`. + +App developers should attempt to familiarize themselves with the GraphViz graph of their app to see which modules +depend on which other modules. diff --git a/core/appmodule/option.go b/depinject/appmodule/option.go similarity index 96% rename from core/appmodule/option.go rename to depinject/appmodule/option.go index 951bfc6e2d7c..df8f0c499469 100644 --- a/core/appmodule/option.go +++ b/depinject/appmodule/option.go @@ -1,7 +1,7 @@ package appmodule import ( - "cosmossdk.io/core/internal" + internal "cosmossdk.io/depinject/internal/appconfig" ) // Option is a functional option for implementing modules. diff --git a/core/appmodule/register.go b/depinject/appmodule/register.go similarity index 94% rename from core/appmodule/register.go rename to depinject/appmodule/register.go index 56004dbb863c..ed68ebfcefef 100644 --- a/core/appmodule/register.go +++ b/depinject/appmodule/register.go @@ -5,7 +5,7 @@ import ( "google.golang.org/protobuf/proto" - "cosmossdk.io/core/internal" + internal "cosmossdk.io/depinject/internal/appconfig" ) // Register registers a module with the global module registry. The provided diff --git a/depinject/go.mod b/depinject/go.mod index 713e5498c166..be6de69b96a5 100644 --- a/depinject/go.mod +++ b/depinject/go.mod @@ -3,10 +3,14 @@ module cosmossdk.io/depinject go 1.20 require ( + cosmossdk.io/api v0.7.2 github.com/cockroachdb/errors v1.11.1 + github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/stretchr/testify v1.8.4 - golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e + golang.org/x/exp v0.0.0-20230811145659-89c5cff77bcb + google.golang.org/protobuf v1.31.0 gotest.tools/v3 v3.5.1 + sigs.k8s.io/yaml v1.4.0 ) require ( @@ -15,13 +19,17 @@ require ( github.com/davecgh/go-spew v1.1.1 // indirect github.com/getsentry/sentry-go v0.23.0 // indirect github.com/gogo/protobuf v1.3.2 // indirect + github.com/golang/protobuf v1.5.3 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/rogpeppe/go-internal v1.11.0 // indirect + golang.org/x/net v0.17.0 // indirect golang.org/x/sys v0.15.0 // indirect golang.org/x/text v0.14.0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect + google.golang.org/grpc v1.58.3 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/depinject/go.sum b/depinject/go.sum index 09e787234563..7f566f79f2a2 100644 --- a/depinject/go.sum +++ b/depinject/go.sum @@ -1,9 +1,13 @@ +cosmossdk.io/api v0.7.2 h1:BO3i5fvKMKvfaUiMkCznxViuBEfyWA/k6w2eAF6q1C4= +cosmossdk.io/api v0.7.2/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cosmos/cosmos-proto v1.0.0-beta.3 h1:VitvZ1lPORTVxkmF2fAp3IiA61xVwArQYKXTdEcpW6o= +github.com/cosmos/cosmos-proto v1.0.0-beta.3/go.mod h1:t8IASdLaAq+bbHbjq4p960BvcTqtwuAxid3b/2rOD6I= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -12,6 +16,11 @@ github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= +github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= @@ -36,14 +45,16 @@ github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9dec golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e h1:+WEEuIdZHnUeJJmEUjyYC2gfUMj69yZXw17EnHg/otA= -golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e/go.mod h1:Kr81I6Kryrl9sr8s2FK3vxD90NdsKWRuOIl2O4CvYbA= +golang.org/x/exp v0.0.0-20230811145659-89c5cff77bcb h1:mIKbk8weKhSeLH2GmUTrvx8CjkyJmnU1wFmg59CUjFA= +golang.org/x/exp v0.0.0-20230811145659-89c5cff77bcb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= +golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -64,9 +75,19 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c h1:jHkCUWkseRf+W+edG5hMzr/Uh1xkDREY4caybAq4dpY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/grpc v1.58.3 h1:BjnpXut1btbtgN/6sp+brB2Kbm2LjNXnidYujAVbSoQ= +google.golang.org/grpc v1.58.3/go.mod h1:tgX3ZQDlNJGU96V6yHh1T/JeoBQ2TXdr43YbYSsCJk0= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= +sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= +sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/core/internal/buf.gen.yaml b/depinject/internal/appconfig/buf.gen.yaml similarity index 100% rename from core/internal/buf.gen.yaml rename to depinject/internal/appconfig/buf.gen.yaml diff --git a/core/internal/buf.yaml b/depinject/internal/appconfig/buf.yaml similarity index 100% rename from core/internal/buf.yaml rename to depinject/internal/appconfig/buf.yaml diff --git a/core/internal/registry.go b/depinject/internal/appconfig/registry.go similarity index 100% rename from core/internal/registry.go rename to depinject/internal/appconfig/registry.go diff --git a/core/internal/testpb/test.proto b/depinject/internal/appconfig/testpb/test.proto similarity index 100% rename from core/internal/testpb/test.proto rename to depinject/internal/appconfig/testpb/test.proto diff --git a/core/internal/testpb/test.pulsar.go b/depinject/internal/appconfig/testpb/test.pulsar.go similarity index 100% rename from core/internal/testpb/test.pulsar.go rename to depinject/internal/appconfig/testpb/test.pulsar.go diff --git a/docs/build/building-modules/15-depinject.md b/docs/build/building-modules/15-depinject.md index f277e5b1db79..8cfe4f6e30d7 100644 --- a/docs/build/building-modules/15-depinject.md +++ b/docs/build/building-modules/15-depinject.md @@ -104,18 +104,28 @@ All methods, structs and their fields must be public for `depinject`. 5. Create a function named `ProvideModule` (as called in 1.) and use the inputs for instantiating the module outputs. - ```go reference - https://github.com/cosmos/cosmos-sdk/blob/v0.50.0-alpha.0/x/group/module/module.go#L220-L235 - ``` + ```go reference + https://github.com/cosmos/cosmos-sdk/blob/v0.50.0-alpha.0/x/group/module/module.go#L220-L235 + ``` + + The `ProvideModule` function should return an instance of `cosmossdk.io/core/appmodule.AppModule` which implements + one or more app module extension interfaces for initializing the module. + + Following is the complete app wiring configuration for `group`: + + ```go reference + https://github.com/cosmos/cosmos-sdk/blob/v0.50.0-alpha.0/x/group/module/module.go#L194-L235 + ``` + +6. All modules must implement `depinject.OnePerModuleType` interface. This is used in order to tell the dependency injection framework that the module can only be instantiated once. + + ```go reference + https://github.com/cosmos/cosmos-sdk/blob/f4bdec3433373cc4950f4680743e969495763fbb/x/group/module/module.go#L64-L65 + ``` + -The `ProvideModule` function should return an instance of `cosmossdk.io/core/appmodule.AppModule` which implements -one or more app module extension interfaces for initializing the module. -Following is the complete app wiring configuration for `group`: -```go reference -https://github.com/cosmos/cosmos-sdk/blob/v0.50.0-alpha.0/x/group/module/module.go#L194-L235 -``` The module is now ready to be used with `depinject` by a chain developer. diff --git a/go.mod b/go.mod index 68e457662fc0..f6aea49a663f 100644 --- a/go.mod +++ b/go.mod @@ -178,6 +178,7 @@ require ( // ) // TODO remove after all modules have their own go.mods replace ( + cosmossdk.io/depinject => ./depinject cosmossdk.io/x/auth => ./x/auth cosmossdk.io/x/bank => ./x/bank cosmossdk.io/x/distribution => ./x/distribution diff --git a/go.sum b/go.sum index ae1d53ed0d9a..acd42833b797 100644 --- a/go.sum +++ b/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/orm/go.mod b/orm/go.mod index a1180672a98c..5149edc3383e 100644 --- a/orm/go.mod +++ b/orm/go.mod @@ -68,3 +68,5 @@ require ( gopkg.in/yaml.v3 v3.0.1 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) + +replace cosmossdk.io/depinject => ../depinject diff --git a/orm/go.sum b/orm/go.sum index 75818fe95b1a..a7f10310c7e2 100644 --- a/orm/go.sum +++ b/orm/go.sum @@ -2,8 +2,6 @@ cosmossdk.io/api v0.7.2 h1:BO3i5fvKMKvfaUiMkCznxViuBEfyWA/k6w2eAF6q1C4= cosmossdk.io/api v0.7.2/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= diff --git a/orm/model/ormdb/module_test.go b/orm/model/ormdb/module_test.go index d224063714f6..a146aa78b825 100644 --- a/orm/model/ormdb/module_test.go +++ b/orm/model/ormdb/module_test.go @@ -16,11 +16,11 @@ import ( appv1alpha1 "cosmossdk.io/api/cosmos/app/v1alpha1" ormmodulev1alpha1 "cosmossdk.io/api/cosmos/orm/module/v1alpha1" ormv1alpha1 "cosmossdk.io/api/cosmos/orm/v1alpha1" - "cosmossdk.io/core/appconfig" - "cosmossdk.io/core/appmodule" "cosmossdk.io/core/genesis" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appconfig" + am "cosmossdk.io/depinject/appmodule" _ "cosmossdk.io/orm" // required for ORM module registration "cosmossdk.io/orm/internal/testkv" "cosmossdk.io/orm/internal/testpb" @@ -36,8 +36,8 @@ import ( func init() { // this registers the test module with the module registry - appmodule.Register(&testpb.Module{}, - appmodule.Provide(NewKeeper), + am.Register(&testpb.Module{}, + am.Provide(NewKeeper), ) } diff --git a/orm/orm.go b/orm/orm.go index c970f2d21af0..c9d7872508b3 100644 --- a/orm/orm.go +++ b/orm/orm.go @@ -10,16 +10,16 @@ import ( appv1alpha1 "cosmossdk.io/api/cosmos/app/v1alpha1" modulev1alpha1 "cosmossdk.io/api/cosmos/orm/module/v1alpha1" ormv1alpha1 "cosmossdk.io/api/cosmos/orm/v1alpha1" - "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/orm/model/ormdb" "cosmossdk.io/orm/model/ormtable" ) func init() { - appmodule.Register(&modulev1alpha1.Module{}, - appmodule.Provide(ProvideModuleDB), + am.Register(&modulev1alpha1.Module{}, + am.Provide(ProvideModuleDB), ) } diff --git a/runtime/app.go b/runtime/app.go index 41746b0b1ed6..9b07970ff428 100644 --- a/runtime/app.go +++ b/runtime/app.go @@ -76,8 +76,8 @@ func (a *App) RegisterModules(modules ...module.AppModule) error { appModule.RegisterInterfaces(a.interfaceRegistry) appModule.RegisterLegacyAminoCodec(a.amino) - if module, ok := appModule.(module.HasServices); ok { - module.RegisterServices(a.configurator) + if mod, ok := appModule.(module.HasServices); ok { + mod.RegisterServices(a.configurator) } else if module, ok := appModule.(appmodule.HasServices); ok { if err := module.RegisterServices(a.configurator); err != nil { return err diff --git a/runtime/module.go b/runtime/module.go index 4440b3b8a314..0c4cbda7da7a 100644 --- a/runtime/module.go +++ b/runtime/module.go @@ -18,6 +18,7 @@ import ( "cosmossdk.io/core/genesis" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/log" storetypes "cosmossdk.io/store/types" "cosmossdk.io/x/tx/signing" @@ -58,8 +59,8 @@ type BaseAppOption func(*baseapp.BaseApp) func (b BaseAppOption) IsManyPerContainerType() {} func init() { - appmodule.Register(&runtimev1alpha1.Module{}, - appmodule.Provide( + am.Register(&runtimev1alpha1.Module{}, + am.Provide( ProvideApp, ProvideInterfaceRegistry, ProvideKVStoreKey, @@ -74,7 +75,7 @@ func init() { ProvideAppVersionModifier, ProvideAddressCodec, ), - appmodule.Invoke(SetupAppBuilder), + am.Invoke(SetupAppBuilder), ) } diff --git a/simapp/app_config.go b/simapp/app_config.go index 4f19426b8198..7994125320c2 100644 --- a/simapp/app_config.go +++ b/simapp/app_config.go @@ -26,8 +26,8 @@ import ( txconfigv1 "cosmossdk.io/api/cosmos/tx/config/v1" upgrademodulev1 "cosmossdk.io/api/cosmos/upgrade/module/v1" vestingmodulev1 "cosmossdk.io/api/cosmos/vesting/module/v1" - "cosmossdk.io/core/appconfig" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appconfig" _ "cosmossdk.io/x/auth/tx/config" // import for side-effects authtypes "cosmossdk.io/x/auth/types" _ "cosmossdk.io/x/auth/vesting" // import for side-effects diff --git a/simapp/go.mod b/simapp/go.mod index b47ec9ca820b..6963edadf888 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -230,6 +230,7 @@ require ( replace ( cosmossdk.io/api => ../api cosmossdk.io/client/v2 => ../client/v2 + cosmossdk.io/depinject => ../depinject cosmossdk.io/tools/confix => ../tools/confix cosmossdk.io/x/accounts => ../x/accounts cosmossdk.io/x/auth => ../x/auth diff --git a/simapp/go.sum b/simapp/go.sum index 4863ae871b14..6a3ef953523c 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -188,8 +188,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/simapp/gomod2nix.toml b/simapp/gomod2nix.toml index 967ec3dbfdf8..c179d412a208 100644 --- a/simapp/gomod2nix.toml +++ b/simapp/gomod2nix.toml @@ -22,9 +22,6 @@ schema = 3 [mod."cosmossdk.io/core"] version = "v0.12.1-0.20231114100755-569e3ff6a0d7" hash = "sha256-I74lq2kZ9hOcvOU4uJZ8LhSoQ0RbgCvAvSXj1xI0iII=" - [mod."cosmossdk.io/depinject"] - version = "v1.0.0-alpha.4" - hash = "sha256-xpLH0K6ivQznFrLw2hmhWIIyYgqjstV47OhTEj/c1oQ=" [mod."cosmossdk.io/errors"] version = "v1.0.0" hash = "sha256-ZD1fhIefk3qkt9I4+ed9NBmBqTDvym9cXWmgFBh5qu0=" diff --git a/tests/go.mod b/tests/go.mod index 256f1f9e3ca8..f74fd5df0c3c 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -222,6 +222,7 @@ require ( replace ( cosmossdk.io/api => ../api cosmossdk.io/client/v2 => ../client/v2 + cosmossdk.io/depinject => ../depinject cosmossdk.io/x/accounts => ../x/accounts cosmossdk.io/x/auth => ../x/auth cosmossdk.io/x/authz => ../x/authz diff --git a/tests/go.sum b/tests/go.sum index 36cbb203601a..0d8a193a5e3d 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -188,8 +188,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/tests/starship/tests/go.mod b/tests/starship/tests/go.mod index c35871ac4bde..37ceefcdeda3 100644 --- a/tests/starship/tests/go.mod +++ b/tests/starship/tests/go.mod @@ -14,6 +14,7 @@ replace ( replace ( cosmossdk.io/api => ../../../api cosmossdk.io/client/v2 => ../../../client/v2 + cosmossdk.io/depinject => ../../../depinject cosmossdk.io/simapp => ../../../simapp cosmossdk.io/x/accounts => ../../../x/accounts cosmossdk.io/x/auth => ../../../x/auth diff --git a/tests/starship/tests/go.sum b/tests/starship/tests/go.sum index 02f8526d6e78..ab255034075c 100644 --- a/tests/starship/tests/go.sum +++ b/tests/starship/tests/go.sum @@ -188,8 +188,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/testutil/configurator/configurator.go b/testutil/configurator/configurator.go index 8a42c5e45aec..336e4ef1459b 100644 --- a/testutil/configurator/configurator.go +++ b/testutil/configurator/configurator.go @@ -23,8 +23,8 @@ import ( stakingmodulev1 "cosmossdk.io/api/cosmos/staking/module/v1" txconfigv1 "cosmossdk.io/api/cosmos/tx/config/v1" vestingmodulev1 "cosmossdk.io/api/cosmos/vesting/module/v1" - "cosmossdk.io/core/appconfig" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appconfig" "github.com/cosmos/cosmos-sdk/testutil" ) diff --git a/x/accounts/go.mod b/x/accounts/go.mod index 10db0942b84f..da29c0247c0f 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -160,6 +160,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. replace ( cosmossdk.io/api => ../../api + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/accounts/go.sum b/x/accounts/go.sum index 40a03db614c8..eb2bd1e4cbf3 100644 --- a/x/accounts/go.sum +++ b/x/accounts/go.sum @@ -4,8 +4,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/auth/go.mod b/x/auth/go.mod index 98730c511089..64fe7439bf95 100644 --- a/x/auth/go.mod +++ b/x/auth/go.mod @@ -166,6 +166,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution cosmossdk.io/x/mint => ../mint diff --git a/x/auth/go.sum b/x/auth/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/auth/go.sum +++ b/x/auth/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/auth/module.go b/x/auth/module.go index f5f5952ed36b..534bcd43e018 100644 --- a/x/auth/module.go +++ b/x/auth/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/x/auth/keeper" "cosmossdk.io/x/auth/simulation" "cosmossdk.io/x/auth/types" @@ -35,6 +36,7 @@ var ( _ module.AppModuleSimulation = AppModule{} _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} ) @@ -173,8 +175,8 @@ func (AppModule) WeightedOperations(_ module.SimulationState) []simtypes.Weighte // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/auth/tx/config/config.go b/x/auth/tx/config/config.go index ca61e53b8e07..30397e33a91e 100644 --- a/x/auth/tx/config/config.go +++ b/x/auth/tx/config/config.go @@ -11,8 +11,8 @@ import ( bankv1beta1 "cosmossdk.io/api/cosmos/bank/v1beta1" txconfigv1 "cosmossdk.io/api/cosmos/tx/config/v1" "cosmossdk.io/core/address" - "cosmossdk.io/core/appmodule" "cosmossdk.io/depinject" + "cosmossdk.io/depinject/appmodule" "cosmossdk.io/x/auth/ante" "cosmossdk.io/x/auth/posthandler" "cosmossdk.io/x/auth/tx" diff --git a/x/auth/vesting/module.go b/x/auth/vesting/module.go index 7dfbe79abe2f..085ef6138713 100644 --- a/x/auth/vesting/module.go +++ b/x/auth/vesting/module.go @@ -11,6 +11,7 @@ import ( modulev1 "cosmossdk.io/api/cosmos/vesting/module/v1" "cosmossdk.io/core/appmodule" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/x/auth/keeper" "cosmossdk.io/x/auth/vesting/client/cli" "cosmossdk.io/x/auth/vesting/types" @@ -25,8 +26,7 @@ var ( _ module.AppModuleBasic = AppModule{} _ module.HasGenesis = AppModule{} - _ appmodule.AppModule = AppModule{} - _ appmodule.HasServices = AppModule{} + _ appmodule.AppModule = AppModule{} ) // AppModuleBasic defines the basic application module used by the sub-vesting @@ -114,8 +114,8 @@ func (AppModule) ConsensusVersion() uint64 { return 1 } // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/authz/go.mod b/x/authz/go.mod index 41cf7be7f757..d8cfca3d490e 100644 --- a/x/authz/go.mod +++ b/x/authz/go.mod @@ -172,6 +172,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( cosmossdk.io/api => ../../api + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/authz/go.sum b/x/authz/go.sum index 12fdb7432932..4d5002c86be7 100644 --- a/x/authz/go.sum +++ b/x/authz/go.sum @@ -4,8 +4,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/authz/module/module.go b/x/authz/module/module.go index 16a7f7e440d7..62156ebe8739 100644 --- a/x/authz/module/module.go +++ b/x/authz/module/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/errors" "cosmossdk.io/x/authz" "cosmossdk.io/x/authz/client/cli" @@ -31,6 +32,7 @@ var ( _ module.AppModuleSimulation = AppModule{} _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasBeginBlocker = AppModule{} @@ -147,9 +149,9 @@ func (am AppModule) BeginBlock(ctx context.Context) error { } func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/bank/go.mod b/x/bank/go.mod index d450ebf3aa3a..ccda0c7807ad 100644 --- a/x/bank/go.mod +++ b/x/bank/go.mod @@ -165,6 +165,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/distribution => ../distribution cosmossdk.io/x/mint => ../mint diff --git a/x/bank/go.sum b/x/bank/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/bank/go.sum +++ b/x/bank/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/bank/module.go b/x/bank/module.go index 67889d2a5dfd..1d0c56ee76bb 100644 --- a/x/bank/module.go +++ b/x/bank/module.go @@ -13,6 +13,7 @@ import ( "cosmossdk.io/core/appmodule" corestore "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/log" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/bank/client/cli" @@ -38,6 +39,7 @@ var ( _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} _ module.HasInvariants = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} ) @@ -187,8 +189,8 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // App Wiring Setup func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/circuit/go.mod b/x/circuit/go.mod index 474060ba6abc..284bb521d596 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -165,6 +165,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/circuit/go.sum b/x/circuit/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/circuit/module.go b/x/circuit/module.go index bfbc4d3dc73f..667a1fd9700a 100644 --- a/x/circuit/module.go +++ b/x/circuit/module.go @@ -13,6 +13,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/circuit/keeper" "cosmossdk.io/x/circuit/types" @@ -126,9 +127,9 @@ func (am AppModule) ExportGenesis(ctx context.Context, cdc codec.JSONCodec) json } func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/consensus/module.go b/x/consensus/module.go index 7091e5f80bcb..03c5edc1106a 100644 --- a/x/consensus/module.go +++ b/x/consensus/module.go @@ -11,6 +11,7 @@ import ( "cosmossdk.io/core/event" storetypes "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "github.com/cosmos/cosmos-sdk/baseapp" @@ -29,8 +30,7 @@ const ConsensusVersion = 1 var ( _ module.AppModuleBasic = AppModule{} - _ appmodule.AppModule = AppModule{} - _ appmodule.HasServices = AppModule{} + _ appmodule.AppModule = AppModule{} ) // AppModuleBasic defines the basic application module used by the consensus module. @@ -90,9 +90,9 @@ func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/counter/module.go b/x/counter/module.go index 6c14ff2e5aeb..fae00c214081 100644 --- a/x/counter/module.go +++ b/x/counter/module.go @@ -9,6 +9,7 @@ import ( "cosmossdk.io/core/event" storetypes "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" @@ -21,8 +22,7 @@ import ( var ( _ module.AppModuleBasic = AppModule{} - _ appmodule.AppModule = AppModule{} - _ appmodule.HasServices = AppModule{} + _ appmodule.AppModule = AppModule{} ) // AppModuleBasic defines the basic application module used by the consensus module. @@ -74,9 +74,9 @@ func NewAppModule(keeper keeper.Keeper) AppModule { func (AppModule) ConsensusVersion() uint64 { return 1 } func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/crisis/module.go b/x/crisis/module.go index 1dfdb01499d0..6fee91a29ffb 100644 --- a/x/crisis/module.go +++ b/x/crisis/module.go @@ -15,6 +15,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "github.com/cosmos/cosmos-sdk/client" @@ -163,9 +164,9 @@ func (am AppModule) EndBlock(ctx context.Context) error { // App Wiring Setup func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/distribution/go.mod b/x/distribution/go.mod index fb1d08e7d8f0..cfdfdbcbd552 100644 --- a/x/distribution/go.mod +++ b/x/distribution/go.mod @@ -167,6 +167,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/mint => ../mint diff --git a/x/distribution/go.sum b/x/distribution/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/distribution/go.sum +++ b/x/distribution/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/distribution/module.go b/x/distribution/module.go index caa441ee2cb6..690ed300d2e7 100644 --- a/x/distribution/module.go +++ b/x/distribution/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/distribution/client/cli" "cosmossdk.io/x/distribution/keeper" @@ -36,6 +37,7 @@ var ( _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} _ module.HasInvariants = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasBeginBlocker = AppModule{} @@ -199,8 +201,8 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/evidence/go.mod b/x/evidence/go.mod index e9dadaaf1f4f..1f9fe02fea15 100644 --- a/x/evidence/go.mod +++ b/x/evidence/go.mod @@ -167,6 +167,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/evidence/go.sum b/x/evidence/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/evidence/go.sum +++ b/x/evidence/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/evidence/module.go b/x/evidence/module.go index e72a562cee09..3f5ff820a6ad 100644 --- a/x/evidence/module.go +++ b/x/evidence/module.go @@ -14,6 +14,7 @@ import ( "cosmossdk.io/core/appmodule" store "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" eviclient "cosmossdk.io/x/evidence/client" "cosmossdk.io/x/evidence/client/cli" "cosmossdk.io/x/evidence/keeper" @@ -33,7 +34,6 @@ var ( _ module.HasGenesis = AppModule{} _ appmodule.AppModule = AppModule{} - _ appmodule.HasServices = AppModule{} _ appmodule.HasBeginBlocker = AppModule{} ) @@ -180,8 +180,8 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/feegrant/go.mod b/x/feegrant/go.mod index 6aa36cacbbdb..4062ab71cb0b 100644 --- a/x/feegrant/go.mod +++ b/x/feegrant/go.mod @@ -169,6 +169,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/feegrant/go.sum b/x/feegrant/go.sum index 0a913cb49f9b..3cfefc2a7f0f 100644 --- a/x/feegrant/go.sum +++ b/x/feegrant/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/feegrant/module/module.go b/x/feegrant/module/module.go index 97f30b7ef029..a76a0f835bd3 100644 --- a/x/feegrant/module/module.go +++ b/x/feegrant/module/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/errors" "cosmossdk.io/x/feegrant" "cosmossdk.io/x/feegrant/client/cli" @@ -30,6 +31,7 @@ var ( _ module.AppModuleSimulation = AppModule{} _ module.HasServices = AppModule{} _ module.HasGenesis = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasEndBlocker = AppModule{} @@ -163,8 +165,8 @@ func (am AppModule) EndBlock(ctx context.Context) error { } func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/genutil/module.go b/x/genutil/module.go index 4959c8692f62..403838dddae9 100644 --- a/x/genutil/module.go +++ b/x/genutil/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/genesis" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" @@ -120,8 +121,8 @@ func (am AppModule) ExportGenesis(_ context.Context, cdc codec.JSONCodec) json.R func (AppModule) ConsensusVersion() uint64 { return 1 } func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/gov/go.mod b/x/gov/go.mod index 7d82c8fb0b36..1493b02322f5 100644 --- a/x/gov/go.mod +++ b/x/gov/go.mod @@ -169,6 +169,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. replace ( cosmossdk.io/api => ../../api + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/gov/go.sum b/x/gov/go.sum index 12fdb7432932..4d5002c86be7 100644 --- a/x/gov/go.sum +++ b/x/gov/go.sum @@ -4,8 +4,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/gov/module.go b/x/gov/module.go index 7eb791dc4bff..f6b1750a7b55 100644 --- a/x/gov/module.go +++ b/x/gov/module.go @@ -17,6 +17,7 @@ import ( "cosmossdk.io/core/appmodule" store "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" govclient "cosmossdk.io/x/gov/client" "cosmossdk.io/x/gov/client/cli" @@ -151,10 +152,10 @@ func (am AppModule) IsOnePerModuleType() {} func (am AppModule) IsAppModule() {} func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Invoke(InvokeAddRoutes, InvokeSetHooks), - appmodule.Provide(ProvideModule)) + am.Invoke(InvokeAddRoutes, InvokeSetHooks), + am.Provide(ProvideModule)) } type ModuleInputs struct { diff --git a/x/group/go.mod b/x/group/go.mod index 7fec2fc9b458..256129927946 100644 --- a/x/group/go.mod +++ b/x/group/go.mod @@ -172,6 +172,7 @@ replace github.com/cosmos/cosmos-sdk => ../../ replace ( cosmossdk.io/api => ../../api + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/authz => ../authz cosmossdk.io/x/bank => ../bank diff --git a/x/group/go.sum b/x/group/go.sum index 468ae76a8a8e..5f7b1ee5486d 100644 --- a/x/group/go.sum +++ b/x/group/go.sum @@ -4,8 +4,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/group/module/module.go b/x/group/module/module.go index 53938c4879cc..7ce3c2ed217f 100644 --- a/x/group/module/module.go +++ b/x/group/module/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/address" "cosmossdk.io/core/appmodule" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" store "cosmossdk.io/store/types" "cosmossdk.io/x/group" "cosmossdk.io/x/group/client/cli" @@ -36,6 +37,7 @@ var ( _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} _ module.HasInvariants = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasEndBlocker = AppModule{} @@ -180,9 +182,9 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/mint/go.mod b/x/mint/go.mod index 9c66386da001..dfbe0cfffc6e 100644 --- a/x/mint/go.mod +++ b/x/mint/go.mod @@ -166,6 +166,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/mint/go.sum b/x/mint/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/mint/go.sum +++ b/x/mint/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/mint/module.go b/x/mint/module.go index a28640f2df49..4af6eeaa349f 100644 --- a/x/mint/module.go +++ b/x/mint/module.go @@ -11,6 +11,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/mint/keeper" "cosmossdk.io/x/mint/simulation" @@ -31,6 +32,7 @@ var ( _ module.AppModuleSimulation = AppModule{} _ module.HasGenesis = AppModule{} _ module.HasServices = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasBeginBlocker = AppModule{} @@ -181,8 +183,8 @@ func (AppModule) WeightedOperations(_ module.SimulationState) []simtypes.Weighte // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/nft/go.mod b/x/nft/go.mod index 451da701f726..4077646eacd6 100644 --- a/x/nft/go.mod +++ b/x/nft/go.mod @@ -166,6 +166,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/nft/go.sum b/x/nft/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/nft/go.sum +++ b/x/nft/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/nft/module/module.go b/x/nft/module/module.go index e1099c4e7c4d..79cc78dff3aa 100644 --- a/x/nft/module/module.go +++ b/x/nft/module/module.go @@ -12,6 +12,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" "cosmossdk.io/errors" "cosmossdk.io/x/nft" "cosmossdk.io/x/nft/keeper" @@ -29,8 +30,7 @@ var ( _ module.AppModuleSimulation = AppModule{} _ module.HasGenesis = AppModule{} - _ appmodule.AppModule = AppModule{} - _ appmodule.HasServices = AppModule{} + _ appmodule.AppModule = AppModule{} ) // AppModuleBasic defines the basic application module used by the nft module. @@ -156,8 +156,8 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), ) } diff --git a/x/params/go.mod b/x/params/go.mod index 35874b5f3e5b..5ae0f3f3ad68 100644 --- a/x/params/go.mod +++ b/x/params/go.mod @@ -166,6 +166,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../.. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/params/go.sum b/x/params/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/params/go.sum +++ b/x/params/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/params/module.go b/x/params/module.go index 44cb81cdfbbb..13ee912d94f8 100644 --- a/x/params/module.go +++ b/x/params/module.go @@ -8,6 +8,7 @@ import ( modulev1 "cosmossdk.io/api/cosmos/params/module/v1" "cosmossdk.io/core/appmodule" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" store "cosmossdk.io/store/types" govv1beta1 "cosmossdk.io/x/gov/types/v1beta1" "cosmossdk.io/x/params/keeper" @@ -25,6 +26,7 @@ var ( _ module.AppModuleBasic = AppModule{} _ module.AppModuleSimulation = AppModule{} _ module.HasServices = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} ) @@ -102,8 +104,8 @@ func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide( + am.Register(&modulev1.Module{}, + am.Provide( ProvideModule, ProvideSubspace, )) diff --git a/x/protocolpool/go.mod b/x/protocolpool/go.mod index 53e092ecd1c9..11e333aa7841 100644 --- a/x/protocolpool/go.mod +++ b/x/protocolpool/go.mod @@ -167,6 +167,7 @@ require ( replace github.com/cosmos/cosmos-sdk => ../../. replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/protocolpool/go.sum b/x/protocolpool/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/protocolpool/go.sum +++ b/x/protocolpool/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/protocolpool/module.go b/x/protocolpool/module.go index bb6c43eb7c95..0afb3b152a70 100644 --- a/x/protocolpool/module.go +++ b/x/protocolpool/module.go @@ -9,6 +9,7 @@ import ( "cosmossdk.io/core/appmodule" storetypes "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/protocolpool/keeper" "cosmossdk.io/x/protocolpool/simulation" @@ -97,9 +98,9 @@ func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } // func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/slashing/go.mod b/x/slashing/go.mod index 21e660eb5df5..27acc250661b 100644 --- a/x/slashing/go.mod +++ b/x/slashing/go.mod @@ -170,6 +170,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/slashing/go.sum b/x/slashing/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/slashing/go.sum +++ b/x/slashing/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/slashing/module.go b/x/slashing/module.go index c758d8fbef71..6a984253745d 100644 --- a/x/slashing/module.go +++ b/x/slashing/module.go @@ -11,6 +11,7 @@ import ( "cosmossdk.io/core/appmodule" store "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/slashing/keeper" "cosmossdk.io/x/slashing/simulation" @@ -187,9 +188,9 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp // func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), + am.Provide(ProvideModule), ) } diff --git a/x/staking/go.mod b/x/staking/go.mod index 243e228399cb..f6e8fecc8545 100644 --- a/x/staking/go.mod +++ b/x/staking/go.mod @@ -170,6 +170,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO remove post spinning out all modules replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/staking/go.sum b/x/staking/go.sum index ff10a22331dd..5701bb7ea52e 100644 --- a/x/staking/go.sum +++ b/x/staking/go.sum @@ -6,8 +6,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/staking/module.go b/x/staking/module.go index 82fd4d533f64..333d89d53b05 100644 --- a/x/staking/module.go +++ b/x/staking/module.go @@ -15,6 +15,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/staking/client/cli" "cosmossdk.io/x/staking/keeper" @@ -41,6 +42,7 @@ var ( _ module.HasInvariants = AppModule{} _ module.HasABCIGenesis = AppModule{} _ module.HasABCIEndBlock = AppModule{} + _ depinject.OnePerModuleType = AppModule{} _ appmodule.AppModule = AppModule{} _ appmodule.HasBeginBlocker = AppModule{} @@ -180,10 +182,10 @@ func (am AppModule) EndBlock(ctx context.Context) ([]abci.ValidatorUpdate, error } func init() { - appmodule.Register( + am.Register( &modulev1.Module{}, - appmodule.Provide(ProvideModule), - appmodule.Invoke(InvokeSetStakingHooks), + am.Provide(ProvideModule), + am.Invoke(InvokeSetStakingHooks), ) } diff --git a/x/upgrade/go.mod b/x/upgrade/go.mod index b6e1f77fdc75..e953879c6efb 100644 --- a/x/upgrade/go.mod +++ b/x/upgrade/go.mod @@ -196,6 +196,7 @@ replace github.com/cosmos/cosmos-sdk => ../../. // TODO Remove it: https://github.com/cosmos/cosmos-sdk/issues/10409 replace ( + cosmossdk.io/depinject => ../../depinject cosmossdk.io/x/auth => ../auth cosmossdk.io/x/bank => ../bank cosmossdk.io/x/distribution => ../distribution diff --git a/x/upgrade/go.sum b/x/upgrade/go.sum index ea3ac7a1d998..ed4034e9e006 100644 --- a/x/upgrade/go.sum +++ b/x/upgrade/go.sum @@ -190,8 +190,6 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= diff --git a/x/upgrade/module.go b/x/upgrade/module.go index 7a0014178c56..e821a4d8faa5 100644 --- a/x/upgrade/module.go +++ b/x/upgrade/module.go @@ -14,6 +14,7 @@ import ( "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" "cosmossdk.io/depinject" + am "cosmossdk.io/depinject/appmodule" authtypes "cosmossdk.io/x/auth/types" "cosmossdk.io/x/upgrade/client/cli" "cosmossdk.io/x/upgrade/keeper" @@ -165,9 +166,9 @@ func (am AppModule) PreBlock(ctx context.Context) (appmodule.ResponsePreBlock, e // func init() { - appmodule.Register(&modulev1.Module{}, - appmodule.Provide(ProvideModule), - appmodule.Invoke(PopulateVersionMap), + am.Register(&modulev1.Module{}, + am.Provide(ProvideModule), + am.Invoke(PopulateVersionMap), ) } From e2d76b3078ec36229e2917af299d8db48ab5474a Mon Sep 17 00:00:00 2001 From: Aleksandr Bezobchuk Date: Tue, 9 Jan 2024 10:38:24 -0500 Subject: [PATCH 09/28] feat(store/v2): Modify RootStore to Support Multi StoreKeys (#18968) --- store/changeset.go | 26 ++++-- store/commitment/store_test_suite.go | 2 +- store/kv/branch/store.go | 10 ++- store/kv/branch/store_test.go | 2 +- store/kv/mem/store.go | 2 +- store/pruning/manager_test.go | 2 +- store/root/store.go | 101 +++++++++++++----------- store/root/store_test.go | 114 ++++----------------------- store/storage/storage_bench_test.go | 6 +- store/storage/storage_test_suite.go | 32 ++++---- 10 files changed, 120 insertions(+), 177 deletions(-) diff --git a/store/changeset.go b/store/changeset.go index 6982344375af..7c5d88a864a3 100644 --- a/store/changeset.go +++ b/store/changeset.go @@ -11,13 +11,19 @@ type KVPair struct { type KVPairs []KVPair -// Changeset defines a set of KVPair entries by maintaining a map -// from store key to a slice of KVPair objects. +// Changeset defines a set of KVPair entries by maintaining a map from store key +// to a slice of KVPair objects. type Changeset struct { Pairs map[string]KVPairs } -func NewChangeset(pairs map[string]KVPairs) *Changeset { +func NewChangeset() *Changeset { + return &Changeset{ + Pairs: make(map[string]KVPairs), + } +} + +func NewChangesetWithPairs(pairs map[string]KVPairs) *Changeset { return &Changeset{ Pairs: pairs, } @@ -36,8 +42,9 @@ func (cs *Changeset) Size() int { // Add adds a key-value pair to the ChangeSet. func (cs *Changeset) Add(storeKey string, key, value []byte) { cs.Pairs[storeKey] = append(cs.Pairs[storeKey], KVPair{ - Key: key, - Value: value, + Key: key, + Value: value, + StoreKey: storeKey, }) } @@ -45,3 +52,12 @@ func (cs *Changeset) Add(storeKey string, key, value []byte) { func (cs *Changeset) AddKVPair(storeKey string, pair KVPair) { cs.Pairs[storeKey] = append(cs.Pairs[storeKey], pair) } + +// Merge merges the provided Changeset argument into the receiver. This may be +// useful when you have a Changeset that only pertains to a single store key, +// i.e. a map of size one, and you want to merge it into another. +func (cs *Changeset) Merge(other *Changeset) { + for storeKey, pairs := range other.Pairs { + cs.Pairs[storeKey] = append(cs.Pairs[storeKey], pairs...) + } +} diff --git a/store/commitment/store_test_suite.go b/store/commitment/store_test_suite.go index 370958cb3f10..6c0a56914836 100644 --- a/store/commitment/store_test_suite.go +++ b/store/commitment/store_test_suite.go @@ -43,7 +43,7 @@ func (s *CommitStoreTestSuite) TestSnapshotter() { kvPairs[storeKey] = append(kvPairs[storeKey], store.KVPair{Key: key, Value: value}) } } - s.Require().NoError(commitStore.WriteBatch(store.NewChangeset(kvPairs))) + s.Require().NoError(commitStore.WriteBatch(store.NewChangesetWithPairs(kvPairs))) _, err = commitStore.Commit() s.Require().NoError(err) diff --git a/store/kv/branch/store.go b/store/kv/branch/store.go index 98416a9655c1..4322d46a04f9 100644 --- a/store/kv/branch/store.go +++ b/store/kv/branch/store.go @@ -34,7 +34,8 @@ type Store struct { // parent reflects a parent store if branched (it may be nil) parent store.KVStore - // changeset reflects the uncommitted writes to the store + // changeset reflects the uncommitted writes to the store as it contains a mapping + // from key to a KVPair. changeset map[string]store.KVPair } @@ -77,12 +78,13 @@ func (s *Store) GetChangeset() *store.Changeset { for i, key := range keys { kvPair := s.changeset[key] pairs[i] = store.KVPair{ - Key: []byte(key), - Value: slices.Clone(kvPair.Value), + Key: []byte(key), + Value: slices.Clone(kvPair.Value), + StoreKey: s.storeKey, } } - return store.NewChangeset(map[string]store.KVPairs{s.storeKey: pairs}) + return store.NewChangesetWithPairs(map[string]store.KVPairs{s.storeKey: pairs}) } func (s *Store) Reset(toVersion uint64) error { diff --git a/store/kv/branch/store_test.go b/store/kv/branch/store_test.go index 0d3ffffd3ecb..ada3b8aa0ff5 100644 --- a/store/kv/branch/store_test.go +++ b/store/kv/branch/store_test.go @@ -30,7 +30,7 @@ func (s *StoreTestSuite) SetupTest() { ss := storage.NewStorageStore(sqliteDB) s.Require().NoError(err) - cs := store.NewChangeset(map[string]store.KVPairs{storeKey: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey: {}}) for i := 0; i < 100; i++ { key := fmt.Sprintf("key%03d", i) // key000, key001, ..., key099 val := fmt.Sprintf("val%03d", i) // val000, val001, ..., val099 diff --git a/store/kv/mem/store.go b/store/kv/mem/store.go index 4e3a1dbb8e87..5db8b90a5b27 100644 --- a/store/kv/mem/store.go +++ b/store/kv/mem/store.go @@ -85,7 +85,7 @@ func (s *Store) GetChangeset() *store.Changeset { }) } - return store.NewChangeset(map[string]store.KVPairs{s.storeKey: kvPairs}) + return store.NewChangesetWithPairs(map[string]store.KVPairs{s.storeKey: kvPairs}) } func (s *Store) Reset(_ uint64) error { diff --git a/store/pruning/manager_test.go b/store/pruning/manager_test.go index 65e7fe1b09ec..b3b4ce9b838b 100644 --- a/store/pruning/manager_test.go +++ b/store/pruning/manager_test.go @@ -64,7 +64,7 @@ func (s *PruningTestSuite) TestPruning() { for i := uint64(0); i < latestVersion; i++ { version := i + 1 - cs := store.NewChangeset(map[string]store.KVPairs{defaultStoreKey: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{defaultStoreKey: {}}) cs.AddKVPair(defaultStoreKey, store.KVPair{ Key: []byte("key"), Value: []byte(fmt.Sprintf("value%d", version)), diff --git a/store/root/store.go b/store/root/store.go index 4904184f23a7..386fd0e1bdce 100644 --- a/store/root/store.go +++ b/store/root/store.go @@ -18,11 +18,6 @@ import ( "cosmossdk.io/store/v2/pruning" ) -// defaultStoreKey defines the default store key used for the single SC backend. -// Note, however, this store key is essentially irrelevant as it's not exposed -// to the user and it only needed to fulfill usage of StoreInfo during Commit. -const defaultStoreKey = "default" - var _ store.RootStore = (*Store)(nil) // Store defines the SDK's default RootStore implementation. It contains a single @@ -39,9 +34,10 @@ type Store struct { // stateCommitment reflects the state commitment (SC) backend stateCommitment store.Committer - // rootKVStore reflects the root BranchedKVStore that is used to accumulate writes + // kvStores reflects a mapping of store keys, typically dedicated to modules, + // to a dedicated BranchedKVStore. Each store is used to accumulate writes // and branch off of. - rootKVStore store.BranchedKVStore + kvStores map[string]store.BranchedKVStore // commitHeader reflects the header used when committing state (note, this isn't required and only used for query purposes) commitHeader *coreheader.Info @@ -69,12 +65,18 @@ func New( logger log.Logger, ss store.VersionedDatabase, sc store.Committer, + storeKeys []string, ssOpts, scOpts pruning.Options, m metrics.StoreMetrics, ) (store.RootStore, error) { - rootKVStore, err := branch.New(defaultStoreKey, ss) - if err != nil { - return nil, err + kvStores := make(map[string]store.BranchedKVStore, len(storeKeys)) + for _, storeKey := range storeKeys { + bkv, err := branch.New(storeKey, ss) + if err != nil { + return nil, err + } + + kvStores[storeKey] = bkv } pruningManager := pruning.NewManager(logger, ss, sc) @@ -87,7 +89,7 @@ func New( initialVersion: 1, stateStore: ss, stateCommitment: sc, - rootKVStore: rootKVStore, + kvStores: kvStores, pruningManager: pruningManager, telemetry: m, }, nil @@ -196,24 +198,28 @@ func (s *Store) Query(storeKey string, version uint64, key []byte, prove bool) ( return result, nil } -// GetKVStore returns the store's root KVStore. Any writes to this store without -// branching will be committed to SC and SS upon Commit(). Branching will create +// GetKVStore returns a KVStore for the given store key. Any writes to this store +// without branching will be committed to SC and SS upon Commit(). Branching will create // a branched KVStore that allow writes to be discarded and propagated to the // root KVStore using Write(). -func (s *Store) GetKVStore(_ string) store.KVStore { - if s.TracingEnabled() { - return trace.New(s.rootKVStore, s.traceWriter, s.traceContext) +func (s *Store) GetKVStore(storeKey string) store.KVStore { + bkv, ok := s.kvStores[storeKey] + if !ok { + panic(fmt.Sprintf("unknown store key: %s", storeKey)) } - return s.rootKVStore -} - -func (s *Store) GetBranchedKVStore(_ string) store.BranchedKVStore { if s.TracingEnabled() { - return trace.New(s.rootKVStore, s.traceWriter, s.traceContext) + return trace.New(bkv, s.traceWriter, s.traceContext) } - return s.rootKVStore + return bkv +} + +func (s *Store) GetBranchedKVStore(storeKey string) store.BranchedKVStore { + // Branching will soon be removed. + // + // Ref: https://github.com/cosmos/cosmos-sdk/issues/18981 + panic("TODO: WILL BE REMOVED!") } func (s *Store) LoadLatestVersion() error { @@ -242,10 +248,12 @@ func (s *Store) LoadVersion(version uint64) error { func (s *Store) loadVersion(v uint64) error { s.logger.Debug("loading version", "version", v) - // Reset the root KVStore s.t. the latest version is v. Any writes will - // overwrite existing versions. - if err := s.rootKVStore.Reset(v); err != nil { - return err + // Reset each KVStore s.t. the latest version is v. Any writes will overwrite + // existing versions. + for storeKey, kvStore := range s.kvStores { + if err := kvStore.Reset(v); err != nil { + return fmt.Errorf("failed to reset %s KVStore: %w", storeKey, err) + } } if err := s.stateCommitment.LoadVersion(v); err != nil { @@ -277,22 +285,11 @@ func (s *Store) SetCommitHeader(h *coreheader.Info) { s.commitHeader = h } -// Branch a copy of the Store with a branched underlying root KVStore. Any call -// to GetKVStore and GetBranchedKVStore returns the branched KVStore. func (s *Store) Branch() store.BranchedRootStore { - branch := s.rootKVStore.Branch() - - return &Store{ - logger: s.logger, - initialVersion: s.initialVersion, - stateStore: s.stateStore, - stateCommitment: s.stateCommitment, - rootKVStore: branch, - commitHeader: s.commitHeader, - lastCommitInfo: s.lastCommitInfo, - traceWriter: s.traceWriter, - traceContext: s.traceContext, - } + // Branching will soon be removed. + // + // Ref: https://github.com/cosmos/cosmos-sdk/issues/18981 + panic("TODO: WILL BE REMOVED!") } // WorkingHash returns the working hash of the root store. Note, WorkingHash() @@ -320,7 +317,9 @@ func (s *Store) WorkingHash() ([]byte, error) { } func (s *Store) Write() { - s.rootKVStore.Write() + for _, kvStore := range s.kvStores { + kvStore.Write() + } } // Commit commits all state changes to the underlying SS and SC backends. Note, @@ -347,7 +346,10 @@ func (s *Store) Commit() ([]byte, error) { s.logger.Debug("commit header and version mismatch", "header_height", s.commitHeader.Height, "version", version) } - changeset := s.rootKVStore.GetChangeset() + changeset := store.NewChangeset() + for _, kvStore := range s.kvStores { + changeset.Merge(kvStore.GetChangeset()) + } // commit SS if err := s.stateStore.ApplyChangeset(version, changeset); err != nil { @@ -363,8 +365,10 @@ func (s *Store) Commit() ([]byte, error) { s.lastCommitInfo.Timestamp = s.commitHeader.Time } - if err := s.rootKVStore.Reset(version); err != nil { - return nil, fmt.Errorf("failed to reset root KVStore: %w", err) + for storeKey, kvStore := range s.kvStores { + if err := kvStore.Reset(version); err != nil { + return nil, fmt.Errorf("failed to reset %s KVStore: %w", storeKey, err) + } } s.workingHash = nil @@ -380,9 +384,12 @@ func (s *Store) Commit() ([]byte, error) { // of the SC tree. Finally, we construct a *CommitInfo and return the hash. // Note, this should only be called once per block! func (s *Store) writeSC() error { - changeSet := s.rootKVStore.GetChangeset() + changeset := store.NewChangeset() + for _, kvStore := range s.kvStores { + changeset.Merge(kvStore.GetChangeset()) + } - if err := s.stateCommitment.WriteBatch(changeSet); err != nil { + if err := s.stateCommitment.WriteBatch(changeset); err != nil { return fmt.Errorf("failed to write batch to SC store: %w", err) } diff --git a/store/root/store_test.go b/store/root/store_test.go index 9bb17dca0345..9d5d69771808 100644 --- a/store/root/store_test.go +++ b/store/root/store_test.go @@ -17,6 +17,10 @@ import ( "cosmossdk.io/store/v2/storage/sqlite" ) +const ( + testStoreKey = "test" +) + type RootStoreTestSuite struct { suite.Suite @@ -35,10 +39,10 @@ func (s *RootStoreTestSuite) SetupTest() { ss := storage.NewStorageStore(sqliteDB) tree := iavl.NewIavlTree(dbm.NewMemDB(), noopLog, iavl.DefaultConfig()) - sc, err := commitment.NewCommitStore(map[string]commitment.Tree{defaultStoreKey: tree}, noopLog) + sc, err := commitment.NewCommitStore(map[string]commitment.Tree{testStoreKey: tree}, noopLog) s.Require().NoError(err) - rs, err := New(noopLog, ss, sc, pruning.DefaultOptions(), pruning.DefaultOptions(), nil) + rs, err := New(noopLog, ss, sc, []string{testStoreKey}, pruning.DefaultOptions(), pruning.DefaultOptions(), nil) s.Require().NoError(err) rs.SetTracer(io.Discard) @@ -59,22 +63,16 @@ func (s *RootStoreTestSuite) TestGetSCStore() { } func (s *RootStoreTestSuite) TestGetKVStore() { - kvs := s.rootStore.GetKVStore("") + kvs := s.rootStore.GetKVStore(testStoreKey) s.Require().NotNil(kvs) } -func (s *RootStoreTestSuite) TestGetBranchedKVStore() { - bs := s.rootStore.GetBranchedKVStore("") - s.Require().NotNil(bs) - s.Require().Empty(bs.GetChangeset().Size()) -} - func (s *RootStoreTestSuite) TestQuery() { _, err := s.rootStore.Query("", 1, []byte("foo"), true) s.Require().Error(err) // write and commit a changeset - bs := s.rootStore.GetBranchedKVStore("") + bs := s.rootStore.GetKVStore(testStoreKey) bs.Set([]byte("foo"), []byte("bar")) workingHash, err := s.rootStore.WorkingHash() @@ -87,51 +85,17 @@ func (s *RootStoreTestSuite) TestQuery() { s.Require().Equal(workingHash, commitHash) // ensure the proof is non-nil for the corresponding version - result, err := s.rootStore.Query(defaultStoreKey, 1, []byte("foo"), true) + result, err := s.rootStore.Query(testStoreKey, 1, []byte("foo"), true) s.Require().NoError(err) s.Require().NotNil(result.Proof.Proof) s.Require().Equal([]byte("foo"), result.Proof.Proof.GetExist().Key) s.Require().Equal([]byte("bar"), result.Proof.Proof.GetExist().Value) } -func (s *RootStoreTestSuite) TestBranch() { - // write and commit a changeset - bs := s.rootStore.GetKVStore("") - bs.Set([]byte("foo"), []byte("bar")) - - workingHash, err := s.rootStore.WorkingHash() - s.Require().NoError(err) - s.Require().NotNil(workingHash) - - commitHash, err := s.rootStore.Commit() - s.Require().NoError(err) - s.Require().NotNil(commitHash) - s.Require().Equal(workingHash, commitHash) - - // branch the root store - rs2 := s.rootStore.Branch() - - // ensure we can perform reads which pass through to the original root store - bs2 := rs2.GetKVStore("") - s.Require().Equal([]byte("bar"), bs2.Get([]byte("foo"))) - - // make a change to the branched root store - bs2.Set([]byte("foo"), []byte("updated_bar")) - - // ensure the original root store is not modified - s.Require().Equal([]byte("bar"), bs.Get([]byte("foo"))) - - // write changes - rs2.Write() - - // ensure changes are reflected in the original root store - s.Require().Equal([]byte("updated_bar"), bs.Get([]byte("foo"))) -} - func (s *RootStoreTestSuite) TestLoadVersion() { // write and commit a few changesets for v := 1; v <= 5; v++ { - bs := s.rootStore.GetBranchedKVStore("") + bs := s.rootStore.GetKVStore(testStoreKey) val := fmt.Sprintf("val%03d", v) // val001, val002, ..., val005 bs.Set([]byte("key"), []byte(val)) @@ -164,13 +128,13 @@ func (s *RootStoreTestSuite) TestLoadVersion() { s.Require().Equal(uint64(3), latest) // query state and ensure values returned are based on the loaded version - kvStore := s.rootStore.GetKVStore("") + kvStore := s.rootStore.GetKVStore(testStoreKey) val := kvStore.Get([]byte("key")) s.Require().Equal([]byte("val003"), val) // attempt to write and commit a few changesets for v := 4; v <= 5; v++ { - bs := s.rootStore.GetBranchedKVStore("") + bs := s.rootStore.GetKVStore(testStoreKey) val := fmt.Sprintf("overwritten_val%03d", v) // overwritten_val004, overwritten_val005 bs.Set([]byte("key"), []byte(val)) @@ -190,61 +154,18 @@ func (s *RootStoreTestSuite) TestLoadVersion() { s.Require().Equal(uint64(5), latest) // query state and ensure values returned are based on the loaded version - kvStore = s.rootStore.GetKVStore("") + kvStore = s.rootStore.GetKVStore(testStoreKey) val = kvStore.Get([]byte("key")) s.Require().Equal([]byte("overwritten_val005"), val) } -func (s *RootStoreTestSuite) TestMultiBranch() { - // write and commit a changeset - bs := s.rootStore.GetKVStore("") - bs.Set([]byte("foo"), []byte("bar")) - - workingHash, err := s.rootStore.WorkingHash() - s.Require().NoError(err) - s.Require().NotNil(workingHash) - - commitHash, err := s.rootStore.Commit() - s.Require().NoError(err) - s.Require().NotNil(commitHash) - s.Require().Equal(workingHash, commitHash) - - // create multiple branches of the root store - var branchedRootStores []store.BranchedRootStore - for i := 0; i < 5; i++ { - branchedRootStores = append(branchedRootStores, s.rootStore.Branch()) - } - - // get the last branched root store - rs2 := branchedRootStores[4] - - // ensure we can perform reads which pass through to the original root store - bs2 := rs2.GetKVStore("") - s.Require().Equal([]byte("bar"), bs2.Get([]byte("foo"))) - - // make a change to the branched root store - bs2.Set([]byte("foo"), []byte("updated_bar")) - - // ensure the original root store is not modified - s.Require().Equal([]byte("bar"), bs.Get([]byte("foo"))) - - // write changes - rs2.Write() - - // ensure changes are reflected in the original root store - s.Require().Equal([]byte("updated_bar"), bs.Get([]byte("foo"))) -} - func (s *RootStoreTestSuite) TestCommit() { lv, err := s.rootStore.GetLatestVersion() s.Require().NoError(err) s.Require().Zero(lv) - // branch the root store - rs2 := s.rootStore.Branch() - // perform changes - bs2 := rs2.GetKVStore("") + bs2 := s.rootStore.GetKVStore(testStoreKey) for i := 0; i < 100; i++ { key := fmt.Sprintf("key%03d", i) // key000, key001, ..., key099 val := fmt.Sprintf("val%03d", i) // val000, val001, ..., val099 @@ -252,9 +173,6 @@ func (s *RootStoreTestSuite) TestCommit() { bs2.Set([]byte(key), []byte(val)) } - // write to the branched root store, which will flush to the parent root store - rs2.Write() - // committing w/o calling WorkingHash should error _, err = s.rootStore.Commit() s.Require().Error(err) @@ -273,10 +191,10 @@ func (s *RootStoreTestSuite) TestCommit() { s.Require().Equal(uint64(1), lv) // ensure the root KVStore is cleared - s.Require().Empty(s.rootStore.(*Store).rootKVStore.GetChangeset().Size()) + s.Require().Empty(s.rootStore.(*Store).kvStores[testStoreKey].GetChangeset().Size()) // perform reads on the updated root store - bs := s.rootStore.GetKVStore("") + bs := s.rootStore.GetKVStore(testStoreKey) for i := 0; i < 100; i++ { key := fmt.Sprintf("key%03d", i) // key000, key001, ..., key099 val := fmt.Sprintf("val%03d", i) // val000, val001, ..., val099 diff --git a/store/storage/storage_bench_test.go b/store/storage/storage_bench_test.go index 5639d5d4e84f..62ea1d6164cc 100644 --- a/store/storage/storage_bench_test.go +++ b/store/storage/storage_bench_test.go @@ -65,7 +65,7 @@ func BenchmarkGet(b *testing.B) { _ = db.Close() }() - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < numKeyVals; i++ { cs.AddKVPair(storeKey1, store.KVPair{Key: keys[i], Value: vals[i]}) } @@ -101,7 +101,7 @@ func BenchmarkApplyChangeset(b *testing.B) { for i := 0; i < b.N; i++ { b.StopTimer() - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for j := 0; j < 1000; j++ { key := make([]byte, 128) val := make([]byte, 128) @@ -148,7 +148,7 @@ func BenchmarkIterate(b *testing.B) { b.StopTimer() - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < numKeyVals; i++ { cs.AddKVPair(storeKey1, store.KVPair{Key: keys[i], Value: vals[i]}) } diff --git a/store/storage/storage_test_suite.go b/store/storage/storage_test_suite.go index 7c7ea03e0c82..303d77bd13c2 100644 --- a/store/storage/storage_test_suite.go +++ b/store/storage/storage_test_suite.go @@ -56,7 +56,7 @@ func (s *StorageTestSuite) TestDatabase_VersionedKeys() { defer db.Close() for i := uint64(1); i <= 100; i++ { - s.Require().NoError(db.ApplyChangeset(i, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(i, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: {{Key: []byte("key"), Value: []byte(fmt.Sprintf("value%03d", i))}}, }, @@ -76,7 +76,7 @@ func (s *StorageTestSuite) TestDatabase_GetVersionedKey() { defer db.Close() // store a key at version 1 - s.Require().NoError(db.ApplyChangeset(1, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(1, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: {{Key: []byte("key"), Value: []byte("value001")}}, }, @@ -92,7 +92,7 @@ func (s *StorageTestSuite) TestDatabase_GetVersionedKey() { s.Require().True(ok) // chain progresses to version 11 with an update to key - s.Require().NoError(db.ApplyChangeset(11, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(11, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: {{Key: []byte("key"), Value: []byte("value011")}}, }, @@ -117,7 +117,7 @@ func (s *StorageTestSuite) TestDatabase_GetVersionedKey() { } // chain progresses to version 15 with a delete to key - s.Require().NoError(db.ApplyChangeset(15, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(15, store.NewChangesetWithPairs( map[string]store.KVPairs{storeKey1: {{Key: []byte("key")}}}, ))) @@ -149,7 +149,7 @@ func (s *StorageTestSuite) TestDatabase_ApplyChangeset() { s.Require().NoError(err) defer db.Close() - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 100; i++ { cs.AddKVPair(storeKey1, store.KVPair{Key: []byte(fmt.Sprintf("key%03d", i)), Value: []byte("value")}) } @@ -236,7 +236,7 @@ func (s *StorageTestSuite) TestDatabase_Iterator() { s.Require().NoError(err) defer db.Close() - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 100; i++ { key := fmt.Sprintf("key%03d", i) // key000, key001, ..., key099 val := fmt.Sprintf("val%03d", i) // val000, val001, ..., val099 @@ -301,7 +301,7 @@ func (s *StorageTestSuite) TestDatabase_Iterator_RangedDeletes() { s.Require().NoError(err) defer db.Close() - s.Require().NoError(db.ApplyChangeset(1, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(1, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: { {Key: []byte("key001"), Value: []byte("value001")}, @@ -310,13 +310,13 @@ func (s *StorageTestSuite) TestDatabase_Iterator_RangedDeletes() { }, ))) - s.Require().NoError(db.ApplyChangeset(5, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(5, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: {{Key: []byte("key002"), Value: []byte("value002")}}, }, ))) - s.Require().NoError(db.ApplyChangeset(10, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(10, store.NewChangesetWithPairs( map[string]store.KVPairs{ storeKey1: {{Key: []byte("key002")}}, }, @@ -344,7 +344,7 @@ func (s *StorageTestSuite) TestDatabase_IteratorMultiVersion() { // for versions 1-49, set all 10 keys for v := uint64(1); v < 50; v++ { - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 10; i++ { key := fmt.Sprintf("key%03d", i) val := fmt.Sprintf("val%03d-%03d", i, v) @@ -357,7 +357,7 @@ func (s *StorageTestSuite) TestDatabase_IteratorMultiVersion() { // for versions 50-100, only update even keys for v := uint64(50); v <= 100; v++ { - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 10; i++ { if i%2 == 0 { key := fmt.Sprintf("key%03d", i) @@ -402,7 +402,7 @@ func (s *StorageTestSuite) TestDatabase_IteratorNoDomain() { // for versions 1-50, set all 10 keys for v := uint64(1); v <= 50; v++ { - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 10; i++ { key := fmt.Sprintf("key%03d", i) val := fmt.Sprintf("val%03d-%03d", i, v) @@ -442,7 +442,7 @@ func (s *StorageTestSuite) TestDatabase_Prune() { // for versions 1-50, set 10 keys for v := uint64(1); v <= 50; v++ { - cs := store.NewChangeset(map[string]store.KVPairs{storeKey1: {}}) + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: {}}) for i := 0; i < 10; i++ { key := fmt.Sprintf("key%03d", i) val := fmt.Sprintf("val%03d-%03d", i, v) @@ -508,13 +508,13 @@ func (s *StorageTestSuite) TestDatabase_Prune_KeepRecent() { key := []byte("key") // write a key at three different versions - s.Require().NoError(db.ApplyChangeset(1, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(1, store.NewChangesetWithPairs( map[string]store.KVPairs{storeKey1: {{Key: key, Value: []byte("val001")}}}, ))) - s.Require().NoError(db.ApplyChangeset(100, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(100, store.NewChangesetWithPairs( map[string]store.KVPairs{storeKey1: {{Key: key, Value: []byte("val100")}}}, ))) - s.Require().NoError(db.ApplyChangeset(200, store.NewChangeset( + s.Require().NoError(db.ApplyChangeset(200, store.NewChangesetWithPairs( map[string]store.KVPairs{storeKey1: {{Key: key, Value: []byte("val200")}}}, ))) From 6ffc2090434e8ae3c61e76336df988c2d8f0de78 Mon Sep 17 00:00:00 2001 From: Likhita Polavarapu <78951027+likhita-809@users.noreply.github.com> Date: Tue, 9 Jan 2024 21:47:59 +0530 Subject: [PATCH 10/28] feat(x/protocolpool): Add Implementation for CreateContinuousFund and CancelContinuousFund features (#18471) --- api/cosmos/protocolpool/v1/genesis.pulsar.go | 808 ++++++++ api/cosmos/protocolpool/v1/tx.pulsar.go | 1792 ++++++++++++----- api/cosmos/protocolpool/v1/tx_grpc.pb.go | 51 +- api/cosmos/protocolpool/v1/types.pulsar.go | 706 ++++++- proto/cosmos/protocolpool/v1/genesis.proto | 14 + proto/cosmos/protocolpool/v1/tx.proto | 44 +- proto/cosmos/protocolpool/v1/types.proto | 16 +- simapp/app.go | 2 +- simapp/app_config.go | 1 + .../distribution/keeper/msg_server_test.go | 2 +- tests/integration/gov/keeper/keeper_test.go | 2 +- testutil/configurator/configurator.go | 1 + x/accounts/go.mod | 2 +- x/distribution/keeper/allocation.go | 5 + x/distribution/keeper/allocation_test.go | 2 + .../testutil/expected_keepers_mocks.go | 14 + x/distribution/types/expected_keepers.go | 1 + x/gov/client/cli/prompt.go | 4 + x/protocolpool/README.md | 61 +- x/protocolpool/autocli.go | 31 +- x/protocolpool/keeper/genesis.go | 83 + x/protocolpool/keeper/grpc_query_test.go | 4 +- x/protocolpool/keeper/keeper.go | 216 +- x/protocolpool/keeper/keeper_test.go | 45 +- x/protocolpool/keeper/msg_server.go | 100 +- x/protocolpool/keeper/msg_server_test.go | 529 ++++- x/protocolpool/module.go | 41 +- .../testutil/expected_keepers_mocks.go | 66 + x/protocolpool/types/codec.go | 3 + x/protocolpool/types/errors.go | 5 +- x/protocolpool/types/expected_keepers.go | 6 + x/protocolpool/types/genesis.go | 82 + x/protocolpool/types/genesis.pb.go | 395 ++++ x/protocolpool/types/keys.go | 8 +- x/protocolpool/types/tx.pb.go | 842 +++++--- x/protocolpool/types/types.pb.go | 344 +++- 36 files changed, 5351 insertions(+), 977 deletions(-) create mode 100644 api/cosmos/protocolpool/v1/genesis.pulsar.go create mode 100644 proto/cosmos/protocolpool/v1/genesis.proto create mode 100644 x/protocolpool/keeper/genesis.go create mode 100644 x/protocolpool/types/genesis.go create mode 100644 x/protocolpool/types/genesis.pb.go diff --git a/api/cosmos/protocolpool/v1/genesis.pulsar.go b/api/cosmos/protocolpool/v1/genesis.pulsar.go new file mode 100644 index 000000000000..83f0de7b743e --- /dev/null +++ b/api/cosmos/protocolpool/v1/genesis.pulsar.go @@ -0,0 +1,808 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package protocolpoolv1 + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_1_list)(nil) + +type _GenesisState_1_list struct { + list *[]*ContinuousFund +} + +func (x *_GenesisState_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ContinuousFund) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ContinuousFund) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_1_list) AppendMutable() protoreflect.Value { + v := new(ContinuousFund) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_1_list) NewElement() protoreflect.Value { + v := new(ContinuousFund) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_1_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*Budget +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Budget) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Budget) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(Budget) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(Budget) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_continuous_fund protoreflect.FieldDescriptor + fd_GenesisState_budget protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_protocolpool_v1_genesis_proto_init() + md_GenesisState = File_cosmos_protocolpool_v1_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_continuous_fund = md_GenesisState.Fields().ByName("continuous_fund") + fd_GenesisState_budget = md_GenesisState.Fields().ByName("budget") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_protocolpool_v1_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ContinuousFund) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_1_list{list: &x.ContinuousFund}) + if !f(fd_GenesisState_continuous_fund, value) { + return + } + } + if len(x.Budget) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.Budget}) + if !f(fd_GenesisState_budget, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + return len(x.ContinuousFund) != 0 + case "cosmos.protocolpool.v1.GenesisState.budget": + return len(x.Budget) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + x.ContinuousFund = nil + case "cosmos.protocolpool.v1.GenesisState.budget": + x.Budget = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + if len(x.ContinuousFund) == 0 { + return protoreflect.ValueOfList(&_GenesisState_1_list{}) + } + listValue := &_GenesisState_1_list{list: &x.ContinuousFund} + return protoreflect.ValueOfList(listValue) + case "cosmos.protocolpool.v1.GenesisState.budget": + if len(x.Budget) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.Budget} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + lv := value.List() + clv := lv.(*_GenesisState_1_list) + x.ContinuousFund = *clv.list + case "cosmos.protocolpool.v1.GenesisState.budget": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.Budget = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + if x.ContinuousFund == nil { + x.ContinuousFund = []*ContinuousFund{} + } + value := &_GenesisState_1_list{list: &x.ContinuousFund} + return protoreflect.ValueOfList(value) + case "cosmos.protocolpool.v1.GenesisState.budget": + if x.Budget == nil { + x.Budget = []*Budget{} + } + value := &_GenesisState_2_list{list: &x.Budget} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.GenesisState.continuous_fund": + list := []*ContinuousFund{} + return protoreflect.ValueOfList(&_GenesisState_1_list{list: &list}) + case "cosmos.protocolpool.v1.GenesisState.budget": + list := []*Budget{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.GenesisState")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.protocolpool.v1.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ContinuousFund) > 0 { + for _, e := range x.ContinuousFund { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.Budget) > 0 { + for _, e := range x.Budget { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Budget) > 0 { + for iNdEx := len(x.Budget) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Budget[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if len(x.ContinuousFund) > 0 { + for iNdEx := len(x.ContinuousFund) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ContinuousFund[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ContinuousFund", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ContinuousFund = append(x.ContinuousFund, &ContinuousFund{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ContinuousFund[len(x.ContinuousFund)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Budget", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Budget = append(x.Budget, &Budget{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Budget[len(x.Budget)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: cosmos/protocolpool/v1/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the protocolpool module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // ContinuousFund defines the continuous funds at genesis. + ContinuousFund []*ContinuousFund `protobuf:"bytes,1,rep,name=continuous_fund,json=continuousFund,proto3" json:"continuous_fund,omitempty"` + // Budget defines the budget proposals at genesis. + Budget []*Budget `protobuf:"bytes,2,rep,name=budget,proto3" json:"budget,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_protocolpool_v1_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_cosmos_protocolpool_v1_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetContinuousFund() []*ContinuousFund { + if x != nil { + return x.ContinuousFund + } + return nil +} + +func (x *GenesisState) GetBudget() []*Budget { + if x != nil { + return x.Budget + } + return nil +} + +var File_cosmos_protocolpool_v1_genesis_proto protoreflect.FileDescriptor + +var file_cosmos_protocolpool_v1_genesis_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, + 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2f, 0x76, 0x31, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x16, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x1a, 0x22, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, + 0x6f, 0x6f, 0x6c, 0x2f, 0x76, 0x31, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0x97, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x4f, 0x0a, 0x0f, 0x63, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, + 0x73, 0x5f, 0x66, 0x75, 0x6e, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, + 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, + 0x46, 0x75, 0x6e, 0x64, 0x52, 0x0e, 0x63, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, + 0x46, 0x75, 0x6e, 0x64, 0x12, 0x36, 0x0a, 0x06, 0x62, 0x75, 0x64, 0x67, 0x65, 0x74, 0x18, 0x02, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x75, + 0x64, 0x67, 0x65, 0x74, 0x52, 0x06, 0x62, 0x75, 0x64, 0x67, 0x65, 0x74, 0x42, 0xdc, 0x01, 0x0a, + 0x1a, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x42, 0x0c, 0x47, 0x65, 0x6e, + 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x36, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, + 0x6c, 0x2f, 0x76, 0x31, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, + 0x6c, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x50, 0x58, 0xaa, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, + 0x56, 0x31, 0xca, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x22, 0x43, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, + 0x6c, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_cosmos_protocolpool_v1_genesis_proto_rawDescOnce sync.Once + file_cosmos_protocolpool_v1_genesis_proto_rawDescData = file_cosmos_protocolpool_v1_genesis_proto_rawDesc +) + +func file_cosmos_protocolpool_v1_genesis_proto_rawDescGZIP() []byte { + file_cosmos_protocolpool_v1_genesis_proto_rawDescOnce.Do(func() { + file_cosmos_protocolpool_v1_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_cosmos_protocolpool_v1_genesis_proto_rawDescData) + }) + return file_cosmos_protocolpool_v1_genesis_proto_rawDescData +} + +var file_cosmos_protocolpool_v1_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_cosmos_protocolpool_v1_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: cosmos.protocolpool.v1.GenesisState + (*ContinuousFund)(nil), // 1: cosmos.protocolpool.v1.ContinuousFund + (*Budget)(nil), // 2: cosmos.protocolpool.v1.Budget +} +var file_cosmos_protocolpool_v1_genesis_proto_depIdxs = []int32{ + 1, // 0: cosmos.protocolpool.v1.GenesisState.continuous_fund:type_name -> cosmos.protocolpool.v1.ContinuousFund + 2, // 1: cosmos.protocolpool.v1.GenesisState.budget:type_name -> cosmos.protocolpool.v1.Budget + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_cosmos_protocolpool_v1_genesis_proto_init() } +func file_cosmos_protocolpool_v1_genesis_proto_init() { + if File_cosmos_protocolpool_v1_genesis_proto != nil { + return + } + file_cosmos_protocolpool_v1_types_proto_init() + if !protoimpl.UnsafeEnabled { + file_cosmos_protocolpool_v1_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_cosmos_protocolpool_v1_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_cosmos_protocolpool_v1_genesis_proto_goTypes, + DependencyIndexes: file_cosmos_protocolpool_v1_genesis_proto_depIdxs, + MessageInfos: file_cosmos_protocolpool_v1_genesis_proto_msgTypes, + }.Build() + File_cosmos_protocolpool_v1_genesis_proto = out.File + file_cosmos_protocolpool_v1_genesis_proto_rawDesc = nil + file_cosmos_protocolpool_v1_genesis_proto_goTypes = nil + file_cosmos_protocolpool_v1_genesis_proto_depIdxs = nil +} diff --git a/api/cosmos/protocolpool/v1/tx.pulsar.go b/api/cosmos/protocolpool/v1/tx.pulsar.go index 889c3d417f07..31175cf9cfba 100644 --- a/api/cosmos/protocolpool/v1/tx.pulsar.go +++ b/api/cosmos/protocolpool/v1/tx.pulsar.go @@ -3890,79 +3890,20 @@ func (x *fastReflection_MsgClaimBudgetResponse) ProtoMethods() *protoiface.Metho } } -var _ protoreflect.List = (*_MsgCreateContinuousFund_7_list)(nil) - -type _MsgCreateContinuousFund_7_list struct { - list *[]*v1beta1.Coin -} - -func (x *_MsgCreateContinuousFund_7_list) Len() int { - if x.list == nil { - return 0 - } - return len(*x.list) -} - -func (x *_MsgCreateContinuousFund_7_list) Get(i int) protoreflect.Value { - return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) -} - -func (x *_MsgCreateContinuousFund_7_list) Set(i int, value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin) - (*x.list)[i] = concreteValue -} - -func (x *_MsgCreateContinuousFund_7_list) Append(value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin) - *x.list = append(*x.list, concreteValue) -} - -func (x *_MsgCreateContinuousFund_7_list) AppendMutable() protoreflect.Value { - v := new(v1beta1.Coin) - *x.list = append(*x.list, v) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_MsgCreateContinuousFund_7_list) Truncate(n int) { - for i := n; i < len(*x.list); i++ { - (*x.list)[i] = nil - } - *x.list = (*x.list)[:n] -} - -func (x *_MsgCreateContinuousFund_7_list) NewElement() protoreflect.Value { - v := new(v1beta1.Coin) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_MsgCreateContinuousFund_7_list) IsValid() bool { - return x.list != nil -} - var ( - md_MsgCreateContinuousFund protoreflect.MessageDescriptor - fd_MsgCreateContinuousFund_title protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_description protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_authority protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_recipient protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_metadata protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_percentage protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_cap protoreflect.FieldDescriptor - fd_MsgCreateContinuousFund_expiry protoreflect.FieldDescriptor + md_MsgCreateContinuousFund protoreflect.MessageDescriptor + fd_MsgCreateContinuousFund_authority protoreflect.FieldDescriptor + fd_MsgCreateContinuousFund_recipient protoreflect.FieldDescriptor + fd_MsgCreateContinuousFund_percentage protoreflect.FieldDescriptor + fd_MsgCreateContinuousFund_expiry protoreflect.FieldDescriptor ) func init() { file_cosmos_protocolpool_v1_tx_proto_init() md_MsgCreateContinuousFund = File_cosmos_protocolpool_v1_tx_proto.Messages().ByName("MsgCreateContinuousFund") - fd_MsgCreateContinuousFund_title = md_MsgCreateContinuousFund.Fields().ByName("title") - fd_MsgCreateContinuousFund_description = md_MsgCreateContinuousFund.Fields().ByName("description") fd_MsgCreateContinuousFund_authority = md_MsgCreateContinuousFund.Fields().ByName("authority") fd_MsgCreateContinuousFund_recipient = md_MsgCreateContinuousFund.Fields().ByName("recipient") - fd_MsgCreateContinuousFund_metadata = md_MsgCreateContinuousFund.Fields().ByName("metadata") fd_MsgCreateContinuousFund_percentage = md_MsgCreateContinuousFund.Fields().ByName("percentage") - fd_MsgCreateContinuousFund_cap = md_MsgCreateContinuousFund.Fields().ByName("cap") fd_MsgCreateContinuousFund_expiry = md_MsgCreateContinuousFund.Fields().ByName("expiry") } @@ -4031,18 +3972,6 @@ func (x *fastReflection_MsgCreateContinuousFund) Interface() protoreflect.ProtoM // While iterating, mutating operations may only be performed // on the current field descriptor. func (x *fastReflection_MsgCreateContinuousFund) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Title != "" { - value := protoreflect.ValueOfString(x.Title) - if !f(fd_MsgCreateContinuousFund_title, value) { - return - } - } - if x.Description != "" { - value := protoreflect.ValueOfString(x.Description) - if !f(fd_MsgCreateContinuousFund_description, value) { - return - } - } if x.Authority != "" { value := protoreflect.ValueOfString(x.Authority) if !f(fd_MsgCreateContinuousFund_authority, value) { @@ -4055,24 +3984,12 @@ func (x *fastReflection_MsgCreateContinuousFund) Range(f func(protoreflect.Field return } } - if x.Metadata != "" { - value := protoreflect.ValueOfString(x.Metadata) - if !f(fd_MsgCreateContinuousFund_metadata, value) { - return - } - } if x.Percentage != "" { value := protoreflect.ValueOfString(x.Percentage) if !f(fd_MsgCreateContinuousFund_percentage, value) { return } } - if len(x.Cap) != 0 { - value := protoreflect.ValueOfList(&_MsgCreateContinuousFund_7_list{list: &x.Cap}) - if !f(fd_MsgCreateContinuousFund_cap, value) { - return - } - } if x.Expiry != nil { value := protoreflect.ValueOfMessage(x.Expiry.ProtoReflect()) if !f(fd_MsgCreateContinuousFund_expiry, value) { @@ -4094,20 +4011,12 @@ func (x *fastReflection_MsgCreateContinuousFund) Range(f func(protoreflect.Field // a repeated field is populated if it is non-empty. func (x *fastReflection_MsgCreateContinuousFund) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - return x.Title != "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - return x.Description != "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": return x.Authority != "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": return x.Recipient != "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - return x.Metadata != "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": return x.Percentage != "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - return len(x.Cap) != 0 case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": return x.Expiry != nil default: @@ -4126,20 +4035,12 @@ func (x *fastReflection_MsgCreateContinuousFund) Has(fd protoreflect.FieldDescri // Clear is a mutating operation and unsafe for concurrent use. func (x *fastReflection_MsgCreateContinuousFund) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - x.Title = "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - x.Description = "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": x.Authority = "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": x.Recipient = "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - x.Metadata = "" case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": x.Percentage = "" - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - x.Cap = nil case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": x.Expiry = nil default: @@ -4158,30 +4059,15 @@ func (x *fastReflection_MsgCreateContinuousFund) Clear(fd protoreflect.FieldDesc // of the value; to obtain a mutable reference, use Mutable. func (x *fastReflection_MsgCreateContinuousFund) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - value := x.Title - return protoreflect.ValueOfString(value) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - value := x.Description - return protoreflect.ValueOfString(value) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": value := x.Authority return protoreflect.ValueOfString(value) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": value := x.Recipient return protoreflect.ValueOfString(value) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - value := x.Metadata - return protoreflect.ValueOfString(value) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": value := x.Percentage return protoreflect.ValueOfString(value) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - if len(x.Cap) == 0 { - return protoreflect.ValueOfList(&_MsgCreateContinuousFund_7_list{}) - } - listValue := &_MsgCreateContinuousFund_7_list{list: &x.Cap} - return protoreflect.ValueOfList(listValue) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": value := x.Expiry return protoreflect.ValueOfMessage(value.ProtoReflect()) @@ -4205,22 +4091,12 @@ func (x *fastReflection_MsgCreateContinuousFund) Get(descriptor protoreflect.Fie // Set is a mutating operation and unsafe for concurrent use. func (x *fastReflection_MsgCreateContinuousFund) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - x.Title = value.Interface().(string) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - x.Description = value.Interface().(string) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": x.Authority = value.Interface().(string) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": x.Recipient = value.Interface().(string) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - x.Metadata = value.Interface().(string) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": x.Percentage = value.Interface().(string) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - lv := value.List() - clv := lv.(*_MsgCreateContinuousFund_7_list) - x.Cap = *clv.list case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": x.Expiry = value.Message().Interface().(*timestamppb.Timestamp) default: @@ -4243,27 +4119,15 @@ func (x *fastReflection_MsgCreateContinuousFund) Set(fd protoreflect.FieldDescri // Mutable is a mutating operation and unsafe for concurrent use. func (x *fastReflection_MsgCreateContinuousFund) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - if x.Cap == nil { - x.Cap = []*v1beta1.Coin{} - } - value := &_MsgCreateContinuousFund_7_list{list: &x.Cap} - return protoreflect.ValueOfList(value) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": if x.Expiry == nil { x.Expiry = new(timestamppb.Timestamp) } return protoreflect.ValueOfMessage(x.Expiry.ProtoReflect()) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - panic(fmt.Errorf("field title of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - panic(fmt.Errorf("field description of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": panic(fmt.Errorf("field authority of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": panic(fmt.Errorf("field recipient of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - panic(fmt.Errorf("field metadata of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": panic(fmt.Errorf("field percentage of message cosmos.protocolpool.v1.MsgCreateContinuousFund is not mutable")) default: @@ -4279,21 +4143,12 @@ func (x *fastReflection_MsgCreateContinuousFund) Mutable(fd protoreflect.FieldDe // For lists, maps, and messages, this returns a new, empty, mutable value. func (x *fastReflection_MsgCreateContinuousFund) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.title": - return protoreflect.ValueOfString("") - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.description": - return protoreflect.ValueOfString("") case "cosmos.protocolpool.v1.MsgCreateContinuousFund.authority": return protoreflect.ValueOfString("") case "cosmos.protocolpool.v1.MsgCreateContinuousFund.recipient": return protoreflect.ValueOfString("") - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.metadata": - return protoreflect.ValueOfString("") case "cosmos.protocolpool.v1.MsgCreateContinuousFund.percentage": return protoreflect.ValueOfString("") - case "cosmos.protocolpool.v1.MsgCreateContinuousFund.cap": - list := []*v1beta1.Coin{} - return protoreflect.ValueOfList(&_MsgCreateContinuousFund_7_list{list: &list}) case "cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry": m := new(timestamppb.Timestamp) return protoreflect.ValueOfMessage(m.ProtoReflect()) @@ -4366,14 +4221,6 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth var n int var l int _ = l - l = len(x.Title) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } - l = len(x.Description) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } l = len(x.Authority) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) @@ -4382,20 +4229,10 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Metadata) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } l = len(x.Percentage) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - if len(x.Cap) > 0 { - for _, e := range x.Cap { - l = options.Size(e) - n += 1 + l + runtime.Sov(uint64(l)) - } - } if x.Expiry != nil { l = options.Size(x.Expiry) n += 1 + l + runtime.Sov(uint64(l)) @@ -4441,64 +4278,27 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x42 - } - if len(x.Cap) > 0 { - for iNdEx := len(x.Cap) - 1; iNdEx >= 0; iNdEx-- { - encoded, err := options.Marshal(x.Cap[iNdEx]) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0x3a - } + dAtA[i] = 0x22 } if len(x.Percentage) > 0 { i -= len(x.Percentage) copy(dAtA[i:], x.Percentage) i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Percentage))) i-- - dAtA[i] = 0x32 - } - if len(x.Metadata) > 0 { - i -= len(x.Metadata) - copy(dAtA[i:], x.Metadata) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Metadata))) - i-- - dAtA[i] = 0x2a + dAtA[i] = 0x1a } if len(x.Recipient) > 0 { i -= len(x.Recipient) copy(dAtA[i:], x.Recipient) i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Recipient))) i-- - dAtA[i] = 0x22 + dAtA[i] = 0x12 } if len(x.Authority) > 0 { i -= len(x.Authority) copy(dAtA[i:], x.Authority) i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) i-- - dAtA[i] = 0x1a - } - if len(x.Description) > 0 { - i -= len(x.Description) - copy(dAtA[i:], x.Description) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Description))) - i-- - dAtA[i] = 0x12 - } - if len(x.Title) > 0 { - i -= len(x.Title) - copy(dAtA[i:], x.Title) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Title))) - i-- dAtA[i] = 0xa } if input.Buf != nil { @@ -4551,70 +4351,6 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth } switch fieldNum { case 1: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Title", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Title = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Description = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } @@ -4646,7 +4382,7 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth } x.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 2: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) } @@ -4678,39 +4414,7 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth } x.Recipient = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Metadata = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: + case 3: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Percentage", wireType) } @@ -4742,41 +4446,7 @@ func (x *fastReflection_MsgCreateContinuousFund) ProtoMethods() *protoiface.Meth } x.Percentage = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 7: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Cap", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Cap = append(x.Cap, &v1beta1.Coin{}) - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Cap[len(x.Cap)-1]); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - iNdEx = postIndex - case 8: + case 4: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Expiry", wireType) } @@ -5688,10 +5358,11 @@ func (x *fastReflection_MsgCancelContinuousFund) ProtoMethods() *protoiface.Meth } var ( - md_MsgCancelContinuousFundResponse protoreflect.MessageDescriptor - fd_MsgCancelContinuousFundResponse_canceled_time protoreflect.FieldDescriptor - fd_MsgCancelContinuousFundResponse_canceled_height protoreflect.FieldDescriptor - fd_MsgCancelContinuousFundResponse_recipient_address protoreflect.FieldDescriptor + md_MsgCancelContinuousFundResponse protoreflect.MessageDescriptor + fd_MsgCancelContinuousFundResponse_canceled_time protoreflect.FieldDescriptor + fd_MsgCancelContinuousFundResponse_canceled_height protoreflect.FieldDescriptor + fd_MsgCancelContinuousFundResponse_recipient_address protoreflect.FieldDescriptor + fd_MsgCancelContinuousFundResponse_withdrawn_allocated_fund protoreflect.FieldDescriptor ) func init() { @@ -5700,6 +5371,7 @@ func init() { fd_MsgCancelContinuousFundResponse_canceled_time = md_MsgCancelContinuousFundResponse.Fields().ByName("canceled_time") fd_MsgCancelContinuousFundResponse_canceled_height = md_MsgCancelContinuousFundResponse.Fields().ByName("canceled_height") fd_MsgCancelContinuousFundResponse_recipient_address = md_MsgCancelContinuousFundResponse.Fields().ByName("recipient_address") + fd_MsgCancelContinuousFundResponse_withdrawn_allocated_fund = md_MsgCancelContinuousFundResponse.Fields().ByName("withdrawn_allocated_fund") } var _ protoreflect.Message = (*fastReflection_MsgCancelContinuousFundResponse)(nil) @@ -5785,6 +5457,12 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Range(f func(protorefle return } } + if x.WithdrawnAllocatedFund != nil { + value := protoreflect.ValueOfMessage(x.WithdrawnAllocatedFund.ProtoReflect()) + if !f(fd_MsgCancelContinuousFundResponse_withdrawn_allocated_fund, value) { + return + } + } } // Has reports whether a field is populated. @@ -5806,6 +5484,8 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Has(fd protoreflect.Fie return x.CanceledHeight != uint64(0) case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": return x.RecipientAddress != "" + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + return x.WithdrawnAllocatedFund != nil default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse")) @@ -5828,6 +5508,8 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Clear(fd protoreflect.F x.CanceledHeight = uint64(0) case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": x.RecipientAddress = "" + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + x.WithdrawnAllocatedFund = nil default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse")) @@ -5853,6 +5535,9 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Get(descriptor protoref case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": value := x.RecipientAddress return protoreflect.ValueOfString(value) + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + value := x.WithdrawnAllocatedFund + return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse")) @@ -5879,6 +5564,8 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Set(fd protoreflect.Fie x.CanceledHeight = value.Uint() case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": x.RecipientAddress = value.Interface().(string) + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + x.WithdrawnAllocatedFund = value.Message().Interface().(*v1beta1.Coin) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse")) @@ -5904,6 +5591,11 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) Mutable(fd protoreflect x.CanceledTime = new(timestamppb.Timestamp) } return protoreflect.ValueOfMessage(x.CanceledTime.ProtoReflect()) + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + if x.WithdrawnAllocatedFund == nil { + x.WithdrawnAllocatedFund = new(v1beta1.Coin) + } + return protoreflect.ValueOfMessage(x.WithdrawnAllocatedFund.ProtoReflect()) case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.canceled_height": panic(fmt.Errorf("field canceled_height of message cosmos.protocolpool.v1.MsgCancelContinuousFundResponse is not mutable")) case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": @@ -5928,6 +5620,9 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) NewField(fd protoreflec return protoreflect.ValueOfUint64(uint64(0)) case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.recipient_address": return protoreflect.ValueOfString("") + case "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund": + m := new(v1beta1.Coin) + return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse")) @@ -6008,6 +5703,10 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) ProtoMethods() *protoif if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } + if x.WithdrawnAllocatedFund != nil { + l = options.Size(x.WithdrawnAllocatedFund) + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -6037,6 +5736,20 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) ProtoMethods() *protoif i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if x.WithdrawnAllocatedFund != nil { + encoded, err := options.Marshal(x.WithdrawnAllocatedFund) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } if len(x.RecipientAddress) > 0 { i -= len(x.RecipientAddress) copy(dAtA[i:], x.RecipientAddress) @@ -6199,11 +5912,902 @@ func (x *fastReflection_MsgCancelContinuousFundResponse) ProtoMethods() *protoif } x.RecipientAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := runtime.Skip(dAtA[iNdEx:]) - if err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawnAllocatedFund", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.WithdrawnAllocatedFund == nil { + x.WithdrawnAllocatedFund = &v1beta1.Coin{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.WithdrawnAllocatedFund); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawContinuousFund protoreflect.MessageDescriptor + fd_MsgWithdrawContinuousFund_recipient_address protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_protocolpool_v1_tx_proto_init() + md_MsgWithdrawContinuousFund = File_cosmos_protocolpool_v1_tx_proto.Messages().ByName("MsgWithdrawContinuousFund") + fd_MsgWithdrawContinuousFund_recipient_address = md_MsgWithdrawContinuousFund.Fields().ByName("recipient_address") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawContinuousFund)(nil) + +type fastReflection_MsgWithdrawContinuousFund MsgWithdrawContinuousFund + +func (x *MsgWithdrawContinuousFund) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawContinuousFund)(x) +} + +func (x *MsgWithdrawContinuousFund) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_protocolpool_v1_tx_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawContinuousFund_messageType fastReflection_MsgWithdrawContinuousFund_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawContinuousFund_messageType{} + +type fastReflection_MsgWithdrawContinuousFund_messageType struct{} + +func (x fastReflection_MsgWithdrawContinuousFund_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawContinuousFund)(nil) +} +func (x fastReflection_MsgWithdrawContinuousFund_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawContinuousFund) +} +func (x fastReflection_MsgWithdrawContinuousFund_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawContinuousFund +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawContinuousFund) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawContinuousFund +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawContinuousFund) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawContinuousFund_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawContinuousFund) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawContinuousFund) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawContinuousFund) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawContinuousFund)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawContinuousFund) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.RecipientAddress != "" { + value := protoreflect.ValueOfString(x.RecipientAddress) + if !f(fd_MsgWithdrawContinuousFund_recipient_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawContinuousFund) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + return x.RecipientAddress != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFund) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + x.RecipientAddress = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawContinuousFund) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + value := x.RecipientAddress + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFund) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + x.RecipientAddress = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFund) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + panic(fmt.Errorf("field recipient_address of message cosmos.protocolpool.v1.MsgWithdrawContinuousFund is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawContinuousFund) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFund.recipient_address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFund does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawContinuousFund) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.protocolpool.v1.MsgWithdrawContinuousFund", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawContinuousFund) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFund) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawContinuousFund) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawContinuousFund) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawContinuousFund) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.RecipientAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawContinuousFund) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.RecipientAddress) > 0 { + i -= len(x.RecipientAddress) + copy(dAtA[i:], x.RecipientAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.RecipientAddress))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawContinuousFund) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawContinuousFund: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawContinuousFund: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RecipientAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.RecipientAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawContinuousFundResponse protoreflect.MessageDescriptor + fd_MsgWithdrawContinuousFundResponse_amount protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_protocolpool_v1_tx_proto_init() + md_MsgWithdrawContinuousFundResponse = File_cosmos_protocolpool_v1_tx_proto.Messages().ByName("MsgWithdrawContinuousFundResponse") + fd_MsgWithdrawContinuousFundResponse_amount = md_MsgWithdrawContinuousFundResponse.Fields().ByName("amount") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawContinuousFundResponse)(nil) + +type fastReflection_MsgWithdrawContinuousFundResponse MsgWithdrawContinuousFundResponse + +func (x *MsgWithdrawContinuousFundResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawContinuousFundResponse)(x) +} + +func (x *MsgWithdrawContinuousFundResponse) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_protocolpool_v1_tx_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawContinuousFundResponse_messageType fastReflection_MsgWithdrawContinuousFundResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawContinuousFundResponse_messageType{} + +type fastReflection_MsgWithdrawContinuousFundResponse_messageType struct{} + +func (x fastReflection_MsgWithdrawContinuousFundResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawContinuousFundResponse)(nil) +} +func (x fastReflection_MsgWithdrawContinuousFundResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawContinuousFundResponse) +} +func (x fastReflection_MsgWithdrawContinuousFundResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawContinuousFundResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawContinuousFundResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawContinuousFundResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawContinuousFundResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawContinuousFundResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Amount != nil { + value := protoreflect.ValueOfMessage(x.Amount.ProtoReflect()) + if !f(fd_MsgWithdrawContinuousFundResponse_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + return x.Amount != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + x.Amount = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + value := x.Amount + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + x.Amount = value.Message().Interface().(*v1beta1.Coin) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + if x.Amount == nil { + x.Amount = new(v1beta1.Coin) + } + return protoreflect.ValueOfMessage(x.Amount.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount": + m := new(v1beta1.Coin) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawContinuousFundResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawContinuousFundResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Amount != nil { + l = options.Size(x.Amount) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawContinuousFundResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Amount != nil { + encoded, err := options.Marshal(x.Amount) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawContinuousFundResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawContinuousFundResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawContinuousFundResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Amount == nil { + x.Amount = &v1beta1.Coin{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Amount); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } if (skippy < 0) || (iNdEx+skippy) < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength @@ -6594,23 +7198,14 @@ type MsgCreateContinuousFund struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // Title is the title of the funds. - Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` - // Description of the funds. - Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` // Authority is the address that controls the module (defaults to x/gov unless overwritten). - Authority string `protobuf:"bytes,3,opt,name=authority,proto3" json:"authority,omitempty"` + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` // Recipient address of the account receiving funds. - Recipient string `protobuf:"bytes,4,opt,name=recipient,proto3" json:"recipient,omitempty"` - // Metadata is any arbitrary metadata attached. - Metadata string `protobuf:"bytes,5,opt,name=metadata,proto3" json:"metadata,omitempty"` - // Percentage is the percentage of funds to be allocated from Community pool share on block by block, - // till the `cap` is reached or expired. - Percentage string `protobuf:"bytes,6,opt,name=percentage,proto3" json:"percentage,omitempty"` - // Cap is the capital amount, which when its met funds are no longer distributed. - Cap []*v1beta1.Coin `protobuf:"bytes,7,rep,name=cap,proto3" json:"cap,omitempty"` + Recipient string `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` + // Percentage is the percentage of funds to be allocated from Community pool. + Percentage string `protobuf:"bytes,3,opt,name=percentage,proto3" json:"percentage,omitempty"` // Optional, if expiry is set, removes the state object when expired. - Expiry *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=expiry,proto3" json:"expiry,omitempty"` + Expiry *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=expiry,proto3" json:"expiry,omitempty"` } func (x *MsgCreateContinuousFund) Reset() { @@ -6633,20 +7228,6 @@ func (*MsgCreateContinuousFund) Descriptor() ([]byte, []int) { return file_cosmos_protocolpool_v1_tx_proto_rawDescGZIP(), []int{8} } -func (x *MsgCreateContinuousFund) GetTitle() string { - if x != nil { - return x.Title - } - return "" -} - -func (x *MsgCreateContinuousFund) GetDescription() string { - if x != nil { - return x.Description - } - return "" -} - func (x *MsgCreateContinuousFund) GetAuthority() string { if x != nil { return x.Authority @@ -6661,13 +7242,6 @@ func (x *MsgCreateContinuousFund) GetRecipient() string { return "" } -func (x *MsgCreateContinuousFund) GetMetadata() string { - if x != nil { - return x.Metadata - } - return "" -} - func (x *MsgCreateContinuousFund) GetPercentage() string { if x != nil { return x.Percentage @@ -6675,13 +7249,6 @@ func (x *MsgCreateContinuousFund) GetPercentage() string { return "" } -func (x *MsgCreateContinuousFund) GetCap() []*v1beta1.Coin { - if x != nil { - return x.Cap - } - return nil -} - func (x *MsgCreateContinuousFund) GetExpiry() *timestamppb.Timestamp { if x != nil { return x.Expiry @@ -6776,6 +7343,10 @@ type MsgCancelContinuousFundResponse struct { CanceledHeight uint64 `protobuf:"varint,2,opt,name=canceled_height,json=canceledHeight,proto3" json:"canceled_height,omitempty"` // RecipientAddress is the account address of recipient whose funds are cancelled. RecipientAddress string `protobuf:"bytes,3,opt,name=recipient_address,json=recipientAddress,proto3" json:"recipient_address,omitempty"` + // withdrawnAllocatedFund represents the fund allocated to this recipient (if any) that have not been withdrawn yet, + // before a cancellation request has been initiated. + // It involves first withdrawing the funds and then canceling the request. + WithdrawnAllocatedFund *v1beta1.Coin `protobuf:"bytes,4,opt,name=withdrawn_allocated_fund,json=withdrawnAllocatedFund,proto3" json:"withdrawn_allocated_fund,omitempty"` } func (x *MsgCancelContinuousFundResponse) Reset() { @@ -6819,6 +7390,86 @@ func (x *MsgCancelContinuousFundResponse) GetRecipientAddress() string { return "" } +func (x *MsgCancelContinuousFundResponse) GetWithdrawnAllocatedFund() *v1beta1.Coin { + if x != nil { + return x.WithdrawnAllocatedFund + } + return nil +} + +// MsgWithdrawContinuousFund defines a message for withdrawing the continuous fund allocated to it. +type MsgWithdrawContinuousFund struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + RecipientAddress string `protobuf:"bytes,1,opt,name=recipient_address,json=recipientAddress,proto3" json:"recipient_address,omitempty"` +} + +func (x *MsgWithdrawContinuousFund) Reset() { + *x = MsgWithdrawContinuousFund{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_protocolpool_v1_tx_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawContinuousFund) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawContinuousFund) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawContinuousFund.ProtoReflect.Descriptor instead. +func (*MsgWithdrawContinuousFund) Descriptor() ([]byte, []int) { + return file_cosmos_protocolpool_v1_tx_proto_rawDescGZIP(), []int{12} +} + +func (x *MsgWithdrawContinuousFund) GetRecipientAddress() string { + if x != nil { + return x.RecipientAddress + } + return "" +} + +// MsgWithdrawContinuousFundResponse defines the response to executing a +// MsgWithdrawContinuousFund message. +type MsgWithdrawContinuousFundResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Amount *v1beta1.Coin `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount,omitempty"` +} + +func (x *MsgWithdrawContinuousFundResponse) Reset() { + *x = MsgWithdrawContinuousFundResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_protocolpool_v1_tx_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawContinuousFundResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawContinuousFundResponse) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawContinuousFundResponse.ProtoReflect.Descriptor instead. +func (*MsgWithdrawContinuousFundResponse) Descriptor() ([]byte, []int) { + return file_cosmos_protocolpool_v1_tx_proto_rawDescGZIP(), []int{13} +} + +func (x *MsgWithdrawContinuousFundResponse) GetAmount() *v1beta1.Coin { + if x != nil { + return x.Amount + } + return nil +} + var File_cosmos_protocolpool_v1_tx_proto protoreflect.FileDescriptor var file_cosmos_protocolpool_v1_tx_proto_rawDesc = []byte{ @@ -6908,125 +7559,147 @@ var file_cosmos_protocolpool_v1_tx_proto_rawDesc = []byte{ 0x42, 0x30, 0xc8, 0xde, 0x1f, 0x00, 0xaa, 0xdf, 0x1f, 0x28, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x43, 0x6f, 0x69, - 0x6e, 0x73, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xd9, 0x03, 0x0a, 0x17, 0x4d, + 0x6e, 0x73, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xa6, 0x02, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, - 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x20, 0x0a, 0x0b, - 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x36, - 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x36, 0x0a, 0x09, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, - 0x65, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, + 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, - 0x69, 0x6e, 0x67, 0x52, 0x09, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x1a, - 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x51, 0x0a, 0x0a, 0x70, 0x65, - 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, - 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, - 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, - 0x44, 0x65, 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, - 0x63, 0x52, 0x0a, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x12, 0x5d, 0x0a, - 0x03, 0x63, 0x61, 0x70, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, + 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x36, + 0x0a, 0x09, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x72, 0x65, 0x63, + 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x51, 0x0a, 0x0a, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, + 0x74, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, 0xc8, 0xde, 0x1f, 0x00, + 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, + 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xd2, + 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0a, 0x70, + 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x12, 0x38, 0x0a, 0x06, 0x65, 0x78, 0x70, + 0x69, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x06, 0x65, 0x78, 0x70, + 0x69, 0x72, 0x79, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, + 0x69, 0x74, 0x79, 0x22, 0x21, 0x0a, 0x1f, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xa8, 0x01, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x43, 0x61, + 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, + 0x6e, 0x64, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x45, 0x0a, 0x11, 0x72, 0x65, + 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x10, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, + 0x79, 0x22, 0xe4, 0x02, 0x0a, 0x1f, 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, + 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x0d, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, + 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, + 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, + 0x1f, 0x01, 0x52, 0x0c, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x54, 0x69, 0x6d, 0x65, + 0x12, 0x27, 0x0a, 0x0f, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x5f, 0x68, 0x65, 0x69, + 0x67, 0x68, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0e, 0x63, 0x61, 0x6e, 0x63, 0x65, + 0x6c, 0x65, 0x64, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x45, 0x0a, 0x11, 0x72, 0x65, 0x63, + 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x10, + 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x12, 0x85, 0x01, 0x0a, 0x18, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x6e, 0x5f, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x66, 0x75, 0x6e, 0x64, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, + 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x30, + 0xc8, 0xde, 0x1f, 0x00, 0xaa, 0xdf, 0x1f, 0x28, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x73, + 0x52, 0x16, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x6e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x65, 0x64, 0x46, 0x75, 0x6e, 0x64, 0x22, 0x7a, 0x0a, 0x19, 0x4d, 0x73, 0x67, 0x57, + 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, + 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x45, 0x0a, 0x11, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, + 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x10, 0x72, 0x65, 0x63, 0x69, + 0x70, 0x69, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x16, 0x82, 0xe7, + 0xb0, 0x2a, 0x11, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x22, 0x88, 0x01, 0x0a, 0x21, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, + 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x63, 0x0a, 0x06, 0x61, 0x6d, + 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x30, 0xc8, 0xde, 0x1f, 0x00, 0xaa, 0xdf, 0x1f, 0x28, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, - 0x73, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x73, 0x52, 0x03, 0x63, 0x61, 0x70, 0x12, 0x38, 0x0a, 0x06, - 0x65, 0x78, 0x70, 0x69, 0x72, 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, - 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x06, - 0x65, 0x78, 0x70, 0x69, 0x72, 0x79, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x21, 0x0a, 0x1f, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, - 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xa8, 0x01, 0x0a, 0x17, 0x4d, 0x73, - 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, - 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, - 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x45, 0x0a, - 0x11, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, - 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x52, 0x10, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, - 0x72, 0x69, 0x74, 0x79, 0x22, 0xdc, 0x01, 0x0a, 0x1f, 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, - 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x0d, 0x63, 0x61, 0x6e, 0x63, - 0x65, 0x6c, 0x65, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, - 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0c, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x54, - 0x69, 0x6d, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x5f, - 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0e, 0x63, 0x61, - 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x45, 0x0a, 0x11, - 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, - 0x67, 0x52, 0x10, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, - 0x65, 0x73, 0x73, 0x32, 0xf1, 0x05, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x77, 0x0a, 0x11, 0x46, - 0x75, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, - 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, - 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x46, 0x75, 0x6e, - 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x1a, 0x34, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, - 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x46, 0x75, 0x6e, 0x64, 0x43, - 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x7a, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, - 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, + 0x73, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x73, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x32, + 0xfa, 0x06, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x77, 0x0a, 0x11, 0x46, 0x75, 0x6e, 0x64, 0x43, + 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x12, 0x2c, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, + 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x46, 0x75, 0x6e, 0x64, 0x43, 0x6f, 0x6d, + 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x1a, 0x34, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, - 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, - 0x50, 0x6f, 0x6f, 0x6c, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x1a, 0x35, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, - 0x6f, 0x6f, 0x6c, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x80, 0x01, 0x0a, 0x14, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, 0x67, 0x65, - 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, 0x67, - 0x65, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x37, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, - 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, - 0x67, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x65, 0x0a, 0x0b, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x42, 0x75, 0x64, 0x67, - 0x65, 0x74, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, - 0x6c, 0x61, 0x69, 0x6d, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, - 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x42, 0x75, 0x64, 0x67, - 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x80, 0x01, 0x0a, 0x14, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, - 0x75, 0x6e, 0x64, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, - 0x46, 0x75, 0x6e, 0x64, 0x1a, 0x37, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, - 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, - 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x80, 0x01, - 0x0a, 0x14, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, - 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x46, 0x75, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x75, + 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x7a, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, + 0x6c, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, + 0x53, 0x70, 0x65, 0x6e, 0x64, 0x1a, 0x35, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, + 0x73, 0x67, 0x43, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x74, 0x79, 0x50, 0x6f, 0x6f, 0x6c, 0x53, + 0x70, 0x65, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x80, 0x01, 0x0a, + 0x14, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, + 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x50, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x37, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, - 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, - 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x1a, 0x37, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x65, 0x0a, 0x0b, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x12, 0x26, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, + 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x61, 0x69, 0x6d, + 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x42, 0x75, 0x64, 0x67, 0x65, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x80, 0x01, 0x0a, 0x14, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, + 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, + 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, + 0x1a, 0x37, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, + 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, + 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x86, 0x01, 0x0a, 0x16, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, + 0x46, 0x75, 0x6e, 0x64, 0x12, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, + 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x1a, 0x39, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, - 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, - 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x1a, 0x05, 0x80, 0xe7, 0xb0, 0x2a, 0x01, 0x42, 0xd7, 0x01, 0x0a, 0x1a, 0x63, 0x6f, 0x6d, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, - 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, - 0x01, 0x5a, 0x36, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, - 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2f, 0x76, 0x31, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x50, 0x58, 0xaa, - 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, - 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, - 0x31, 0xe2, 0x02, 0x22, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, - 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, - 0x3a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x3a, 0x3a, 0x56, - 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6e, 0x74, + 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x80, 0x01, 0x0a, 0x14, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, 0x6e, + 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x2f, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, + 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, 0x6f, + 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x1a, 0x37, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, + 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x43, + 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, 0x2a, 0x01, 0x42, 0xd7, 0x01, 0x0a, + 0x1a, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x36, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2f, 0x76, 0x31, 0x3b, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x76, 0x31, 0xa2, 0x02, + 0x03, 0x43, 0x50, 0x58, 0xaa, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x16, + 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, + 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x22, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x43, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, + 0x6f, 0x6c, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -7041,51 +7714,56 @@ func file_cosmos_protocolpool_v1_tx_proto_rawDescGZIP() []byte { return file_cosmos_protocolpool_v1_tx_proto_rawDescData } -var file_cosmos_protocolpool_v1_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 12) +var file_cosmos_protocolpool_v1_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 14) var file_cosmos_protocolpool_v1_tx_proto_goTypes = []interface{}{ - (*MsgFundCommunityPool)(nil), // 0: cosmos.protocolpool.v1.MsgFundCommunityPool - (*MsgFundCommunityPoolResponse)(nil), // 1: cosmos.protocolpool.v1.MsgFundCommunityPoolResponse - (*MsgCommunityPoolSpend)(nil), // 2: cosmos.protocolpool.v1.MsgCommunityPoolSpend - (*MsgCommunityPoolSpendResponse)(nil), // 3: cosmos.protocolpool.v1.MsgCommunityPoolSpendResponse - (*MsgSubmitBudgetProposal)(nil), // 4: cosmos.protocolpool.v1.MsgSubmitBudgetProposal - (*MsgSubmitBudgetProposalResponse)(nil), // 5: cosmos.protocolpool.v1.MsgSubmitBudgetProposalResponse - (*MsgClaimBudget)(nil), // 6: cosmos.protocolpool.v1.MsgClaimBudget - (*MsgClaimBudgetResponse)(nil), // 7: cosmos.protocolpool.v1.MsgClaimBudgetResponse - (*MsgCreateContinuousFund)(nil), // 8: cosmos.protocolpool.v1.MsgCreateContinuousFund - (*MsgCreateContinuousFundResponse)(nil), // 9: cosmos.protocolpool.v1.MsgCreateContinuousFundResponse - (*MsgCancelContinuousFund)(nil), // 10: cosmos.protocolpool.v1.MsgCancelContinuousFund - (*MsgCancelContinuousFundResponse)(nil), // 11: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse - (*v1beta1.Coin)(nil), // 12: cosmos.base.v1beta1.Coin - (*timestamppb.Timestamp)(nil), // 13: google.protobuf.Timestamp - (*durationpb.Duration)(nil), // 14: google.protobuf.Duration + (*MsgFundCommunityPool)(nil), // 0: cosmos.protocolpool.v1.MsgFundCommunityPool + (*MsgFundCommunityPoolResponse)(nil), // 1: cosmos.protocolpool.v1.MsgFundCommunityPoolResponse + (*MsgCommunityPoolSpend)(nil), // 2: cosmos.protocolpool.v1.MsgCommunityPoolSpend + (*MsgCommunityPoolSpendResponse)(nil), // 3: cosmos.protocolpool.v1.MsgCommunityPoolSpendResponse + (*MsgSubmitBudgetProposal)(nil), // 4: cosmos.protocolpool.v1.MsgSubmitBudgetProposal + (*MsgSubmitBudgetProposalResponse)(nil), // 5: cosmos.protocolpool.v1.MsgSubmitBudgetProposalResponse + (*MsgClaimBudget)(nil), // 6: cosmos.protocolpool.v1.MsgClaimBudget + (*MsgClaimBudgetResponse)(nil), // 7: cosmos.protocolpool.v1.MsgClaimBudgetResponse + (*MsgCreateContinuousFund)(nil), // 8: cosmos.protocolpool.v1.MsgCreateContinuousFund + (*MsgCreateContinuousFundResponse)(nil), // 9: cosmos.protocolpool.v1.MsgCreateContinuousFundResponse + (*MsgCancelContinuousFund)(nil), // 10: cosmos.protocolpool.v1.MsgCancelContinuousFund + (*MsgCancelContinuousFundResponse)(nil), // 11: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse + (*MsgWithdrawContinuousFund)(nil), // 12: cosmos.protocolpool.v1.MsgWithdrawContinuousFund + (*MsgWithdrawContinuousFundResponse)(nil), // 13: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse + (*v1beta1.Coin)(nil), // 14: cosmos.base.v1beta1.Coin + (*timestamppb.Timestamp)(nil), // 15: google.protobuf.Timestamp + (*durationpb.Duration)(nil), // 16: google.protobuf.Duration } var file_cosmos_protocolpool_v1_tx_proto_depIdxs = []int32{ - 12, // 0: cosmos.protocolpool.v1.MsgFundCommunityPool.amount:type_name -> cosmos.base.v1beta1.Coin - 12, // 1: cosmos.protocolpool.v1.MsgCommunityPoolSpend.amount:type_name -> cosmos.base.v1beta1.Coin - 12, // 2: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.total_budget:type_name -> cosmos.base.v1beta1.Coin - 13, // 3: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.start_time:type_name -> google.protobuf.Timestamp - 14, // 4: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.period:type_name -> google.protobuf.Duration - 12, // 5: cosmos.protocolpool.v1.MsgClaimBudgetResponse.amount:type_name -> cosmos.base.v1beta1.Coin - 12, // 6: cosmos.protocolpool.v1.MsgCreateContinuousFund.cap:type_name -> cosmos.base.v1beta1.Coin - 13, // 7: cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry:type_name -> google.protobuf.Timestamp - 13, // 8: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.canceled_time:type_name -> google.protobuf.Timestamp - 0, // 9: cosmos.protocolpool.v1.Msg.FundCommunityPool:input_type -> cosmos.protocolpool.v1.MsgFundCommunityPool - 2, // 10: cosmos.protocolpool.v1.Msg.CommunityPoolSpend:input_type -> cosmos.protocolpool.v1.MsgCommunityPoolSpend - 4, // 11: cosmos.protocolpool.v1.Msg.SubmitBudgetProposal:input_type -> cosmos.protocolpool.v1.MsgSubmitBudgetProposal - 6, // 12: cosmos.protocolpool.v1.Msg.ClaimBudget:input_type -> cosmos.protocolpool.v1.MsgClaimBudget - 8, // 13: cosmos.protocolpool.v1.Msg.CreateContinuousFund:input_type -> cosmos.protocolpool.v1.MsgCreateContinuousFund - 10, // 14: cosmos.protocolpool.v1.Msg.CancelContinuousFund:input_type -> cosmos.protocolpool.v1.MsgCancelContinuousFund - 1, // 15: cosmos.protocolpool.v1.Msg.FundCommunityPool:output_type -> cosmos.protocolpool.v1.MsgFundCommunityPoolResponse - 3, // 16: cosmos.protocolpool.v1.Msg.CommunityPoolSpend:output_type -> cosmos.protocolpool.v1.MsgCommunityPoolSpendResponse - 5, // 17: cosmos.protocolpool.v1.Msg.SubmitBudgetProposal:output_type -> cosmos.protocolpool.v1.MsgSubmitBudgetProposalResponse - 7, // 18: cosmos.protocolpool.v1.Msg.ClaimBudget:output_type -> cosmos.protocolpool.v1.MsgClaimBudgetResponse - 9, // 19: cosmos.protocolpool.v1.Msg.CreateContinuousFund:output_type -> cosmos.protocolpool.v1.MsgCreateContinuousFundResponse - 11, // 20: cosmos.protocolpool.v1.Msg.CancelContinuousFund:output_type -> cosmos.protocolpool.v1.MsgCancelContinuousFundResponse - 15, // [15:21] is the sub-list for method output_type - 9, // [9:15] is the sub-list for method input_type - 9, // [9:9] is the sub-list for extension type_name - 9, // [9:9] is the sub-list for extension extendee - 0, // [0:9] is the sub-list for field type_name + 14, // 0: cosmos.protocolpool.v1.MsgFundCommunityPool.amount:type_name -> cosmos.base.v1beta1.Coin + 14, // 1: cosmos.protocolpool.v1.MsgCommunityPoolSpend.amount:type_name -> cosmos.base.v1beta1.Coin + 14, // 2: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.total_budget:type_name -> cosmos.base.v1beta1.Coin + 15, // 3: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.start_time:type_name -> google.protobuf.Timestamp + 16, // 4: cosmos.protocolpool.v1.MsgSubmitBudgetProposal.period:type_name -> google.protobuf.Duration + 14, // 5: cosmos.protocolpool.v1.MsgClaimBudgetResponse.amount:type_name -> cosmos.base.v1beta1.Coin + 15, // 6: cosmos.protocolpool.v1.MsgCreateContinuousFund.expiry:type_name -> google.protobuf.Timestamp + 15, // 7: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.canceled_time:type_name -> google.protobuf.Timestamp + 14, // 8: cosmos.protocolpool.v1.MsgCancelContinuousFundResponse.withdrawn_allocated_fund:type_name -> cosmos.base.v1beta1.Coin + 14, // 9: cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse.amount:type_name -> cosmos.base.v1beta1.Coin + 0, // 10: cosmos.protocolpool.v1.Msg.FundCommunityPool:input_type -> cosmos.protocolpool.v1.MsgFundCommunityPool + 2, // 11: cosmos.protocolpool.v1.Msg.CommunityPoolSpend:input_type -> cosmos.protocolpool.v1.MsgCommunityPoolSpend + 4, // 12: cosmos.protocolpool.v1.Msg.SubmitBudgetProposal:input_type -> cosmos.protocolpool.v1.MsgSubmitBudgetProposal + 6, // 13: cosmos.protocolpool.v1.Msg.ClaimBudget:input_type -> cosmos.protocolpool.v1.MsgClaimBudget + 8, // 14: cosmos.protocolpool.v1.Msg.CreateContinuousFund:input_type -> cosmos.protocolpool.v1.MsgCreateContinuousFund + 12, // 15: cosmos.protocolpool.v1.Msg.WithdrawContinuousFund:input_type -> cosmos.protocolpool.v1.MsgWithdrawContinuousFund + 10, // 16: cosmos.protocolpool.v1.Msg.CancelContinuousFund:input_type -> cosmos.protocolpool.v1.MsgCancelContinuousFund + 1, // 17: cosmos.protocolpool.v1.Msg.FundCommunityPool:output_type -> cosmos.protocolpool.v1.MsgFundCommunityPoolResponse + 3, // 18: cosmos.protocolpool.v1.Msg.CommunityPoolSpend:output_type -> cosmos.protocolpool.v1.MsgCommunityPoolSpendResponse + 5, // 19: cosmos.protocolpool.v1.Msg.SubmitBudgetProposal:output_type -> cosmos.protocolpool.v1.MsgSubmitBudgetProposalResponse + 7, // 20: cosmos.protocolpool.v1.Msg.ClaimBudget:output_type -> cosmos.protocolpool.v1.MsgClaimBudgetResponse + 9, // 21: cosmos.protocolpool.v1.Msg.CreateContinuousFund:output_type -> cosmos.protocolpool.v1.MsgCreateContinuousFundResponse + 13, // 22: cosmos.protocolpool.v1.Msg.WithdrawContinuousFund:output_type -> cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse + 11, // 23: cosmos.protocolpool.v1.Msg.CancelContinuousFund:output_type -> cosmos.protocolpool.v1.MsgCancelContinuousFundResponse + 17, // [17:24] is the sub-list for method output_type + 10, // [10:17] is the sub-list for method input_type + 10, // [10:10] is the sub-list for extension type_name + 10, // [10:10] is the sub-list for extension extendee + 0, // [0:10] is the sub-list for field type_name } func init() { file_cosmos_protocolpool_v1_tx_proto_init() } @@ -7238,6 +7916,30 @@ func file_cosmos_protocolpool_v1_tx_proto_init() { return nil } } + file_cosmos_protocolpool_v1_tx_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawContinuousFund); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_protocolpool_v1_tx_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawContinuousFundResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -7245,7 +7947,7 @@ func file_cosmos_protocolpool_v1_tx_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_protocolpool_v1_tx_proto_rawDesc, NumEnums: 0, - NumMessages: 12, + NumMessages: 14, NumExtensions: 0, NumServices: 1, }, diff --git a/api/cosmos/protocolpool/v1/tx_grpc.pb.go b/api/cosmos/protocolpool/v1/tx_grpc.pb.go index dda2bc0427b2..07f61899feb4 100644 --- a/api/cosmos/protocolpool/v1/tx_grpc.pb.go +++ b/api/cosmos/protocolpool/v1/tx_grpc.pb.go @@ -19,12 +19,13 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - Msg_FundCommunityPool_FullMethodName = "/cosmos.protocolpool.v1.Msg/FundCommunityPool" - Msg_CommunityPoolSpend_FullMethodName = "/cosmos.protocolpool.v1.Msg/CommunityPoolSpend" - Msg_SubmitBudgetProposal_FullMethodName = "/cosmos.protocolpool.v1.Msg/SubmitBudgetProposal" - Msg_ClaimBudget_FullMethodName = "/cosmos.protocolpool.v1.Msg/ClaimBudget" - Msg_CreateContinuousFund_FullMethodName = "/cosmos.protocolpool.v1.Msg/CreateContinuousFund" - Msg_CancelContinuousFund_FullMethodName = "/cosmos.protocolpool.v1.Msg/CancelContinuousFund" + Msg_FundCommunityPool_FullMethodName = "/cosmos.protocolpool.v1.Msg/FundCommunityPool" + Msg_CommunityPoolSpend_FullMethodName = "/cosmos.protocolpool.v1.Msg/CommunityPoolSpend" + Msg_SubmitBudgetProposal_FullMethodName = "/cosmos.protocolpool.v1.Msg/SubmitBudgetProposal" + Msg_ClaimBudget_FullMethodName = "/cosmos.protocolpool.v1.Msg/ClaimBudget" + Msg_CreateContinuousFund_FullMethodName = "/cosmos.protocolpool.v1.Msg/CreateContinuousFund" + Msg_WithdrawContinuousFund_FullMethodName = "/cosmos.protocolpool.v1.Msg/WithdrawContinuousFund" + Msg_CancelContinuousFund_FullMethodName = "/cosmos.protocolpool.v1.Msg/CancelContinuousFund" ) // MsgClient is the client API for Msg service. @@ -45,6 +46,8 @@ type MsgClient interface { ClaimBudget(ctx context.Context, in *MsgClaimBudget, opts ...grpc.CallOption) (*MsgClaimBudgetResponse, error) // CreateContinuousFund defines a method to add funds continuously. CreateContinuousFund(ctx context.Context, in *MsgCreateContinuousFund, opts ...grpc.CallOption) (*MsgCreateContinuousFundResponse, error) + // WithdrawContinuousFund defines a method to withdraw continuous fund allocated. + WithdrawContinuousFund(ctx context.Context, in *MsgWithdrawContinuousFund, opts ...grpc.CallOption) (*MsgWithdrawContinuousFundResponse, error) // CancelContinuousFund defines a method for cancelling continuous fund. CancelContinuousFund(ctx context.Context, in *MsgCancelContinuousFund, opts ...grpc.CallOption) (*MsgCancelContinuousFundResponse, error) } @@ -102,6 +105,15 @@ func (c *msgClient) CreateContinuousFund(ctx context.Context, in *MsgCreateConti return out, nil } +func (c *msgClient) WithdrawContinuousFund(ctx context.Context, in *MsgWithdrawContinuousFund, opts ...grpc.CallOption) (*MsgWithdrawContinuousFundResponse, error) { + out := new(MsgWithdrawContinuousFundResponse) + err := c.cc.Invoke(ctx, Msg_WithdrawContinuousFund_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *msgClient) CancelContinuousFund(ctx context.Context, in *MsgCancelContinuousFund, opts ...grpc.CallOption) (*MsgCancelContinuousFundResponse, error) { out := new(MsgCancelContinuousFundResponse) err := c.cc.Invoke(ctx, Msg_CancelContinuousFund_FullMethodName, in, out, opts...) @@ -129,6 +141,8 @@ type MsgServer interface { ClaimBudget(context.Context, *MsgClaimBudget) (*MsgClaimBudgetResponse, error) // CreateContinuousFund defines a method to add funds continuously. CreateContinuousFund(context.Context, *MsgCreateContinuousFund) (*MsgCreateContinuousFundResponse, error) + // WithdrawContinuousFund defines a method to withdraw continuous fund allocated. + WithdrawContinuousFund(context.Context, *MsgWithdrawContinuousFund) (*MsgWithdrawContinuousFundResponse, error) // CancelContinuousFund defines a method for cancelling continuous fund. CancelContinuousFund(context.Context, *MsgCancelContinuousFund) (*MsgCancelContinuousFundResponse, error) mustEmbedUnimplementedMsgServer() @@ -153,6 +167,9 @@ func (UnimplementedMsgServer) ClaimBudget(context.Context, *MsgClaimBudget) (*Ms func (UnimplementedMsgServer) CreateContinuousFund(context.Context, *MsgCreateContinuousFund) (*MsgCreateContinuousFundResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateContinuousFund not implemented") } +func (UnimplementedMsgServer) WithdrawContinuousFund(context.Context, *MsgWithdrawContinuousFund) (*MsgWithdrawContinuousFundResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WithdrawContinuousFund not implemented") +} func (UnimplementedMsgServer) CancelContinuousFund(context.Context, *MsgCancelContinuousFund) (*MsgCancelContinuousFundResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CancelContinuousFund not implemented") } @@ -259,6 +276,24 @@ func _Msg_CreateContinuousFund_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +func _Msg_WithdrawContinuousFund_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWithdrawContinuousFund) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).WithdrawContinuousFund(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_WithdrawContinuousFund_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).WithdrawContinuousFund(ctx, req.(*MsgWithdrawContinuousFund)) + } + return interceptor(ctx, in, info, handler) +} + func _Msg_CancelContinuousFund_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCancelContinuousFund) if err := dec(in); err != nil { @@ -304,6 +339,10 @@ var Msg_ServiceDesc = grpc.ServiceDesc{ MethodName: "CreateContinuousFund", Handler: _Msg_CreateContinuousFund_Handler, }, + { + MethodName: "WithdrawContinuousFund", + Handler: _Msg_WithdrawContinuousFund_Handler, + }, { MethodName: "CancelContinuousFund", Handler: _Msg_CancelContinuousFund_Handler, diff --git a/api/cosmos/protocolpool/v1/types.pulsar.go b/api/cosmos/protocolpool/v1/types.pulsar.go index 90e099e44c0f..8d69f390f05c 100644 --- a/api/cosmos/protocolpool/v1/types.pulsar.go +++ b/api/cosmos/protocolpool/v1/types.pulsar.go @@ -928,6 +928,569 @@ func (x *fastReflection_Budget) ProtoMethods() *protoiface.Methods { } } +var ( + md_ContinuousFund protoreflect.MessageDescriptor + fd_ContinuousFund_recipient protoreflect.FieldDescriptor + fd_ContinuousFund_percentage protoreflect.FieldDescriptor + fd_ContinuousFund_expiry protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_protocolpool_v1_types_proto_init() + md_ContinuousFund = File_cosmos_protocolpool_v1_types_proto.Messages().ByName("ContinuousFund") + fd_ContinuousFund_recipient = md_ContinuousFund.Fields().ByName("recipient") + fd_ContinuousFund_percentage = md_ContinuousFund.Fields().ByName("percentage") + fd_ContinuousFund_expiry = md_ContinuousFund.Fields().ByName("expiry") +} + +var _ protoreflect.Message = (*fastReflection_ContinuousFund)(nil) + +type fastReflection_ContinuousFund ContinuousFund + +func (x *ContinuousFund) ProtoReflect() protoreflect.Message { + return (*fastReflection_ContinuousFund)(x) +} + +func (x *ContinuousFund) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_protocolpool_v1_types_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_ContinuousFund_messageType fastReflection_ContinuousFund_messageType +var _ protoreflect.MessageType = fastReflection_ContinuousFund_messageType{} + +type fastReflection_ContinuousFund_messageType struct{} + +func (x fastReflection_ContinuousFund_messageType) Zero() protoreflect.Message { + return (*fastReflection_ContinuousFund)(nil) +} +func (x fastReflection_ContinuousFund_messageType) New() protoreflect.Message { + return new(fastReflection_ContinuousFund) +} +func (x fastReflection_ContinuousFund_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_ContinuousFund +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_ContinuousFund) Descriptor() protoreflect.MessageDescriptor { + return md_ContinuousFund +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_ContinuousFund) Type() protoreflect.MessageType { + return _fastReflection_ContinuousFund_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_ContinuousFund) New() protoreflect.Message { + return new(fastReflection_ContinuousFund) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_ContinuousFund) Interface() protoreflect.ProtoMessage { + return (*ContinuousFund)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_ContinuousFund) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Recipient != "" { + value := protoreflect.ValueOfString(x.Recipient) + if !f(fd_ContinuousFund_recipient, value) { + return + } + } + if x.Percentage != "" { + value := protoreflect.ValueOfString(x.Percentage) + if !f(fd_ContinuousFund_percentage, value) { + return + } + } + if x.Expiry != nil { + value := protoreflect.ValueOfMessage(x.Expiry.ProtoReflect()) + if !f(fd_ContinuousFund_expiry, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_ContinuousFund) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + return x.Recipient != "" + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + return x.Percentage != "" + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + return x.Expiry != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ContinuousFund) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + x.Recipient = "" + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + x.Percentage = "" + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + x.Expiry = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_ContinuousFund) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + value := x.Recipient + return protoreflect.ValueOfString(value) + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + value := x.Percentage + return protoreflect.ValueOfString(value) + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + value := x.Expiry + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ContinuousFund) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + x.Recipient = value.Interface().(string) + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + x.Percentage = value.Interface().(string) + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + x.Expiry = value.Message().Interface().(*timestamppb.Timestamp) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ContinuousFund) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + if x.Expiry == nil { + x.Expiry = new(timestamppb.Timestamp) + } + return protoreflect.ValueOfMessage(x.Expiry.ProtoReflect()) + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + panic(fmt.Errorf("field recipient of message cosmos.protocolpool.v1.ContinuousFund is not mutable")) + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + panic(fmt.Errorf("field percentage of message cosmos.protocolpool.v1.ContinuousFund is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_ContinuousFund) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.protocolpool.v1.ContinuousFund.recipient": + return protoreflect.ValueOfString("") + case "cosmos.protocolpool.v1.ContinuousFund.percentage": + return protoreflect.ValueOfString("") + case "cosmos.protocolpool.v1.ContinuousFund.expiry": + m := new(timestamppb.Timestamp) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.protocolpool.v1.ContinuousFund")) + } + panic(fmt.Errorf("message cosmos.protocolpool.v1.ContinuousFund does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_ContinuousFund) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.protocolpool.v1.ContinuousFund", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_ContinuousFund) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ContinuousFund) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_ContinuousFund) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_ContinuousFund) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*ContinuousFund) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Recipient) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Percentage) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Expiry != nil { + l = options.Size(x.Expiry) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*ContinuousFund) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Expiry != nil { + encoded, err := options.Marshal(x.Expiry) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if len(x.Percentage) > 0 { + i -= len(x.Percentage) + copy(dAtA[i:], x.Percentage) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Percentage))) + i-- + dAtA[i] = 0x12 + } + if len(x.Recipient) > 0 { + i -= len(x.Recipient) + copy(dAtA[i:], x.Recipient) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Recipient))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*ContinuousFund) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ContinuousFund: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ContinuousFund: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Recipient = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Percentage", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Percentage = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Expiry", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Expiry == nil { + x.Expiry = ×tamppb.Timestamp{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Expiry); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 @@ -1044,6 +1607,61 @@ func (x *Budget) GetPeriod() *durationpb.Duration { return nil } +// ContinuousFund defines the fields of continuous fund proposal. +type ContinuousFund struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Recipient address of the account receiving funds. + Recipient string `protobuf:"bytes,1,opt,name=recipient,proto3" json:"recipient,omitempty"` + // Percentage is the percentage of funds to be allocated from Community pool. + Percentage string `protobuf:"bytes,2,opt,name=percentage,proto3" json:"percentage,omitempty"` + // Optional, if expiry is set, removes the state object when expired. + Expiry *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=expiry,proto3" json:"expiry,omitempty"` +} + +func (x *ContinuousFund) Reset() { + *x = ContinuousFund{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_protocolpool_v1_types_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ContinuousFund) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ContinuousFund) ProtoMessage() {} + +// Deprecated: Use ContinuousFund.ProtoReflect.Descriptor instead. +func (*ContinuousFund) Descriptor() ([]byte, []int) { + return file_cosmos_protocolpool_v1_types_proto_rawDescGZIP(), []int{1} +} + +func (x *ContinuousFund) GetRecipient() string { + if x != nil { + return x.Recipient + } + return "" +} + +func (x *ContinuousFund) GetPercentage() string { + if x != nil { + return x.Percentage + } + return "" +} + +func (x *ContinuousFund) GetExpiry() *timestamppb.Timestamp { + if x != nil { + return x.Expiry + } + return nil +} + var File_cosmos_protocolpool_v1_types_proto protoreflect.FileDescriptor var file_cosmos_protocolpool_v1_types_proto_rawDesc = []byte{ @@ -1089,21 +1707,35 @@ var file_cosmos_protocolpool_v1_types_proto_rawDesc = []byte{ 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x06, 0x70, - 0x65, 0x72, 0x69, 0x6f, 0x64, 0x42, 0xda, 0x01, 0x0a, 0x1a, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, - 0x6c, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x54, 0x79, 0x70, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x36, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2f, 0x76, 0x31, 0x3b, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x50, 0x58, - 0xaa, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, - 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, - 0x56, 0x31, 0xe2, 0x02, 0x22, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x3a, 0x3a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x3a, 0x3a, - 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x65, 0x72, 0x69, 0x6f, 0x64, 0x22, 0xd5, 0x01, 0x0a, 0x0e, 0x43, 0x6f, 0x6e, 0x74, 0x69, 0x6e, + 0x75, 0x6f, 0x75, 0x73, 0x46, 0x75, 0x6e, 0x64, 0x12, 0x36, 0x0a, 0x09, 0x72, 0x65, 0x63, 0x69, + 0x70, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, + 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, + 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, + 0x12, 0x51, 0x0a, 0x0a, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0a, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, + 0x61, 0x67, 0x65, 0x12, 0x38, 0x0a, 0x06, 0x65, 0x78, 0x70, 0x69, 0x72, 0x79, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, + 0x04, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x06, 0x65, 0x78, 0x70, 0x69, 0x72, 0x79, 0x42, 0xda, 0x01, + 0x0a, 0x1a, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x54, 0x79, + 0x70, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x36, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, + 0x2f, 0x76, 0x31, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, + 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x50, 0x58, 0xaa, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x2e, 0x56, + 0x31, 0xca, 0x02, 0x16, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x22, 0x43, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x5c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, + 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, + 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, + 0x6f, 0x6c, 0x70, 0x6f, 0x6f, 0x6c, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, } var ( @@ -1118,24 +1750,26 @@ func file_cosmos_protocolpool_v1_types_proto_rawDescGZIP() []byte { return file_cosmos_protocolpool_v1_types_proto_rawDescData } -var file_cosmos_protocolpool_v1_types_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_cosmos_protocolpool_v1_types_proto_msgTypes = make([]protoimpl.MessageInfo, 2) var file_cosmos_protocolpool_v1_types_proto_goTypes = []interface{}{ (*Budget)(nil), // 0: cosmos.protocolpool.v1.Budget - (*v1beta1.Coin)(nil), // 1: cosmos.base.v1beta1.Coin - (*timestamppb.Timestamp)(nil), // 2: google.protobuf.Timestamp - (*durationpb.Duration)(nil), // 3: google.protobuf.Duration + (*ContinuousFund)(nil), // 1: cosmos.protocolpool.v1.ContinuousFund + (*v1beta1.Coin)(nil), // 2: cosmos.base.v1beta1.Coin + (*timestamppb.Timestamp)(nil), // 3: google.protobuf.Timestamp + (*durationpb.Duration)(nil), // 4: google.protobuf.Duration } var file_cosmos_protocolpool_v1_types_proto_depIdxs = []int32{ - 1, // 0: cosmos.protocolpool.v1.Budget.total_budget:type_name -> cosmos.base.v1beta1.Coin - 1, // 1: cosmos.protocolpool.v1.Budget.claimed_amount:type_name -> cosmos.base.v1beta1.Coin - 2, // 2: cosmos.protocolpool.v1.Budget.start_time:type_name -> google.protobuf.Timestamp - 2, // 3: cosmos.protocolpool.v1.Budget.next_claim_from:type_name -> google.protobuf.Timestamp - 3, // 4: cosmos.protocolpool.v1.Budget.period:type_name -> google.protobuf.Duration - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name + 2, // 0: cosmos.protocolpool.v1.Budget.total_budget:type_name -> cosmos.base.v1beta1.Coin + 2, // 1: cosmos.protocolpool.v1.Budget.claimed_amount:type_name -> cosmos.base.v1beta1.Coin + 3, // 2: cosmos.protocolpool.v1.Budget.start_time:type_name -> google.protobuf.Timestamp + 3, // 3: cosmos.protocolpool.v1.Budget.next_claim_from:type_name -> google.protobuf.Timestamp + 4, // 4: cosmos.protocolpool.v1.Budget.period:type_name -> google.protobuf.Duration + 3, // 5: cosmos.protocolpool.v1.ContinuousFund.expiry:type_name -> google.protobuf.Timestamp + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name } func init() { file_cosmos_protocolpool_v1_types_proto_init() } @@ -1156,6 +1790,18 @@ func file_cosmos_protocolpool_v1_types_proto_init() { return nil } } + file_cosmos_protocolpool_v1_types_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ContinuousFund); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -1163,7 +1809,7 @@ func file_cosmos_protocolpool_v1_types_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_protocolpool_v1_types_proto_rawDesc, NumEnums: 0, - NumMessages: 1, + NumMessages: 2, NumExtensions: 0, NumServices: 0, }, diff --git a/proto/cosmos/protocolpool/v1/genesis.proto b/proto/cosmos/protocolpool/v1/genesis.proto new file mode 100644 index 000000000000..5f928a569749 --- /dev/null +++ b/proto/cosmos/protocolpool/v1/genesis.proto @@ -0,0 +1,14 @@ +syntax = "proto3"; +package cosmos.protocolpool.v1; + +option go_package = "cosmossdk.io/x/protocolpool/types"; + +import "cosmos/protocolpool/v1/types.proto"; + +// GenesisState defines the protocolpool module's genesis state. +message GenesisState { + // ContinuousFund defines the continuous funds at genesis. + repeated ContinuousFund continuous_fund = 1; + // Budget defines the budget proposals at genesis. + repeated Budget budget = 2; +} diff --git a/proto/cosmos/protocolpool/v1/tx.proto b/proto/cosmos/protocolpool/v1/tx.proto index ac742c013a52..6461f9bca1af 100644 --- a/proto/cosmos/protocolpool/v1/tx.proto +++ b/proto/cosmos/protocolpool/v1/tx.proto @@ -33,6 +33,9 @@ service Msg { // CreateContinuousFund defines a method to add funds continuously. rpc CreateContinuousFund(MsgCreateContinuousFund) returns (MsgCreateContinuousFundResponse); + // WithdrawContinuousFund defines a method to withdraw continuous fund allocated. + rpc WithdrawContinuousFund(MsgWithdrawContinuousFund) returns (MsgWithdrawContinuousFundResponse); + // CancelContinuousFund defines a method for cancelling continuous fund. rpc CancelContinuousFund(MsgCancelContinuousFund) returns (MsgCancelContinuousFundResponse); } @@ -112,28 +115,18 @@ message MsgClaimBudgetResponse { message MsgCreateContinuousFund { option (cosmos.msg.v1.signer) = "authority"; - // Title is the title of the funds. - string title = 1; - // Description of the funds. - string description = 2; // Authority is the address that controls the module (defaults to x/gov unless overwritten). - string authority = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // Recipient address of the account receiving funds. - string recipient = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Metadata is any arbitrary metadata attached. - string metadata = 5; - // Percentage is the percentage of funds to be allocated from Community pool share on block by block, - // till the `cap` is reached or expired. - string percentage = 6 [ + string recipient = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // Percentage is the percentage of funds to be allocated from Community pool. + string percentage = 3 [ (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false ]; - // Cap is the capital amount, which when its met funds are no longer distributed. - repeated cosmos.base.v1beta1.Coin cap = 7 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; // Optional, if expiry is set, removes the state object when expired. - google.protobuf.Timestamp expiry = 8 [(gogoproto.stdtime) = true]; + google.protobuf.Timestamp expiry = 4 [(gogoproto.stdtime) = true]; } // MsgCreateContinuousFundResponse defines the response to executing a @@ -159,4 +152,25 @@ message MsgCancelContinuousFundResponse { uint64 canceled_height = 2; // RecipientAddress is the account address of recipient whose funds are cancelled. string recipient_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // withdrawnAllocatedFund represents the fund allocated to this recipient (if any) that have not been withdrawn yet, + // before a cancellation request has been initiated. + // It involves first withdrawing the funds and then canceling the request. + cosmos.base.v1beta1.Coin withdrawn_allocated_fund = 4 + [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; + ; } + +// MsgWithdrawContinuousFund defines a message for withdrawing the continuous fund allocated to it. +message MsgWithdrawContinuousFund { + option (cosmos.msg.v1.signer) = "recipient_address"; + string recipient_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; +} + +// MsgWithdrawContinuousFundResponse defines the response to executing a +// MsgWithdrawContinuousFund message. +message MsgWithdrawContinuousFundResponse { + cosmos.base.v1beta1.Coin amount = 1 + [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; + ; +} + diff --git a/proto/cosmos/protocolpool/v1/types.proto b/proto/cosmos/protocolpool/v1/types.proto index d7c98fed7f3f..94d1b30734f7 100644 --- a/proto/cosmos/protocolpool/v1/types.proto +++ b/proto/cosmos/protocolpool/v1/types.proto @@ -30,4 +30,18 @@ message Budget { // For example, if a period is set to 3600, it represents an action that // should occur every hour (3600 seconds). google.protobuf.Duration period = 8 [(gogoproto.stdduration) = true]; -} \ No newline at end of file +} + +// ContinuousFund defines the fields of continuous fund proposal. +message ContinuousFund { + // Recipient address of the account receiving funds. + string recipient = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // Percentage is the percentage of funds to be allocated from Community pool. + string percentage = 2 [ + (cosmos_proto.scalar) = "cosmos.Dec", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", + (gogoproto.nullable) = false + ]; + // Optional, if expiry is set, removes the state object when expired. + google.protobuf.Timestamp expiry = 3 [(gogoproto.stdtime) = true]; +} diff --git a/simapp/app.go b/simapp/app.go index 7007d9a62efe..bb31d24f8445 100644 --- a/simapp/app.go +++ b/simapp/app.go @@ -333,7 +333,7 @@ func NewSimApp( ) app.MintKeeper = mintkeeper.NewKeeper(appCodec, runtime.NewKVStoreService(keys[minttypes.StoreKey]), app.StakingKeeper, app.AuthKeeper, app.BankKeeper, authtypes.FeeCollectorName, authtypes.NewModuleAddress(govtypes.ModuleName).String()) - app.PoolKeeper = poolkeeper.NewKeeper(appCodec, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), app.AuthKeeper, app.BankKeeper, authtypes.NewModuleAddress(govtypes.ModuleName).String()) + app.PoolKeeper = poolkeeper.NewKeeper(appCodec, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), app.AuthKeeper, app.BankKeeper, app.StakingKeeper, authtypes.NewModuleAddress(govtypes.ModuleName).String()) app.DistrKeeper = distrkeeper.NewKeeper(appCodec, runtime.NewKVStoreService(keys[distrtypes.StoreKey]), app.AuthKeeper, app.BankKeeper, app.StakingKeeper, app.PoolKeeper, authtypes.FeeCollectorName, authtypes.NewModuleAddress(govtypes.ModuleName).String()) diff --git a/simapp/app_config.go b/simapp/app_config.go index 7994125320c2..ce7cb08bae7f 100644 --- a/simapp/app_config.go +++ b/simapp/app_config.go @@ -152,6 +152,7 @@ var ( upgradetypes.ModuleName, vestingtypes.ModuleName, circuittypes.ModuleName, + pooltypes.ModuleName, }, // When ExportGenesis is not specified, the export genesis module order // is equal to the init genesis order diff --git a/tests/integration/distribution/keeper/msg_server_test.go b/tests/integration/distribution/keeper/msg_server_test.go index e03280f4bc52..0fb8f2be6f7d 100644 --- a/tests/integration/distribution/keeper/msg_server_test.go +++ b/tests/integration/distribution/keeper/msg_server_test.go @@ -108,7 +108,7 @@ func initFixture(t *testing.T) *fixture { require.NoError(t, stakingKeeper.Params.Set(newCtx, stakingtypes.DefaultParams())) poolKeeper := poolkeeper.NewKeeper( - cdc, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), accountKeeper, bankKeeper, authority.String(), + cdc, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), accountKeeper, bankKeeper, stakingKeeper, authority.String(), ) distrKeeper := distrkeeper.NewKeeper( diff --git a/tests/integration/gov/keeper/keeper_test.go b/tests/integration/gov/keeper/keeper_test.go index 80977611166e..edb4f54046bd 100644 --- a/tests/integration/gov/keeper/keeper_test.go +++ b/tests/integration/gov/keeper/keeper_test.go @@ -92,7 +92,7 @@ func initFixture(tb testing.TB) *fixture { stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr)) - poolKeeper := poolkeeper.NewKeeper(cdc, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), accountKeeper, bankKeeper, authority.String()) + poolKeeper := poolkeeper.NewKeeper(cdc, runtime.NewKVStoreService(keys[pooltypes.StoreKey]), accountKeeper, bankKeeper, stakingKeeper, authority.String()) // set default staking params err := stakingKeeper.Params.Set(newCtx, stakingtypes.DefaultParams()) diff --git a/testutil/configurator/configurator.go b/testutil/configurator/configurator.go index 336e4ef1459b..b6e13d8e7da6 100644 --- a/testutil/configurator/configurator.go +++ b/testutil/configurator/configurator.go @@ -105,6 +105,7 @@ func defaultConfig() *Config { testutil.UpgradeModuleName, "vesting", testutil.CircuitModuleName, + testutil.ProtocolPoolModuleName, }, setInitGenesis: true, } diff --git a/x/accounts/go.mod b/x/accounts/go.mod index da29c0247c0f..0c461991a9a9 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -6,6 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 + github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/cosmos/cosmos-sdk v0.51.0 github.com/cosmos/gogoproto v1.4.11 github.com/grpc-ecosystem/grpc-gateway v1.16.0 @@ -44,7 +45,6 @@ require ( github.com/cometbft/cometbft-db v0.8.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-db v1.0.0 // indirect - github.com/cosmos/cosmos-proto v1.0.0-beta.3 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect github.com/cosmos/iavl v1.0.0 // indirect diff --git a/x/distribution/keeper/allocation.go b/x/distribution/keeper/allocation.go index 14bd0321d3d1..52cb89480281 100644 --- a/x/distribution/keeper/allocation.go +++ b/x/distribution/keeper/allocation.go @@ -78,6 +78,11 @@ func (k Keeper) AllocateTokens(ctx context.Context, totalPreviousPower int64, bo return err } + // set ToDistribute in protocolpool to keep track of continuous funds distribution + if err := k.poolKeeper.SetToDistribute(ctx, amt, k.GetAuthority()); err != nil { + return err + } + if err := k.FeePool.Set(ctx, types.FeePool{DecimalPool: feePool.DecimalPool.Add(re...)}); err != nil { return err } diff --git a/x/distribution/keeper/allocation_test.go b/x/distribution/keeper/allocation_test.go index e88f9df2acd0..a0b2b039d79d 100644 --- a/x/distribution/keeper/allocation_test.go +++ b/x/distribution/keeper/allocation_test.go @@ -169,6 +169,7 @@ func TestAllocateTokensToManyValidators(t *testing.T) { bankKeeper.EXPECT().GetAllBalances(gomock.Any(), feeCollectorAcc.GetAddress()).Return(fees) bankKeeper.EXPECT().SendCoinsFromModuleToModule(gomock.Any(), "fee_collector", disttypes.ModuleName, fees) bankKeeper.EXPECT().SendCoinsFromModuleToModule(gomock.Any(), disttypes.ModuleName, disttypes.ProtocolPoolModuleName, sdk.Coins{{Denom: sdk.DefaultBondDenom, Amount: math.NewInt(2)}}) // 2 community pool coins + poolKeeper.EXPECT().SetToDistribute(ctx, gomock.Any(), gomock.Any()) votes := []comet.VoteInfo{ { @@ -310,6 +311,7 @@ func TestAllocateTokensTruncation(t *testing.T) { bankKeeper.EXPECT().GetAllBalances(gomock.Any(), feeCollectorAcc.GetAddress()).Return(fees) bankKeeper.EXPECT().SendCoinsFromModuleToModule(gomock.Any(), "fee_collector", disttypes.ModuleName, fees) bankKeeper.EXPECT().SendCoinsFromModuleToModule(gomock.Any(), disttypes.ModuleName, disttypes.ProtocolPoolModuleName, gomock.Any()) // something is sent to community pool + poolKeeper.EXPECT().SetToDistribute(ctx, gomock.Any(), gomock.Any()) votes := []comet.VoteInfo{ { diff --git a/x/distribution/testutil/expected_keepers_mocks.go b/x/distribution/testutil/expected_keepers_mocks.go index f68140aabfba..e92ed7d0e12e 100644 --- a/x/distribution/testutil/expected_keepers_mocks.go +++ b/x/distribution/testutil/expected_keepers_mocks.go @@ -292,6 +292,20 @@ func (mr *MockPoolKeeperMockRecorder) GetCommunityPool(ctx interface{}) *gomock. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetCommunityPool", reflect.TypeOf((*MockPoolKeeper)(nil).GetCommunityPool), ctx) } +// SetToDistribute mocks base method. +func (m *MockPoolKeeper) SetToDistribute(ctx context.Context, amount types0.Coins, addr string) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SetToDistribute", ctx, amount, addr) + ret0, _ := ret[0].(error) + return ret0 +} + +// SetToDistribute indicates an expected call of SetToDistribute. +func (mr *MockPoolKeeperMockRecorder) SetToDistribute(ctx, amount, addr interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetToDistribute", reflect.TypeOf((*MockPoolKeeper)(nil).SetToDistribute), ctx, amount, addr) +} + // MockStakingKeeper is a mock of StakingKeeper interface. type MockStakingKeeper struct { ctrl *gomock.Controller diff --git a/x/distribution/types/expected_keepers.go b/x/distribution/types/expected_keepers.go index 1d6aefe2201e..4c4b3248f50c 100644 --- a/x/distribution/types/expected_keepers.go +++ b/x/distribution/types/expected_keepers.go @@ -38,6 +38,7 @@ type PoolKeeper interface { FundCommunityPool(ctx context.Context, amount sdk.Coins, sender sdk.AccAddress) error DistributeFromCommunityPool(ctx context.Context, amount sdk.Coins, receiveAddr sdk.AccAddress) error GetCommunityPool(ctx context.Context) (sdk.Coins, error) + SetToDistribute(ctx context.Context, amount sdk.Coins, addr string) error } // StakingKeeper expected staking keeper (noalias) diff --git a/x/gov/client/cli/prompt.go b/x/gov/client/cli/prompt.go index b2fcca629ee2..8ab8a823cdcb 100644 --- a/x/gov/client/cli/prompt.go +++ b/x/gov/client/cli/prompt.go @@ -49,6 +49,10 @@ var suggestedProposalTypes = []proposalType{ Name: "submit-budget-proposal", MsgType: "/cosmos.protocolpool.v1.MsgSubmitBudgetProposal", }, + { + Name: "create-continuous-fund", + MsgType: "/cosmos.protocolpool.v1.MsgCreateContinuousFund", + }, { Name: proposalOther, MsgType: "", // user will input the message type diff --git a/x/protocolpool/README.md b/x/protocolpool/README.md index 3b250f0f9e88..c32ee745a254 100644 --- a/x/protocolpool/README.md +++ b/x/protocolpool/README.md @@ -55,6 +55,25 @@ ClaimBudget is a message used to claim funds from a previously submitted budget ``` +### CreateContinuousFund + +CreateContinuousFund is a message used to initiate a continuous fund for a specific recipient. The proposed percentage of funds will be distributed only on withdraw request for the recipient. The fund distribution continues until expiry time is reached or continuous fund request is canceled. +NOTE: This feature is designed to work with the SDK's default bond denom. + +```protobuf + // CreateContinuousFund defines a method to add funds continuously. + rpc CreateContinuousFund(MsgCreateContinuousFund) returns (MsgCreateContinuousFundResponse); +``` + +### CancelContinuousFund + +CancelContinuousFund is a message used to cancel an existing continuous fund proposal for a specific recipient. Cancelling a continuous fund stops further distribution of funds, and the state object is removed from storage. + +```protobuf + // CancelContinuousFund defines a method for cancelling continuous fund. + rpc CancelContinuousFund(MsgCancelContinuousFund) returns (MsgCancelContinuousFundResponse); +``` + ## Messages ### MsgFundCommunityPool @@ -79,7 +98,7 @@ func (k Keeper) FundCommunityPool(ctx context.Context, amount sdk.Coins, sender ### MsgCommunityPoolSpend -This message distributes funds from the protocolpool module account to the recipient using `DistributeFromFeePool` keeper method. +This message distributes funds from the protocolpool module account to the recipient using `DistributeFromCommunityPool` keeper method. ```protobuf reference https://github.com/cosmos/cosmos-sdk/blob/97724493d792517ba2be8969078b5f92ad04d79c/proto/cosmos/protocolpool/v1/tx.proto#L47-L58 @@ -91,7 +110,7 @@ The message will fail under the following conditions: * The `recipient` address is restricted ```go -func (k Keeper) DistributeFromFeePool(ctx context.Context, amount sdk.Coins, receiveAddr sdk.AccAddress) error { +func (k Keeper) DistributeFromCommunityPool(ctx context.Context, amount sdk.Coins, receiveAddr sdk.AccAddress) error { return k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, receiveAddr, amount) } ``` @@ -139,6 +158,44 @@ The message will fail under the following conditions: https://github.com/cosmos/cosmos-sdk/blob/97724493d792517ba2be8969078b5f92ad04d79c/x/protocolpool/keeper/msg_server.go#L25-L37 ``` +### MsgCreateContinuousFund + +This message is used to create a continuous fund for a specific recipient. The proposed percentage of funds will be distributed only on withdraw request for the recipient. This fund distribution continues until expiry time is reached or continuous fund request is canceled. + +```protobuf reference +https://github.com/cosmos/cosmos-sdk/blob/44985ec56557e2d5b763c8676fabbed971f157ba/proto/cosmos/protocolpool/v1/tx.proto#L111-L130 +``` + +The message will fail under the following conditions: + +- The recipient address is empty or restricted. +- The percentage is zero/negative/greater than one. +- The Expiry time is less than the current block time. + +:::warning +If two continuous fund proposals to the same address are created, the previous ContinuousFund would be updated with the new ContinuousFund. +::: + +```go reference +https://github.com/cosmos/cosmos-sdk/blob/44985ec56557e2d5b763c8676fabbed971f157ba/x/protocolpool/keeper/msg_server.go#L109-L140 +``` + +### MsgCancelContinuousFund + +This message is used to cancel an existing continuous fund proposal for a specific recipient. Once canceled, the continuous fund will no longer distribute funds at each end block, and the state object will be removed. Users should be cautious when canceling continuous funds, as it may affect the planned distribution for the recipient. + +```protobuf reference +https://github.com/cosmos/cosmos-sdk/blob/44985ec56557e2d5b763c8676fabbed971f157ba/proto/cosmos/protocolpool/v1/tx.proto#L136-L144 +``` + +The message will fail under the following conditions: + +- The recipient address is empty or restricted. +- The ContinuousFund for the recipient does not exist. + +```go reference +https://github.com/cosmos/cosmos-sdk/blob/44985ec56557e2d5b763c8676fabbed971f157ba/x/protocolpool/keeper/msg_server.go#L142-L174 +``` ## Client diff --git a/x/protocolpool/autocli.go b/x/protocolpool/autocli.go index 619aa36fbd88..d6b2a0471b33 100644 --- a/x/protocolpool/autocli.go +++ b/x/protocolpool/autocli.go @@ -44,7 +44,7 @@ func (am AppModule) AutoCLIOptions() *autocliv1.ModuleOptions { RpcMethod: "SubmitBudgetProposal", Use: "submit-budget-proposal [recipient] [total-budget] [start-time] [tranches] [period]", Short: "Submit a budget proposal", - Example: fmt.Sprintf(`$ %s tx protocolpool submit-budget-proposal cosmos1... 1000000uatom 1600000000 10 1000 --from mykey`, version.AppName), + Example: fmt.Sprintf(`$ %s tx protocolpool submit-budget-proposal cosmos1... 1000000uatom 2023-10-31T12:34:56.789Z 10 1000 --from mykey`, version.AppName), PositionalArgs: []*autocliv1.PositionalArgDescriptor{ {ProtoField: "recipient_address"}, {ProtoField: "total_budget"}, @@ -60,6 +60,35 @@ func (am AppModule) AutoCLIOptions() *autocliv1.ModuleOptions { Example: fmt.Sprintf(`$ %s tx protocolpool claim-budget cosmos1... --from mykey`, version.AppName), PositionalArgs: []*autocliv1.PositionalArgDescriptor{{ProtoField: "recipient_address"}}, }, + { + RpcMethod: "CreateContinuousFund", + Use: "create-continuous-fund [recipient] [percentage] ", + Short: "Create continuous fund for a recipient with optional expiry", + Example: fmt.Sprintf(`$ %s tx protocolpool create-continuous-fund cosmos1... 0.2 2023-11-31T12:34:56.789Z --from mykey`, version.AppName), + PositionalArgs: []*autocliv1.PositionalArgDescriptor{ + {ProtoField: "recipient"}, + {ProtoField: "percentage"}, + {ProtoField: "expiry", Optional: true}, + }, + GovProposal: true, + }, + { + RpcMethod: "WithdrawContinuousFund", + Use: "withdraw-continuous-fund [recipient]", + Short: "Withdraw continuous fund allocated to the recipient", + Example: fmt.Sprintf(`$ %s tx protocolpool withdraw-continuous-fund cosmos1... --from mykey`, version.AppName), + PositionalArgs: []*autocliv1.PositionalArgDescriptor{{ProtoField: "recipient_address"}}, + }, + { + RpcMethod: "CancelContinuousFund", + Use: "cancel-continuous-fund [recipient_address]", + Short: "Cancel continuous fund for a specific recipient", + Example: fmt.Sprintf(`$ %s tx protocolpool cancel-continuous-fund cosmos1... --from mykey`, version.AppName), + PositionalArgs: []*autocliv1.PositionalArgDescriptor{ + {ProtoField: "recipient_address"}, + }, + GovProposal: true, + }, }, }, } diff --git a/x/protocolpool/keeper/genesis.go b/x/protocolpool/keeper/genesis.go new file mode 100644 index 000000000000..bd29d4afce16 --- /dev/null +++ b/x/protocolpool/keeper/genesis.go @@ -0,0 +1,83 @@ +package keeper + +import ( + "context" + "fmt" + + "cosmossdk.io/x/protocolpool/types" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +func (k Keeper) InitGenesis(ctx context.Context, data *types.GenesisState) error { + sdkCtx := sdk.UnwrapSDKContext(ctx) + currentTime := sdkCtx.BlockTime() + for _, cf := range data.ContinuousFund { + // ignore expired ContinuousFunds + if cf.Expiry != nil && cf.Expiry.Before(currentTime) { + continue + } + + recipientAddress, err := k.authKeeper.AddressCodec().StringToBytes(cf.Recipient) + if err != nil { + return fmt.Errorf("failed to decode recipient address: %w", err) + } + if err := k.ContinuousFund.Set(ctx, recipientAddress, *cf); err != nil { + return fmt.Errorf("failed to set continuous fund for recipient %s: %w", recipientAddress, err) + } + } + for _, budget := range data.Budget { + // Validate StartTime + if budget.StartTime.IsZero() || budget.StartTime == nil { + budget.StartTime = ¤tTime + } + // ignore budget with start time < currentTime + if budget.StartTime != nil && budget.StartTime.Before(currentTime) { + continue + } + + recipientAddress, err := k.authKeeper.AddressCodec().StringToBytes(budget.RecipientAddress) + if err != nil { + return fmt.Errorf("failed to decode recipient address: %w", err) + } + if err = k.BudgetProposal.Set(ctx, recipientAddress, *budget); err != nil { + return fmt.Errorf("failed to set budget for recipient %s: %w", recipientAddress, err) + } + } + return nil +} + +func (k Keeper) ExportGenesis(ctx context.Context) (*types.GenesisState, error) { + var cf []*types.ContinuousFund + err := k.ContinuousFund.Walk(ctx, nil, func(key sdk.AccAddress, value types.ContinuousFund) (stop bool, err error) { + cf = append(cf, &types.ContinuousFund{ + Recipient: key.String(), + Percentage: value.Percentage, + Expiry: value.Expiry, + }) + return false, nil + }) + if err != nil { + return nil, err + } + + var budget []*types.Budget + err = k.BudgetProposal.Walk(ctx, nil, func(key sdk.AccAddress, value types.Budget) (stop bool, err error) { + budget = append(budget, &types.Budget{ + RecipientAddress: key.String(), + TotalBudget: value.TotalBudget, + ClaimedAmount: value.ClaimedAmount, + StartTime: value.StartTime, + NextClaimFrom: value.NextClaimFrom, + Tranches: value.Tranches, + TranchesLeft: value.TranchesLeft, + Period: value.Period, + }) + return false, nil + }) + if err != nil { + return nil, err + } + + return types.NewGenesisState(cf, budget), nil +} diff --git a/x/protocolpool/keeper/grpc_query_test.go b/x/protocolpool/keeper/grpc_query_test.go index 0781f447bc4f..98aa478f70bd 100644 --- a/x/protocolpool/keeper/grpc_query_test.go +++ b/x/protocolpool/keeper/grpc_query_test.go @@ -4,14 +4,12 @@ import ( "time" "cosmossdk.io/math" - "cosmossdk.io/x/protocolpool/keeper" "cosmossdk.io/x/protocolpool/types" sdk "github.com/cosmos/cosmos-sdk/types" ) func (suite *KeeperTestSuite) TestUnclaimedBudget() { - queryServer := keeper.NewQuerier(suite.poolKeeper) startTime := suite.ctx.BlockTime().Add(-70 * time.Second) period := time.Duration(60) * time.Second zeroCoin := sdk.NewCoin("foo", math.ZeroInt()) @@ -112,7 +110,7 @@ func (suite *KeeperTestSuite) TestUnclaimedBudget() { if tc.preRun != nil { tc.preRun() } - resp, err := queryServer.UnclaimedBudget(suite.ctx, tc.req) + resp, err := suite.queryServer.UnclaimedBudget(suite.ctx, tc.req) if tc.expErr { suite.Require().Error(err) suite.Require().Contains(err.Error(), tc.expErrMsg) diff --git a/x/protocolpool/keeper/keeper.go b/x/protocolpool/keeper/keeper.go index 1ef7be7d16ff..abac09d30841 100644 --- a/x/protocolpool/keeper/keeper.go +++ b/x/protocolpool/keeper/keeper.go @@ -1,6 +1,7 @@ package keeper import ( + "bytes" "context" "errors" "fmt" @@ -19,9 +20,10 @@ import ( ) type Keeper struct { - storeService storetypes.KVStoreService - authKeeper types.AccountKeeper - bankKeeper types.BankKeeper + storeService storetypes.KVStoreService + authKeeper types.AccountKeeper + bankKeeper types.BankKeeper + stakingKeeper types.StakingKeeper cdc codec.BinaryCodec @@ -30,10 +32,17 @@ type Keeper struct { // State Schema collections.Schema BudgetProposal collections.Map[sdk.AccAddress, types.Budget] + ContinuousFund collections.Map[sdk.AccAddress, types.ContinuousFund] + // RecipientFundPercentage key: RecipientAddr | value: Percentage in math.Int + RecipientFundPercentage collections.Map[sdk.AccAddress, math.Int] + // RecipientFundDistribution key: RecipientAddr | value: Claimable amount + RecipientFundDistribution collections.Map[sdk.AccAddress, math.Int] + // ToDistribute is to keep track of funds distributed + ToDistribute collections.Item[math.Int] } func NewKeeper(cdc codec.BinaryCodec, storeService storetypes.KVStoreService, - ak types.AccountKeeper, bk types.BankKeeper, authority string, + ak types.AccountKeeper, bk types.BankKeeper, sk types.StakingKeeper, authority string, ) Keeper { // ensure pool module account is set if addr := ak.GetModuleAddress(types.ModuleName); addr == nil { @@ -42,12 +51,17 @@ func NewKeeper(cdc codec.BinaryCodec, storeService storetypes.KVStoreService, sb := collections.NewSchemaBuilder(storeService) keeper := Keeper{ - storeService: storeService, - authKeeper: ak, - bankKeeper: bk, - cdc: cdc, - authority: authority, - BudgetProposal: collections.NewMap(sb, types.BudgetKey, "budget", sdk.AccAddressKey, codec.CollValue[types.Budget](cdc)), + storeService: storeService, + authKeeper: ak, + bankKeeper: bk, + stakingKeeper: sk, + cdc: cdc, + authority: authority, + BudgetProposal: collections.NewMap(sb, types.BudgetKey, "budget", sdk.AccAddressKey, codec.CollValue[types.Budget](cdc)), + ContinuousFund: collections.NewMap(sb, types.ContinuousFundKey, "continuous_fund", sdk.AccAddressKey, codec.CollValue[types.ContinuousFund](cdc)), + RecipientFundPercentage: collections.NewMap(sb, types.RecipientFundPercentageKey, "recipient_fund_percentage", sdk.AccAddressKey, sdk.IntValue), + RecipientFundDistribution: collections.NewMap(sb, types.RecipientFundDistributionKey, "recipient_fund_distribution", sdk.AccAddressKey, sdk.IntValue), + ToDistribute: collections.NewItem(sb, types.ToDistributeKey, "to_distribute", sdk.IntValue), } schema, err := sb.Build() @@ -90,6 +104,163 @@ func (k Keeper) GetCommunityPool(ctx context.Context) (sdk.Coins, error) { return k.bankKeeper.GetAllBalances(ctx, moduleAccount.GetAddress()), nil } +func (k Keeper) withdrawContinuousFund(ctx context.Context, recipient sdk.AccAddress) (sdk.Coin, error) { + sdkCtx := sdk.UnwrapSDKContext(ctx) + cf, err := k.ContinuousFund.Get(ctx, recipient) + if err != nil { + if errors.Is(err, collections.ErrNotFound) { + return sdk.Coin{}, fmt.Errorf("no continuous fund found for recipient: %s", recipient.String()) + } + } + if cf.Expiry != nil && cf.Expiry.Before(sdkCtx.HeaderInfo().Time) { + return sdk.Coin{}, fmt.Errorf("cannot withdraw continuous funds: continuous fund expired for recipient: %s", recipient.String()) + } + + toDistributeAmount, err := k.ToDistribute.Get(ctx) + if err != nil { + return sdk.Coin{}, err + } + + if !toDistributeAmount.Equal(math.ZeroInt()) { + err = k.iterateAndUpdateFundsDistribution(ctx, toDistributeAmount) + if err != nil { + return sdk.Coin{}, fmt.Errorf("error while iterating all the continuous funds: %w", err) + } + } + + // withdraw continuous fund + withdrawnAmount, err := k.withdrawRecipientFunds(ctx, recipient) + if err != nil { + return sdk.Coin{}, fmt.Errorf("error while withdrawing recipient funds for recipient: %s", recipient.String()) + } + + return withdrawnAmount, nil +} + +func (k Keeper) withdrawRecipientFunds(ctx context.Context, recipient sdk.AccAddress) (sdk.Coin, error) { + // get allocated continuous fund + fundsAllocated, err := k.RecipientFundDistribution.Get(ctx, recipient) + if err != nil { + if errors.Is(err, collections.ErrNotFound) { + return sdk.Coin{}, types.ErrNoRecipientFund + } + return sdk.Coin{}, err + } + + denom, err := k.stakingKeeper.BondDenom(ctx) + if err != nil { + return sdk.Coin{}, err + } + + // Distribute funds to the recipient from pool module account + withdrawnAmount := sdk.NewCoin(denom, fundsAllocated) + err = k.DistributeFromCommunityPool(ctx, sdk.NewCoins(withdrawnAmount), recipient) + if err != nil { + return sdk.Coin{}, fmt.Errorf("error while distributing funds to the recipient %s: %v", recipient.String(), err) + } + + // reset fund distribution + err = k.RecipientFundDistribution.Set(ctx, recipient, math.ZeroInt()) + if err != nil { + return sdk.Coin{}, err + } + return withdrawnAmount, nil +} + +// SetToDistribute sets the amount to be distributed among recipients. +// This could be only set by the authority address. +func (k Keeper) SetToDistribute(ctx context.Context, amount sdk.Coins, addr string) error { + authAddr, err := k.authKeeper.AddressCodec().StringToBytes(addr) + if err != nil { + return err + } + hasPermission, err := k.hasPermission(ctx, authAddr) + if err != nil { + return err + } + if !hasPermission { + return sdkerrors.ErrUnauthorized + } + + denom, err := k.stakingKeeper.BondDenom(ctx) + if err != nil { + return err + } + + err = k.ToDistribute.Set(ctx, amount.AmountOf(denom)) + if err != nil { + return fmt.Errorf("error while setting ToDistribute: %v", err) + } + return nil +} + +func (k Keeper) hasPermission(ctx context.Context, addr []byte) (bool, error) { + authority := k.GetAuthority() + authAcc, err := k.authKeeper.AddressCodec().StringToBytes(authority) + if err != nil { + return false, err + } + + return bytes.Equal(authAcc, addr), nil +} + +func (k Keeper) iterateAndUpdateFundsDistribution(ctx context.Context, toDistributeAmount math.Int) error { + totalPercentageToBeDistributed := math.ZeroInt() + + // Create a map to store keys & values from RecipientFundPercentage during the first iteration + recipientFundMap := make(map[string]math.Int) + + // Calculate totalPercentageToBeDistributed and store values + err := k.RecipientFundPercentage.Walk(ctx, nil, func(key sdk.AccAddress, value math.Int) (stop bool, err error) { + totalPercentageToBeDistributed = totalPercentageToBeDistributed.Add(value) + recipientFundMap[key.String()] = value + return false, nil + }) + if err != nil { + return err + } + if totalPercentageToBeDistributed.GT(math.NewInt(100)) { + return fmt.Errorf("total funds percentage cannot exceed 100") + } + + denom, err := k.stakingKeeper.BondDenom(ctx) + if err != nil { + return err + } + toDistributeDec := sdk.NewDecCoins(sdk.NewDecCoin(denom, toDistributeAmount)) + + // Calculate the funds to be distributed based on the total percentage to be distributed + totalAmountToBeDistributed := toDistributeDec.MulDec(math.LegacyNewDecFromIntWithPrec(totalPercentageToBeDistributed, 2)) + totalDistrAmount := totalAmountToBeDistributed.AmountOf(denom) + + for keyStr, value := range recipientFundMap { + // Calculate the funds to be distributed based on the percentage + decValue := math.LegacyNewDecFromIntWithPrec(value, 2) + percentage := math.LegacyNewDecFromIntWithPrec(totalPercentageToBeDistributed, 2) + recipientAmount := totalDistrAmount.Mul(decValue).Quo(percentage) + recipientCoins := recipientAmount.TruncateInt() + + key, err := k.authKeeper.AddressCodec().StringToBytes(keyStr) + if err != nil { + return err + } + + // Set funds to be claimed + toClaim, err := k.RecipientFundDistribution.Get(ctx, key) + if err != nil { + return err + } + amount := toClaim.Add(recipientCoins) + err = k.RecipientFundDistribution.Set(ctx, key, amount) + if err != nil { + return err + } + } + + // Set the coins to be distributed from toDistribute to 0 + return k.ToDistribute.Set(ctx, math.ZeroInt()) +} + func (k Keeper) claimFunds(ctx context.Context, recipient sdk.AccAddress) (amount sdk.Coin, err error) { // get claimable funds from distribution info amount, err = k.getClaimableFunds(ctx, recipient) @@ -202,7 +373,6 @@ func (k Keeper) validateAndUpdateBudgetProposal(ctx context.Context, bp types.Ms bp.StartTime = ¤tTime } - // if bp.StartTime < uint64(currentTime) { if currentTime.After(*bp.StartTime) { return nil, fmt.Errorf("invalid budget proposal: start time cannot be less than the current block time") } @@ -226,3 +396,27 @@ func (k Keeper) validateAndUpdateBudgetProposal(ctx context.Context, bp types.Ms return &updatedBudget, nil } + +// validateContinuousFund validates the fields of the CreateContinuousFund message. +func (k Keeper) validateContinuousFund(ctx context.Context, msg types.MsgCreateContinuousFund) error { + // Validate percentage + if msg.Percentage.IsZero() || msg.Percentage.IsNil() { + return fmt.Errorf("percentage cannot be zero or empty") + } + if msg.Percentage.IsNegative() { + return fmt.Errorf("percentage cannot be negative") + } + if msg.Percentage.GTE(math.LegacyOneDec()) { + return fmt.Errorf("percentage cannot be greater than or equal to one") + } + + // Validate expiry + currentTime := sdk.UnwrapSDKContext(ctx).BlockTime() + if msg.Expiry != nil { + if msg.Expiry.Compare(currentTime) == -1 { + return fmt.Errorf("expiry time cannot be less than the current block time") + } + } + + return nil +} diff --git a/x/protocolpool/keeper/keeper_test.go b/x/protocolpool/keeper/keeper_test.go index b04873bee79f..a3a7dbddec4a 100644 --- a/x/protocolpool/keeper/keeper_test.go +++ b/x/protocolpool/keeper/keeper_test.go @@ -8,12 +8,14 @@ import ( "github.com/stretchr/testify/suite" "cosmossdk.io/core/header" + "cosmossdk.io/math" storetypes "cosmossdk.io/store/types" authtypes "cosmossdk.io/x/auth/types" poolkeeper "cosmossdk.io/x/protocolpool/keeper" pooltestutil "cosmossdk.io/x/protocolpool/testutil" - pooltypes "cosmossdk.io/x/protocolpool/types" + "cosmossdk.io/x/protocolpool/types" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec/address" "github.com/cosmos/cosmos-sdk/runtime" "github.com/cosmos/cosmos-sdk/testutil" @@ -21,19 +23,23 @@ import ( moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" ) -var poolAcc = authtypes.NewEmptyModuleAccount(pooltypes.ModuleName) +var poolAcc = authtypes.NewEmptyModuleAccount(types.ModuleName) type KeeperTestSuite struct { suite.Suite - ctx sdk.Context - poolKeeper poolkeeper.Keeper - bankKeeper *pooltestutil.MockBankKeeper - msgServer pooltypes.MsgServer + ctx sdk.Context + poolKeeper poolkeeper.Keeper + authKeeper *pooltestutil.MockAccountKeeper + bankKeeper *pooltestutil.MockBankKeeper + stakingKeeper *pooltestutil.MockStakingKeeper + + msgServer types.MsgServer + queryServer types.QueryServer } func (s *KeeperTestSuite) SetupTest() { - key := storetypes.NewKVStoreKey(pooltypes.StoreKey) + key := storetypes.NewKVStoreKey(types.StoreKey) storeService := runtime.NewKVStoreService(key) testCtx := testutil.DefaultContextWithDB(s.T(), key, storetypes.NewTransientStoreKey("transient_test")) ctx := testCtx.Ctx.WithHeaderInfo(header.Info{Time: time.Now()}) @@ -42,28 +48,45 @@ func (s *KeeperTestSuite) SetupTest() { // gomock initializations ctrl := gomock.NewController(s.T()) accountKeeper := pooltestutil.NewMockAccountKeeper(ctrl) - accountKeeper.EXPECT().GetModuleAddress(pooltypes.ModuleName).Return(poolAcc.GetAddress()) + accountKeeper.EXPECT().GetModuleAddress(types.ModuleName).Return(poolAcc.GetAddress()) accountKeeper.EXPECT().AddressCodec().Return(address.NewBech32Codec("cosmos")).AnyTimes() + s.authKeeper = accountKeeper bankKeeper := pooltestutil.NewMockBankKeeper(ctrl) s.bankKeeper = bankKeeper + stakingKeeper := pooltestutil.NewMockStakingKeeper(ctrl) + stakingKeeper.EXPECT().BondDenom(ctx).Return("stake", nil).AnyTimes() + s.stakingKeeper = stakingKeeper + poolKeeper := poolkeeper.NewKeeper( encCfg.Codec, storeService, accountKeeper, bankKeeper, - authtypes.NewModuleAddress(pooltypes.GovModuleName).String(), + stakingKeeper, + authtypes.NewModuleAddress(types.GovModuleName).String(), ) s.ctx = ctx s.poolKeeper = poolKeeper - pooltypes.RegisterInterfaces(encCfg.InterfaceRegistry) + types.RegisterInterfaces(encCfg.InterfaceRegistry) + queryHelper := baseapp.NewQueryServerTestHelper(ctx, encCfg.InterfaceRegistry) + types.RegisterQueryServer(queryHelper, poolkeeper.Querier{Keeper: poolKeeper}) s.msgServer = poolkeeper.NewMsgServerImpl(poolKeeper) + s.queryServer = poolkeeper.NewQuerier(poolKeeper) } func (s *KeeperTestSuite) mockSendCoinsFromModuleToAccount(accAddr sdk.AccAddress) { - s.bankKeeper.EXPECT().SendCoinsFromModuleToAccount(s.ctx, pooltypes.ModuleName, accAddr, gomock.Any()).AnyTimes() + s.bankKeeper.EXPECT().SendCoinsFromModuleToAccount(s.ctx, types.ModuleName, accAddr, gomock.Any()).AnyTimes() +} + +func (s *KeeperTestSuite) mockWithdrawContinuousFund() { + s.authKeeper.EXPECT().GetModuleAccount(s.ctx, types.ModuleName).Return(poolAcc).AnyTimes() + distrBal := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + s.bankKeeper.EXPECT().GetAllBalances(s.ctx, gomock.Any()).Return(distrBal).AnyTimes() + s.bankKeeper.EXPECT().SendCoinsFromModuleToAccount(s.ctx, gomock.Any(), gomock.Any(), gomock.Any()).AnyTimes() + s.stakingKeeper.EXPECT().BondDenom(s.ctx).AnyTimes() } func TestKeeperTestSuite(t *testing.T) { diff --git a/x/protocolpool/keeper/msg_server.go b/x/protocolpool/keeper/msg_server.go index 5cc913777881..475378a6f35f 100644 --- a/x/protocolpool/keeper/msg_server.go +++ b/x/protocolpool/keeper/msg_server.go @@ -2,8 +2,11 @@ package keeper import ( "context" + errorspkg "errors" + "fmt" "cosmossdk.io/errors" + "cosmossdk.io/math" "cosmossdk.io/x/protocolpool/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -103,11 +106,106 @@ func (k MsgServer) CommunityPoolSpend(ctx context.Context, msg *types.MsgCommuni } func (k MsgServer) CreateContinuousFund(ctx context.Context, msg *types.MsgCreateContinuousFund) (*types.MsgCreateContinuousFundResponse, error) { + if err := k.validateAuthority(msg.Authority); err != nil { + return nil, err + } + + recipient, err := k.Keeper.authKeeper.AddressCodec().StringToBytes(msg.Recipient) + if err != nil { + return nil, err + } + + // Validate the message fields + err = k.validateContinuousFund(ctx, *msg) + if err != nil { + return nil, err + } + + // Create continuous fund proposal + cf := types.ContinuousFund{ + Recipient: msg.Recipient, + Percentage: msg.Percentage, + Expiry: msg.Expiry, + } + + // Set continuous fund to the state + err = k.ContinuousFund.Set(ctx, recipient, cf) + if err != nil { + return nil, err + } + + // Set recipient fund percentage & distribution + percentage := cf.Percentage.MulInt64(100) + err = k.RecipientFundPercentage.Set(ctx, recipient, percentage.TruncateInt()) + if err != nil { + return nil, err + } + err = k.RecipientFundDistribution.Set(ctx, recipient, math.ZeroInt()) + if err != nil { + return nil, err + } + return &types.MsgCreateContinuousFundResponse{}, nil } +func (k MsgServer) WithdrawContinuousFund(ctx context.Context, msg *types.MsgWithdrawContinuousFund) (*types.MsgWithdrawContinuousFundResponse, error) { + recipient, err := k.Keeper.authKeeper.AddressCodec().StringToBytes(msg.RecipientAddress) + if err != nil { + return nil, sdkerrors.ErrInvalidAddress.Wrapf("invalid recipient address: %s", err) + } + + amount, err := k.withdrawContinuousFund(ctx, recipient) + if err != nil { + return nil, err + } + if amount.IsNil() { + k.Logger(ctx).Info(fmt.Sprintf("no distribution amount found for recipient %s", msg.RecipientAddress)) + } + + return &types.MsgWithdrawContinuousFundResponse{Amount: amount}, nil +} + func (k MsgServer) CancelContinuousFund(ctx context.Context, msg *types.MsgCancelContinuousFund) (*types.MsgCancelContinuousFundResponse, error) { - return &types.MsgCancelContinuousFundResponse{}, nil + sdkCtx := sdk.UnwrapSDKContext(ctx) + + if err := k.validateAuthority(msg.Authority); err != nil { + return nil, err + } + + recipient, err := k.Keeper.authKeeper.AddressCodec().StringToBytes(msg.RecipientAddress) + if err != nil { + return nil, err + } + + canceledHeight := sdkCtx.BlockHeight() + canceledTime := sdkCtx.BlockTime() + + found, err := k.ContinuousFund.Has(ctx, recipient) + if !found { + return nil, fmt.Errorf("no recipient found to cancel continuous fund: %s", msg.RecipientAddress) + } + if err != nil { + return nil, err + } + + // withdraw funds if any are allocated + withdrawnFunds, err := k.withdrawRecipientFunds(ctx, recipient) + if err != nil { + if !errorspkg.Is(err, types.ErrNoRecipientFund) { + return nil, fmt.Errorf("error while withdrawing already allocated funds for recipient %s: %v", msg.RecipientAddress, err) + } + } + + if err := k.ContinuousFund.Remove(ctx, recipient); err != nil { + return nil, fmt.Errorf("failed to remove continuous fund for recipient %s: %w", msg.RecipientAddress, err) + } + + return &types.MsgCancelContinuousFundResponse{ + CanceledTime: canceledTime, + CanceledHeight: uint64(canceledHeight), + RecipientAddress: msg.RecipientAddress, + WithdrawnAllocatedFund: withdrawnFunds, + }, nil } func (k *Keeper) validateAuthority(authority string) error { diff --git a/x/protocolpool/keeper/msg_server_test.go b/x/protocolpool/keeper/msg_server_test.go index 1f72e2d2c305..cebf350c9690 100644 --- a/x/protocolpool/keeper/msg_server_test.go +++ b/x/protocolpool/keeper/msg_server_test.go @@ -3,7 +3,9 @@ package keeper_test import ( "time" + "cosmossdk.io/collections" "cosmossdk.io/core/header" + "cosmossdk.io/math" "cosmossdk.io/x/protocolpool/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -23,7 +25,6 @@ func (suite *KeeperTestSuite) TestMsgSubmitBudgetProposal() { period := time.Duration(60) * time.Second zeroPeriod := time.Duration(0) * time.Second testCases := map[string]struct { - preRun func() input *types.MsgSubmitBudgetProposal expErr bool expErrMsg string @@ -128,9 +129,7 @@ func (suite *KeeperTestSuite) TestMsgSubmitBudgetProposal() { for name, tc := range testCases { suite.Run(name, func() { suite.SetupTest() - if tc.preRun != nil { - tc.preRun() - } + _, err := suite.msgServer.SubmitBudgetProposal(suite.ctx, tc.input) if tc.expErr { suite.Require().Error(err) @@ -337,3 +336,525 @@ func (suite *KeeperTestSuite) TestMsgClaimBudget() { }) } } + +func (suite *KeeperTestSuite) TestWithdrawContinuousFund() { + recipient := sdk.AccAddress([]byte("recipientAddr1__________________")) + recipient2 := sdk.AccAddress([]byte("recipientAddr2___________________")) + recipient3 := sdk.AccAddress([]byte("recipientAddr3___________________")) + testCases := map[string]struct { + preRun func() + recipientAddress []sdk.AccAddress + expErr bool + expErrMsg string + withdrawnAmount sdk.Coin + }{ + "empty recipient": { + recipientAddress: []sdk.AccAddress{sdk.AccAddress([]byte(""))}, + expErr: true, + expErrMsg: "invalid recipient address", + }, + "recipient with no continuous fund": { + recipientAddress: []sdk.AccAddress{recipient}, + expErr: true, + expErrMsg: "no continuous fund found for recipient", + }, + "funds percentage > 100": { + preRun: func() { + // Set fund 1 + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient, math.ZeroInt()) + suite.Require().NoError(err) + + // Set fund 2 + percentage, err = math.LegacyNewDecFromStr("0.9") + suite.Require().NoError(err) + cf = types.ContinuousFund{ + Recipient: recipient2.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient2, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage = percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient2, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient2, math.ZeroInt()) + suite.Require().NoError(err) + + // Set ToDistribute + toDistribute := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + suite.stakingKeeper.EXPECT().BondDenom(suite.ctx).Return("stake", nil).AnyTimes() + err = suite.poolKeeper.SetToDistribute(suite.ctx, toDistribute, suite.poolKeeper.GetAuthority()) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient}, + expErr: true, + expErrMsg: "error while iterating all the continuous funds: total funds percentage cannot exceed 100", + }, + "expired case": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + expiry := suite.ctx.BlockTime().Add(time.Duration(-1) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient}, + expErr: true, + expErrMsg: "cannot withdraw continuous funds: continuous fund expired for recipient", + }, + "valid case with ToDistribute amount zero": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient, math.ZeroInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.ToDistribute.Set(suite.ctx, math.ZeroInt()) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient}, + expErr: false, + withdrawnAmount: sdk.NewCoin(sdk.DefaultBondDenom, math.ZeroInt()), + }, + "valid case with empty expiry": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient, math.ZeroInt()) + suite.Require().NoError(err) + toDistribute := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + err = suite.poolKeeper.SetToDistribute(suite.ctx, toDistribute, suite.poolKeeper.GetAuthority()) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient}, + expErr: false, + withdrawnAmount: sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(20000)), + }, + "valid case": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient, math.ZeroInt()) + suite.Require().NoError(err) + toDistribute := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + err = suite.poolKeeper.SetToDistribute(suite.ctx, toDistribute, suite.poolKeeper.GetAuthority()) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient}, + expErr: false, + withdrawnAmount: sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(20000)), + }, + "valid case with multiple funds": { + preRun: func() { + // Set continuous fund 1 + percentage, err := math.LegacyNewDecFromStr("0.3") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipient.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient, math.ZeroInt()) + suite.Require().NoError(err) + + // Set continuous fund 2 + percentage2, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + cf = types.ContinuousFund{ + Recipient: recipient2.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient2, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage = percentage2.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient2, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient2, math.ZeroInt()) + suite.Require().NoError(err) + + // Set continuous fund 3 + percentage3, err := math.LegacyNewDecFromStr("0.3") + suite.Require().NoError(err) + cf = types.ContinuousFund{ + Recipient: recipient3.String(), + Percentage: percentage2, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient3, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage = percentage3.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient3, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient3, math.ZeroInt()) + suite.Require().NoError(err) + + toDistribute := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + err = suite.poolKeeper.SetToDistribute(suite.ctx, toDistribute, suite.poolKeeper.GetAuthority()) + suite.Require().NoError(err) + }, + recipientAddress: []sdk.AccAddress{recipient, recipient2, recipient3}, + expErr: false, + withdrawnAmount: sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(30000)), + }, + } + + for name, tc := range testCases { + suite.Run(name, func() { + suite.SetupTest() + if tc.preRun != nil { + tc.preRun() + } + msg := &types.MsgWithdrawContinuousFund{ + RecipientAddress: tc.recipientAddress[0].String(), + } + + suite.mockWithdrawContinuousFund() + + resp, err := suite.msgServer.WithdrawContinuousFund(suite.ctx, msg) + if tc.expErr { + suite.Require().Error(err) + suite.Require().Contains(err.Error(), tc.expErrMsg) + } else { + suite.Require().NoError(err) + suite.Require().Equal(tc.withdrawnAmount, resp.Amount) + + // this condition is valid only for request with multiple continuous funds + if len(tc.recipientAddress) > 1 { + toClaim, err := suite.poolKeeper.RecipientFundDistribution.Get(suite.ctx, tc.recipientAddress[1]) + suite.Require().NoError(err) + suite.Require().Equal(toClaim, math.NewInt(20000)) + toClaim, err = suite.poolKeeper.RecipientFundDistribution.Get(suite.ctx, tc.recipientAddress[2]) + suite.Require().NoError(err) + suite.Require().Equal(toClaim, math.NewInt(30000)) + } + } + }) + } +} + +func (suite *KeeperTestSuite) TestCreateContinuousFund() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + negativePercentage, err := math.LegacyNewDecFromStr("-0.2") + suite.Require().NoError(err) + invalidExpirty := suite.ctx.BlockTime().Add(-15 * time.Second) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + testCases := map[string]struct { + input *types.MsgCreateContinuousFund + expErr bool + expErrMsg string + }{ + "empty recipient address": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: "", + Percentage: percentage, + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "empty address string is not allowed", + }, + "empty authority": { + input: &types.MsgCreateContinuousFund{ + Authority: "", + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "empty address string is not allowed", + }, + "invalid authority": { + input: &types.MsgCreateContinuousFund{ + Authority: "invalid_authority", + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "invalid authority", + }, + "zero percentage": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: recipientAddr.String(), + Percentage: math.LegacyNewDec(0), + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "percentage cannot be zero or empty", + }, + "negative percentage": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: recipientAddr.String(), + Percentage: negativePercentage, + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "percentage cannot be negative", + }, + "invalid percentage": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: recipientAddr.String(), + Percentage: math.LegacyNewDec(1), + Expiry: &expiry, + }, + expErr: true, + expErrMsg: "percentage cannot be greater than or equal to one", + }, + "invalid expiry": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &invalidExpirty, + }, + expErr: true, + expErrMsg: "expiry time cannot be less than the current block time", + }, + "all good": { + input: &types.MsgCreateContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &expiry, + }, + expErr: false, + }, + } + + for name, tc := range testCases { + suite.Run(name, func() { + suite.SetupTest() + + _, err := suite.msgServer.CreateContinuousFund(suite.ctx, tc.input) + if tc.expErr { + suite.Require().Error(err) + suite.Require().Contains(err.Error(), tc.expErrMsg) + } else { + suite.Require().NoError(err) + } + }) + } +} + +func (suite *KeeperTestSuite) TestCancelContinuousFund() { + recipient2 := sdk.AccAddress([]byte("recipientAddr2___________________")) + + testCases := map[string]struct { + preRun func() + recipientAddr sdk.AccAddress + expErr bool + expErrMsg string + postRun func() + withdrawnFunds sdk.Coin + }{ + "empty recipient": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: "", + Percentage: percentage, + Expiry: &expiry, + } + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipientAddr, cf) + suite.Require().NoError(err) + }, + expErr: true, + expErrMsg: "empty address string is not allowed", + }, + "no recipient found": { + recipientAddr: recipientAddr, + expErr: true, + expErrMsg: "no recipient found to cancel continuous fund", + }, + "all good with unclaimed funds for recipient": { + preRun: func() { + // Set fund 1 + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipientAddr, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage := percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipientAddr, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipientAddr, math.ZeroInt()) + suite.Require().NoError(err) + + // Set fund 2 + percentage, err = math.LegacyNewDecFromStr("0.3") + suite.Require().NoError(err) + cf = types.ContinuousFund{ + Recipient: recipient2.String(), + Percentage: percentage, + Expiry: &expiry, + } + // Set continuous fund + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipient2, cf) + suite.Require().NoError(err) + // Set recipient fund percentage and recipient fund distribution + intPercentage = percentage.MulInt64(100) + err = suite.poolKeeper.RecipientFundPercentage.Set(suite.ctx, recipient2, intPercentage.TruncateInt()) + suite.Require().NoError(err) + err = suite.poolKeeper.RecipientFundDistribution.Set(suite.ctx, recipient2, math.ZeroInt()) + suite.Require().NoError(err) + + // Set ToDistribute + toDistribute := sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(100000))) + err = suite.poolKeeper.SetToDistribute(suite.ctx, toDistribute, suite.poolKeeper.GetAuthority()) + suite.Require().NoError(err) + + // withdraw funds for fund request 2 + suite.mockWithdrawContinuousFund() + msg := &types.MsgWithdrawContinuousFund{RecipientAddress: recipient2.String()} + _, err = suite.msgServer.WithdrawContinuousFund(suite.ctx, msg) + suite.Require().NoError(err) + }, + recipientAddr: recipientAddr, + expErr: false, + postRun: func() { + _, err := suite.poolKeeper.ContinuousFund.Get(suite.ctx, recipientAddr) + suite.Require().Error(err) + suite.Require().ErrorIs(err, collections.ErrNotFound) + }, + withdrawnFunds: sdk.NewCoin(sdk.DefaultBondDenom, math.NewInt(20000)), + }, + "all good": { + preRun: func() { + percentage, err := math.LegacyNewDecFromStr("0.2") + suite.Require().NoError(err) + oneMonthInSeconds := int64(30 * 24 * 60 * 60) // Approximate number of seconds in 1 month + expiry := suite.ctx.BlockTime().Add(time.Duration(oneMonthInSeconds) * time.Second) + cf := types.ContinuousFund{ + Recipient: recipientAddr.String(), + Percentage: percentage, + Expiry: &expiry, + } + err = suite.poolKeeper.ContinuousFund.Set(suite.ctx, recipientAddr, cf) + suite.Require().NoError(err) + }, + recipientAddr: recipientAddr, + expErr: false, + postRun: func() { + _, err := suite.poolKeeper.ContinuousFund.Get(suite.ctx, recipientAddr) + suite.Require().Error(err) + suite.Require().ErrorIs(err, collections.ErrNotFound) + }, + }, + } + + for name, tc := range testCases { + suite.Run(name, func() { + suite.SetupTest() + if tc.preRun != nil { + tc.preRun() + } + msg := &types.MsgCancelContinuousFund{ + Authority: suite.poolKeeper.GetAuthority(), + RecipientAddress: tc.recipientAddr.String(), + } + resp, err := suite.msgServer.CancelContinuousFund(suite.ctx, msg) + if tc.expErr { + suite.Require().Error(err) + suite.Require().Contains(err.Error(), tc.expErrMsg) + } else { + suite.Require().NoError(err) + suite.Require().Equal(resp.WithdrawnAllocatedFund, tc.withdrawnFunds) + } + if tc.postRun != nil { + tc.postRun() + } + }) + } +} diff --git a/x/protocolpool/module.go b/x/protocolpool/module.go index 0afb3b152a70..94dc10334f7b 100644 --- a/x/protocolpool/module.go +++ b/x/protocolpool/module.go @@ -2,6 +2,8 @@ package protocolpool import ( "context" + "encoding/json" + "fmt" gwruntime "github.com/grpc-ecosystem/grpc-gateway/runtime" @@ -30,6 +32,7 @@ var ( _ module.AppModule = AppModule{} _ module.AppModuleSimulation = AppModule{} + _ module.HasGenesis = AppModule{} ) // AppModuleBasic defines the basic application module used by the pool module. @@ -55,6 +58,22 @@ func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) types.RegisterInterfaces(registry) } +// DefaultGenesis returns default genesis state as raw bytes for the protocolpool +// module. +func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { + return cdc.MustMarshalJSON(types.DefaultGenesisState()) +} + +// ValidateGenesis performs genesis state validation for the protocolpool module. +func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncodingConfig, bz json.RawMessage) error { + var data types.GenesisState + if err := cdc.UnmarshalJSON(bz, &data); err != nil { + return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) + } + + return types.ValidateGenesis(&data) +} + // AppModule implements an application module for the pool module type AppModule struct { AppModuleBasic @@ -90,6 +109,25 @@ func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, } } +// InitGenesis performs genesis initialization for the protocolpool module. +func (am AppModule) InitGenesis(ctx context.Context, cdc codec.JSONCodec, data json.RawMessage) { + var genesisState types.GenesisState + cdc.MustUnmarshalJSON(data, &genesisState) + if err := am.keeper.InitGenesis(ctx, &genesisState); err != nil { + panic(err) + } +} + +// ExportGenesis returns the exported genesis state as raw bytes for the protocolpool +// module. +func (am AppModule) ExportGenesis(ctx context.Context, cdc codec.JSONCodec) json.RawMessage { + gs, err := am.keeper.ExportGenesis(ctx) + if err != nil { + panic(err) + } + return cdc.MustMarshalJSON(gs) +} + // ConsensusVersion implements AppModule/ConsensusVersion. func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } @@ -113,6 +151,7 @@ type ModuleInputs struct { AccountKeeper types.AccountKeeper BankKeeper types.BankKeeper + StakingKeeper types.StakingKeeper } type ModuleOutputs struct { @@ -129,7 +168,7 @@ func ProvideModule(in ModuleInputs) ModuleOutputs { authority = authtypes.NewModuleAddressOrBech32Address(in.Config.Authority) } - k := keeper.NewKeeper(in.Codec, in.StoreService, in.AccountKeeper, in.BankKeeper, authority.String()) + k := keeper.NewKeeper(in.Codec, in.StoreService, in.AccountKeeper, in.BankKeeper, in.StakingKeeper, authority.String()) m := NewAppModule(in.Codec, k, in.AccountKeeper, in.BankKeeper) return ModuleOutputs{ diff --git a/x/protocolpool/testutil/expected_keepers_mocks.go b/x/protocolpool/testutil/expected_keepers_mocks.go index c157e745d475..6740d784af0b 100644 --- a/x/protocolpool/testutil/expected_keepers_mocks.go +++ b/x/protocolpool/testutil/expected_keepers_mocks.go @@ -129,6 +129,20 @@ func (mr *MockBankKeeperMockRecorder) GetAllBalances(ctx, addr interface{}) *gom return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAllBalances", reflect.TypeOf((*MockBankKeeper)(nil).GetAllBalances), ctx, addr) } +// MintCoins mocks base method. +func (m *MockBankKeeper) MintCoins(ctx context.Context, moduleName string, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "MintCoins", ctx, moduleName, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// MintCoins indicates an expected call of MintCoins. +func (mr *MockBankKeeperMockRecorder) MintCoins(ctx, moduleName, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MintCoins", reflect.TypeOf((*MockBankKeeper)(nil).MintCoins), ctx, moduleName, amt) +} + // SendCoinsFromAccountToModule mocks base method. func (m *MockBankKeeper) SendCoinsFromAccountToModule(ctx context.Context, senderAddr types.AccAddress, recipientModule string, amt types.Coins) error { m.ctrl.T.Helper() @@ -157,6 +171,20 @@ func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToAccount(ctx, senderMo return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsFromModuleToAccount", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsFromModuleToAccount), ctx, senderModule, recipientAddr, amt) } +// SendCoinsFromModuleToModule mocks base method. +func (m *MockBankKeeper) SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendCoinsFromModuleToModule", ctx, senderModule, recipientModule, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendCoinsFromModuleToModule indicates an expected call of SendCoinsFromModuleToModule. +func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToModule(ctx, senderModule, recipientModule, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsFromModuleToModule", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsFromModuleToModule), ctx, senderModule, recipientModule, amt) +} + // SpendableCoins mocks base method. func (m *MockBankKeeper) SpendableCoins(ctx context.Context, addr types.AccAddress) types.Coins { m.ctrl.T.Helper() @@ -170,3 +198,41 @@ func (mr *MockBankKeeperMockRecorder) SpendableCoins(ctx, addr interface{}) *gom mr.mock.ctrl.T.Helper() return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SpendableCoins", reflect.TypeOf((*MockBankKeeper)(nil).SpendableCoins), ctx, addr) } + +// MockStakingKeeper is a mock of StakingKeeper interface. +type MockStakingKeeper struct { + ctrl *gomock.Controller + recorder *MockStakingKeeperMockRecorder +} + +// MockStakingKeeperMockRecorder is the mock recorder for MockStakingKeeper. +type MockStakingKeeperMockRecorder struct { + mock *MockStakingKeeper +} + +// NewMockStakingKeeper creates a new mock instance. +func NewMockStakingKeeper(ctrl *gomock.Controller) *MockStakingKeeper { + mock := &MockStakingKeeper{ctrl: ctrl} + mock.recorder = &MockStakingKeeperMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockStakingKeeper) EXPECT() *MockStakingKeeperMockRecorder { + return m.recorder +} + +// BondDenom mocks base method. +func (m *MockStakingKeeper) BondDenom(ctx context.Context) (string, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "BondDenom", ctx) + ret0, _ := ret[0].(string) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// BondDenom indicates an expected call of BondDenom. +func (mr *MockStakingKeeperMockRecorder) BondDenom(ctx interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BondDenom", reflect.TypeOf((*MockStakingKeeper)(nil).BondDenom), ctx) +} diff --git a/x/protocolpool/types/codec.go b/x/protocolpool/types/codec.go index 461d1bbd10af..30bef81c2f8d 100644 --- a/x/protocolpool/types/codec.go +++ b/x/protocolpool/types/codec.go @@ -13,6 +13,9 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { &MsgCommunityPoolSpend{}, &MsgSubmitBudgetProposal{}, &MsgClaimBudget{}, + &MsgCreateContinuousFund{}, + &MsgCancelContinuousFund{}, + &MsgWithdrawContinuousFund{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) diff --git a/x/protocolpool/types/errors.go b/x/protocolpool/types/errors.go index 8b31a933cbc9..5c24b95d1784 100644 --- a/x/protocolpool/types/errors.go +++ b/x/protocolpool/types/errors.go @@ -2,4 +2,7 @@ package types import "cosmossdk.io/errors" -var ErrInvalidSigner = errors.Register(ModuleName, 2, "expected authority account as only signer for community pool spend message") +var ( + ErrInvalidSigner = errors.Register(ModuleName, 2, "expected authority account as only signer for community pool spend message") + ErrNoRecipientFund = errors.Register(ModuleName, 3, "no recipient fund found for recipient") +) diff --git a/x/protocolpool/types/expected_keepers.go b/x/protocolpool/types/expected_keepers.go index a9b6d8d04182..8f86343b1181 100644 --- a/x/protocolpool/types/expected_keepers.go +++ b/x/protocolpool/types/expected_keepers.go @@ -17,8 +17,14 @@ type AccountKeeper interface { // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { + MintCoins(ctx context.Context, moduleName string, amt sdk.Coins) error GetAllBalances(ctx context.Context, addr sdk.AccAddress) sdk.Coins SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error +} + +type StakingKeeper interface { + BondDenom(ctx context.Context) (string, error) } diff --git a/x/protocolpool/types/genesis.go b/x/protocolpool/types/genesis.go new file mode 100644 index 000000000000..085e538c6a92 --- /dev/null +++ b/x/protocolpool/types/genesis.go @@ -0,0 +1,82 @@ +package types + +import ( + "fmt" + + "cosmossdk.io/errors" + "cosmossdk.io/math" + + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +) + +func NewGenesisState(cf []*ContinuousFund, budget []*Budget) *GenesisState { + return &GenesisState{ + ContinuousFund: cf, + Budget: budget, + } +} + +func DefaultGenesisState() *GenesisState { + return &GenesisState{ + ContinuousFund: []*ContinuousFund{}, + Budget: []*Budget{}, + } +} + +// ValidateGenesis validates the genesis state of protocolpool genesis input +func ValidateGenesis(gs *GenesisState) error { + for _, cf := range gs.ContinuousFund { + if err := validateContinuousFund(*cf); err != nil { + return err + } + } + for _, bp := range gs.Budget { + if err := validateBudget(*bp); err != nil { + return err + } + } + return nil +} + +func validateBudget(bp Budget) error { + if bp.RecipientAddress == "" { + return fmt.Errorf("recipient cannot be empty") + } + + // Validate TotalBudget + amount := sdk.NewCoins(*bp.TotalBudget) + if amount.IsZero() { + return fmt.Errorf("total budget cannot be zero") + } + if err := amount.Validate(); err != nil { + return errors.Wrap(sdkerrors.ErrInvalidCoins, amount.String()) + } + + if bp.Tranches == 0 { + return fmt.Errorf("invalid budget proposal: tranches must be greater than zero") + } + + if bp.Period == nil || *bp.Period == 0 { + return fmt.Errorf("invalid budget proposal: period length should be greater than zero") + } + return nil +} + +func validateContinuousFund(cf ContinuousFund) error { + if cf.Recipient == "" { + return fmt.Errorf("recipient cannot be empty") + } + + // Validate percentage + if cf.Percentage.IsZero() || cf.Percentage.IsNil() { + return fmt.Errorf("percentage cannot be zero or empty") + } + if cf.Percentage.IsNegative() { + return fmt.Errorf("percentage cannot be negative") + } + if cf.Percentage.GT(math.LegacyOneDec()) { + return fmt.Errorf("percentage cannot be greater than one") + } + return nil +} diff --git a/x/protocolpool/types/genesis.pb.go b/x/protocolpool/types/genesis.pb.go new file mode 100644 index 000000000000..9f9f65bff39c --- /dev/null +++ b/x/protocolpool/types/genesis.pb.go @@ -0,0 +1,395 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cosmos/protocolpool/v1/genesis.proto + +package types + +import ( + fmt "fmt" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +// GenesisState defines the protocolpool module's genesis state. +type GenesisState struct { + // ContinuousFund defines the continuous funds at genesis. + ContinuousFund []*ContinuousFund `protobuf:"bytes,1,rep,name=continuous_fund,json=continuousFund,proto3" json:"continuous_fund,omitempty"` + // Budget defines the budget proposals at genesis. + Budget []*Budget `protobuf:"bytes,2,rep,name=budget,proto3" json:"budget,omitempty"` +} + +func (m *GenesisState) Reset() { *m = GenesisState{} } +func (m *GenesisState) String() string { return proto.CompactTextString(m) } +func (*GenesisState) ProtoMessage() {} +func (*GenesisState) Descriptor() ([]byte, []int) { + return fileDescriptor_72560a99455b4146, []int{0} +} +func (m *GenesisState) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GenesisState) XXX_Merge(src proto.Message) { + xxx_messageInfo_GenesisState.Merge(m, src) +} +func (m *GenesisState) XXX_Size() int { + return m.Size() +} +func (m *GenesisState) XXX_DiscardUnknown() { + xxx_messageInfo_GenesisState.DiscardUnknown(m) +} + +var xxx_messageInfo_GenesisState proto.InternalMessageInfo + +func (m *GenesisState) GetContinuousFund() []*ContinuousFund { + if m != nil { + return m.ContinuousFund + } + return nil +} + +func (m *GenesisState) GetBudget() []*Budget { + if m != nil { + return m.Budget + } + return nil +} + +func init() { + proto.RegisterType((*GenesisState)(nil), "cosmos.protocolpool.v1.GenesisState") +} + +func init() { + proto.RegisterFile("cosmos/protocolpool/v1/genesis.proto", fileDescriptor_72560a99455b4146) +} + +var fileDescriptor_72560a99455b4146 = []byte{ + // 208 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x49, 0xce, 0x2f, 0xce, + 0xcd, 0x2f, 0xd6, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0xce, 0xcf, 0x29, 0xc8, 0xcf, 0xcf, 0xd1, + 0x2f, 0x33, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x03, 0x8b, 0x0b, 0x89, 0x41, + 0x54, 0xe9, 0x21, 0xab, 0xd2, 0x2b, 0x33, 0x94, 0x52, 0xc2, 0xa1, 0xbb, 0xa4, 0xb2, 0x20, 0x15, + 0xaa, 0x5a, 0x69, 0x3a, 0x23, 0x17, 0x8f, 0x3b, 0xc4, 0xb4, 0xe0, 0x92, 0xc4, 0x92, 0x54, 0x21, + 0x7f, 0x2e, 0xfe, 0xe4, 0xfc, 0xbc, 0x92, 0xcc, 0xbc, 0xd2, 0xfc, 0xd2, 0xe2, 0xf8, 0xb4, 0xd2, + 0xbc, 0x14, 0x09, 0x46, 0x05, 0x66, 0x0d, 0x6e, 0x23, 0x35, 0x3d, 0xec, 0xd6, 0xe8, 0x39, 0xc3, + 0x95, 0xbb, 0x95, 0xe6, 0xa5, 0x04, 0xf1, 0x25, 0xa3, 0xf0, 0x85, 0xcc, 0xb8, 0xd8, 0x92, 0x4a, + 0x53, 0xd2, 0x53, 0x4b, 0x24, 0x98, 0xc0, 0xe6, 0xc8, 0xe1, 0x32, 0xc7, 0x09, 0xac, 0x2a, 0x08, + 0xaa, 0xda, 0xc9, 0xfa, 0xc4, 0x23, 0x39, 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, + 0x9c, 0xf0, 0x58, 0x8e, 0xe1, 0xc2, 0x63, 0x39, 0x86, 0x1b, 0x8f, 0xe5, 0x18, 0xa2, 0x14, 0x21, + 0x06, 0x14, 0xa7, 0x64, 0xeb, 0x65, 0xe6, 0xeb, 0x57, 0xa0, 0xfa, 0x0f, 0xec, 0xb9, 0x24, 0x36, + 0xb0, 0x98, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0x9a, 0x97, 0x3f, 0xc6, 0x41, 0x01, 0x00, 0x00, +} + +func (m *GenesisState) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Budget) > 0 { + for iNdEx := len(m.Budget) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Budget[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenesis(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + } + if len(m.ContinuousFund) > 0 { + for iNdEx := len(m.ContinuousFund) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.ContinuousFund[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenesis(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + } + return len(dAtA) - i, nil +} + +func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { + offset -= sovGenesis(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *GenesisState) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.ContinuousFund) > 0 { + for _, e := range m.ContinuousFund { + l = e.Size() + n += 1 + l + sovGenesis(uint64(l)) + } + } + if len(m.Budget) > 0 { + for _, e := range m.Budget { + l = e.Size() + n += 1 + l + sovGenesis(uint64(l)) + } + } + return n +} + +func sovGenesis(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozGenesis(x uint64) (n int) { + return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *GenesisState) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenesis + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ContinuousFund", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenesis + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenesis + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenesis + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ContinuousFund = append(m.ContinuousFund, &ContinuousFund{}) + if err := m.ContinuousFund[len(m.ContinuousFund)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Budget", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenesis + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenesis + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenesis + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Budget = append(m.Budget, &Budget{}) + if err := m.Budget[len(m.Budget)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenesis(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenesis + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenesis(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenesis + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenesis + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenesis + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthGenesis + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupGenesis + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthGenesis + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") +) diff --git a/x/protocolpool/types/keys.go b/x/protocolpool/types/keys.go index 67f58b8ffec8..432fef41d50e 100644 --- a/x/protocolpool/types/keys.go +++ b/x/protocolpool/types/keys.go @@ -18,4 +18,10 @@ const ( GovModuleName = "gov" ) -var BudgetKey = collections.NewPrefix(2) +var ( + BudgetKey = collections.NewPrefix(2) + ContinuousFundKey = collections.NewPrefix(3) + RecipientFundPercentageKey = collections.NewPrefix(4) + RecipientFundDistributionKey = collections.NewPrefix(5) + ToDistributeKey = collections.NewPrefix(6) +) diff --git a/x/protocolpool/types/tx.pb.go b/x/protocolpool/types/tx.pb.go index 338dd248c2e1..02590280361e 100644 --- a/x/protocolpool/types/tx.pb.go +++ b/x/protocolpool/types/tx.pb.go @@ -442,23 +442,14 @@ func (m *MsgClaimBudgetResponse) GetAmount() types.Coin { // MsgCreateContinuousFund defines a message for adding continuous funds. type MsgCreateContinuousFund struct { - // Title is the title of the funds. - Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` - // Description of the funds. - Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` // Authority is the address that controls the module (defaults to x/gov unless overwritten). - Authority string `protobuf:"bytes,3,opt,name=authority,proto3" json:"authority,omitempty"` + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` // Recipient address of the account receiving funds. - Recipient string `protobuf:"bytes,4,opt,name=recipient,proto3" json:"recipient,omitempty"` - // Metadata is any arbitrary metadata attached. - Metadata string `protobuf:"bytes,5,opt,name=metadata,proto3" json:"metadata,omitempty"` - // Percentage is the percentage of funds to be allocated from Community pool share on block by block, - // till the `cap` is reached or expired. - Percentage cosmossdk_io_math.LegacyDec `protobuf:"bytes,6,opt,name=percentage,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"percentage"` - // Cap is the capital amount, which when its met funds are no longer distributed. - Cap github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,7,rep,name=cap,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"cap"` + Recipient string `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` + // Percentage is the percentage of funds to be allocated from Community pool. + Percentage cosmossdk_io_math.LegacyDec `protobuf:"bytes,3,opt,name=percentage,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"percentage"` // Optional, if expiry is set, removes the state object when expired. - Expiry *time.Time `protobuf:"bytes,8,opt,name=expiry,proto3,stdtime" json:"expiry,omitempty"` + Expiry *time.Time `protobuf:"bytes,4,opt,name=expiry,proto3,stdtime" json:"expiry,omitempty"` } func (m *MsgCreateContinuousFund) Reset() { *m = MsgCreateContinuousFund{} } @@ -494,20 +485,6 @@ func (m *MsgCreateContinuousFund) XXX_DiscardUnknown() { var xxx_messageInfo_MsgCreateContinuousFund proto.InternalMessageInfo -func (m *MsgCreateContinuousFund) GetTitle() string { - if m != nil { - return m.Title - } - return "" -} - -func (m *MsgCreateContinuousFund) GetDescription() string { - if m != nil { - return m.Description - } - return "" -} - func (m *MsgCreateContinuousFund) GetAuthority() string { if m != nil { return m.Authority @@ -522,20 +499,6 @@ func (m *MsgCreateContinuousFund) GetRecipient() string { return "" } -func (m *MsgCreateContinuousFund) GetMetadata() string { - if m != nil { - return m.Metadata - } - return "" -} - -func (m *MsgCreateContinuousFund) GetCap() github_com_cosmos_cosmos_sdk_types.Coins { - if m != nil { - return m.Cap - } - return nil -} - func (m *MsgCreateContinuousFund) GetExpiry() *time.Time { if m != nil { return m.Expiry @@ -645,6 +608,10 @@ type MsgCancelContinuousFundResponse struct { CanceledHeight uint64 `protobuf:"varint,2,opt,name=canceled_height,json=canceledHeight,proto3" json:"canceled_height,omitempty"` // RecipientAddress is the account address of recipient whose funds are cancelled. RecipientAddress string `protobuf:"bytes,3,opt,name=recipient_address,json=recipientAddress,proto3" json:"recipient_address,omitempty"` + // withdrawnAllocatedFund represents the fund allocated to this recipient (if any) that have not been withdrawn yet, + // before a cancellation request has been initiated. + // It involves first withdrawing the funds and then canceling the request. + WithdrawnAllocatedFund types.Coin `protobuf:"bytes,4,opt,name=withdrawn_allocated_fund,json=withdrawnAllocatedFund,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"withdrawn_allocated_fund"` } func (m *MsgCancelContinuousFundResponse) Reset() { *m = MsgCancelContinuousFundResponse{} } @@ -701,6 +668,104 @@ func (m *MsgCancelContinuousFundResponse) GetRecipientAddress() string { return "" } +func (m *MsgCancelContinuousFundResponse) GetWithdrawnAllocatedFund() types.Coin { + if m != nil { + return m.WithdrawnAllocatedFund + } + return types.Coin{} +} + +// MsgWithdrawContinuousFund defines a message for withdrawing the continuous fund allocated to it. +type MsgWithdrawContinuousFund struct { + RecipientAddress string `protobuf:"bytes,1,opt,name=recipient_address,json=recipientAddress,proto3" json:"recipient_address,omitempty"` +} + +func (m *MsgWithdrawContinuousFund) Reset() { *m = MsgWithdrawContinuousFund{} } +func (m *MsgWithdrawContinuousFund) String() string { return proto.CompactTextString(m) } +func (*MsgWithdrawContinuousFund) ProtoMessage() {} +func (*MsgWithdrawContinuousFund) Descriptor() ([]byte, []int) { + return fileDescriptor_09efe14517e7f6dc, []int{12} +} +func (m *MsgWithdrawContinuousFund) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgWithdrawContinuousFund) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgWithdrawContinuousFund.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgWithdrawContinuousFund) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgWithdrawContinuousFund.Merge(m, src) +} +func (m *MsgWithdrawContinuousFund) XXX_Size() int { + return m.Size() +} +func (m *MsgWithdrawContinuousFund) XXX_DiscardUnknown() { + xxx_messageInfo_MsgWithdrawContinuousFund.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgWithdrawContinuousFund proto.InternalMessageInfo + +func (m *MsgWithdrawContinuousFund) GetRecipientAddress() string { + if m != nil { + return m.RecipientAddress + } + return "" +} + +// MsgWithdrawContinuousFundResponse defines the response to executing a +// MsgWithdrawContinuousFund message. +type MsgWithdrawContinuousFundResponse struct { + Amount types.Coin `protobuf:"bytes,1,opt,name=amount,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"amount"` +} + +func (m *MsgWithdrawContinuousFundResponse) Reset() { *m = MsgWithdrawContinuousFundResponse{} } +func (m *MsgWithdrawContinuousFundResponse) String() string { return proto.CompactTextString(m) } +func (*MsgWithdrawContinuousFundResponse) ProtoMessage() {} +func (*MsgWithdrawContinuousFundResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_09efe14517e7f6dc, []int{13} +} +func (m *MsgWithdrawContinuousFundResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgWithdrawContinuousFundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgWithdrawContinuousFundResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgWithdrawContinuousFundResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgWithdrawContinuousFundResponse.Merge(m, src) +} +func (m *MsgWithdrawContinuousFundResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgWithdrawContinuousFundResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgWithdrawContinuousFundResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgWithdrawContinuousFundResponse proto.InternalMessageInfo + +func (m *MsgWithdrawContinuousFundResponse) GetAmount() types.Coin { + if m != nil { + return m.Amount + } + return types.Coin{} +} + func init() { proto.RegisterType((*MsgFundCommunityPool)(nil), "cosmos.protocolpool.v1.MsgFundCommunityPool") proto.RegisterType((*MsgFundCommunityPoolResponse)(nil), "cosmos.protocolpool.v1.MsgFundCommunityPoolResponse") @@ -714,74 +779,77 @@ func init() { proto.RegisterType((*MsgCreateContinuousFundResponse)(nil), "cosmos.protocolpool.v1.MsgCreateContinuousFundResponse") proto.RegisterType((*MsgCancelContinuousFund)(nil), "cosmos.protocolpool.v1.MsgCancelContinuousFund") proto.RegisterType((*MsgCancelContinuousFundResponse)(nil), "cosmos.protocolpool.v1.MsgCancelContinuousFundResponse") + proto.RegisterType((*MsgWithdrawContinuousFund)(nil), "cosmos.protocolpool.v1.MsgWithdrawContinuousFund") + proto.RegisterType((*MsgWithdrawContinuousFundResponse)(nil), "cosmos.protocolpool.v1.MsgWithdrawContinuousFundResponse") } func init() { proto.RegisterFile("cosmos/protocolpool/v1/tx.proto", fileDescriptor_09efe14517e7f6dc) } var fileDescriptor_09efe14517e7f6dc = []byte{ - // 981 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0x41, 0x6f, 0xdc, 0x44, - 0x14, 0xde, 0xe9, 0x6e, 0x96, 0xec, 0xa4, 0x04, 0x6a, 0x2d, 0xa9, 0x6b, 0x8a, 0xbd, 0xdd, 0x03, - 0x44, 0x15, 0xb1, 0xd9, 0x02, 0x2d, 0x0a, 0x48, 0x88, 0x4d, 0x40, 0x20, 0x11, 0xa9, 0x38, 0x9c, - 0x90, 0x50, 0x34, 0x6b, 0x0f, 0xde, 0x51, 0x6d, 0x8f, 0xe5, 0x19, 0x87, 0x2c, 0x12, 0x52, 0xc5, - 0x89, 0x63, 0x8f, 0x1c, 0x7b, 0x44, 0x9c, 0x7a, 0xe8, 0x8f, 0xa8, 0xc4, 0xa5, 0xea, 0x09, 0x10, - 0x6a, 0x51, 0x72, 0x28, 0x57, 0xee, 0x1c, 0x90, 0x67, 0x66, 0xbd, 0xbb, 0x59, 0xd7, 0xc9, 0x22, - 0x22, 0x4e, 0x89, 0xdf, 0xbc, 0xf7, 0xe6, 0xfb, 0xde, 0x7b, 0xdf, 0xb3, 0x17, 0x5a, 0x1e, 0x65, - 0x11, 0x65, 0x4e, 0x92, 0x52, 0x4e, 0x3d, 0x1a, 0x26, 0x94, 0x86, 0xce, 0x7e, 0xcf, 0xe1, 0x07, - 0xb6, 0x30, 0x69, 0x6b, 0xd2, 0xc1, 0x9e, 0x76, 0xb0, 0xf7, 0x7b, 0x46, 0x3b, 0xa0, 0x01, 0x15, - 0x46, 0x27, 0xff, 0x4f, 0x9e, 0x1b, 0xa6, 0x4a, 0x37, 0x40, 0x0c, 0x3b, 0xfb, 0xbd, 0x01, 0xe6, - 0xa8, 0xe7, 0x78, 0x94, 0xc4, 0xea, 0xfc, 0x92, 0x3c, 0xdf, 0x93, 0x81, 0xd3, 0xa9, 0x8d, 0x8b, - 0x2a, 0x34, 0x62, 0x41, 0x0e, 0x20, 0x62, 0x81, 0x3a, 0xb0, 0x02, 0x4a, 0x83, 0x10, 0x4b, 0x88, - 0x83, 0xec, 0x2b, 0x87, 0x93, 0x08, 0x33, 0x8e, 0xa2, 0x64, 0x7c, 0xe9, 0x71, 0x07, 0x3f, 0x4b, - 0x11, 0x27, 0x54, 0x5d, 0xda, 0xfd, 0x19, 0xc0, 0xf6, 0x0e, 0x0b, 0x3e, 0xca, 0x62, 0x7f, 0x8b, - 0x46, 0x51, 0x16, 0x13, 0x3e, 0xba, 0x49, 0x69, 0xa8, 0x79, 0xb0, 0x89, 0x22, 0x9a, 0xc5, 0x5c, - 0x07, 0x9d, 0xfa, 0xfa, 0xca, 0xb5, 0x4b, 0xb6, 0x42, 0x94, 0xc3, 0xb7, 0x15, 0x7c, 0x7b, 0x8b, - 0x92, 0xb8, 0xff, 0xc6, 0x83, 0xc7, 0x56, 0xed, 0xa7, 0x27, 0xd6, 0x7a, 0x40, 0xf8, 0x30, 0x1b, - 0xd8, 0x1e, 0x8d, 0x14, 0x7c, 0xf5, 0x67, 0x83, 0xf9, 0xb7, 0x1c, 0x3e, 0x4a, 0x30, 0x13, 0x01, - 0xcc, 0x55, 0xa9, 0xb5, 0xeb, 0xb0, 0xe5, 0xe3, 0x84, 0x32, 0xc2, 0x69, 0xaa, 0x9f, 0xeb, 0x80, - 0xf5, 0x56, 0x5f, 0x7f, 0x74, 0x7f, 0xa3, 0xad, 0xae, 0xfa, 0xc0, 0xf7, 0x53, 0xcc, 0xd8, 0x2e, - 0x4f, 0x49, 0x1c, 0xb8, 0x13, 0xd7, 0xcd, 0xb5, 0xef, 0xef, 0x5a, 0xb5, 0x3f, 0xef, 0x5a, 0xb5, - 0xef, 0x9e, 0xde, 0xbb, 0x3a, 0xb1, 0x77, 0x4d, 0x78, 0xb9, 0x8c, 0x8c, 0x8b, 0x59, 0x42, 0x63, - 0x86, 0xbb, 0x87, 0x00, 0xbe, 0xb4, 0xc3, 0x82, 0x99, 0xc3, 0xdd, 0x04, 0xc7, 0x7e, 0x8e, 0x04, - 0x65, 0x7c, 0x48, 0x53, 0xc2, 0x47, 0x3a, 0x38, 0x09, 0x49, 0xe1, 0xaa, 0x5d, 0x86, 0xad, 0x14, - 0x7b, 0x24, 0x21, 0x38, 0xe6, 0x92, 0x81, 0x3b, 0x31, 0x4c, 0x15, 0xb1, 0x7e, 0x66, 0x45, 0xdc, - 0x5c, 0x15, 0x45, 0x28, 0x20, 0x75, 0x2d, 0xf8, 0x4a, 0x29, 0xc7, 0xa2, 0x0a, 0x7f, 0x9f, 0x83, - 0x17, 0x77, 0x58, 0xb0, 0x9b, 0x0d, 0x22, 0xc2, 0xfb, 0x99, 0x1f, 0x60, 0x7e, 0x33, 0xa5, 0x09, - 0x65, 0x28, 0xfc, 0xd7, 0x75, 0xf8, 0x10, 0x5e, 0x28, 0x68, 0xef, 0x21, 0xe9, 0x75, 0x62, 0x47, - 0x5f, 0x2c, 0x42, 0x94, 0x5d, 0x7b, 0x0f, 0x9e, 0xe7, 0x94, 0xa3, 0x70, 0x6f, 0x20, 0x60, 0xe9, - 0xf5, 0x0e, 0xa8, 0x2c, 0x9b, 0xbb, 0x22, 0xdc, 0x25, 0x09, 0xed, 0x7d, 0x08, 0x19, 0x47, 0x29, - 0xdf, 0xcb, 0x55, 0xa0, 0x37, 0x44, 0xac, 0x61, 0x4b, 0x05, 0xd8, 0x63, 0x05, 0xd8, 0x9f, 0x8f, - 0x25, 0xd2, 0x6f, 0xdc, 0x79, 0x62, 0x01, 0xb7, 0x25, 0x62, 0x72, 0xab, 0x66, 0xc0, 0x65, 0x9e, - 0xa2, 0xd8, 0x1b, 0x62, 0xa6, 0x2f, 0x75, 0xc0, 0x7a, 0xc3, 0x2d, 0x9e, 0xb5, 0x1b, 0xb0, 0x99, - 0xe0, 0x94, 0x50, 0x5f, 0x6f, 0x2a, 0x50, 0xc7, 0x13, 0x6f, 0x2b, 0x69, 0xf5, 0x1b, 0x3f, 0xe4, - 0x79, 0x95, 0xfb, 0x5c, 0x7f, 0xae, 0x40, 0xeb, 0x19, 0xd5, 0x2f, 0x3a, 0x44, 0xe1, 0x6a, 0xde, - 0xc2, 0x10, 0x91, 0x48, 0x51, 0x2b, 0xad, 0x2f, 0x58, 0xb4, 0xbe, 0x9b, 0x6b, 0x39, 0x96, 0xf9, - 0x4c, 0xdd, 0x6f, 0xe1, 0xda, 0xec, 0x85, 0x63, 0x28, 0x33, 0x7b, 0x00, 0x9c, 0xd1, 0x08, 0x77, - 0x7f, 0xad, 0x8b, 0x89, 0xdc, 0x4a, 0x31, 0xe2, 0x78, 0x8b, 0xc6, 0x9c, 0xc4, 0x19, 0xcd, 0x58, - 0x2e, 0x64, 0xad, 0x0d, 0x97, 0x38, 0xe1, 0x21, 0x96, 0x6c, 0x5d, 0xf9, 0xa0, 0x75, 0xe0, 0x8a, - 0x8f, 0x99, 0x97, 0x92, 0x24, 0xaf, 0xb8, 0x52, 0xde, 0xb4, 0x69, 0x76, 0x92, 0xeb, 0xa7, 0x9f, - 0xe4, 0xeb, 0xd3, 0x8a, 0x6e, 0x9c, 0x14, 0x37, 0xd1, 0xba, 0x01, 0x97, 0x23, 0xcc, 0x91, 0x8f, - 0x38, 0x12, 0xb3, 0xd3, 0x72, 0x8b, 0x67, 0xed, 0x33, 0x08, 0x13, 0x9c, 0x7a, 0x38, 0xe6, 0x28, - 0xc0, 0x62, 0x7e, 0x5a, 0xfd, 0x5e, 0x5e, 0xad, 0xdf, 0x1e, 0x5b, 0x2f, 0xcb, 0xc4, 0xcc, 0xbf, - 0x65, 0x13, 0xea, 0x44, 0x88, 0x0f, 0xed, 0x4f, 0x71, 0x80, 0xbc, 0xd1, 0x36, 0xf6, 0x1e, 0xdd, - 0xdf, 0x80, 0xea, 0xde, 0x6d, 0xec, 0xb9, 0x53, 0x49, 0xb4, 0x2f, 0x61, 0xdd, 0x43, 0x89, 0xfe, - 0xdc, 0x7f, 0xbf, 0x57, 0xf2, 0xbc, 0xda, 0x3b, 0xb0, 0x89, 0x0f, 0x12, 0x92, 0x8e, 0xf4, 0xe5, - 0x53, 0xca, 0x48, 0xf9, 0x3f, 0x63, 0xdc, 0xcb, 0x5a, 0x5b, 0x8c, 0xfb, 0x8f, 0x40, 0xb6, 0x1f, - 0xc5, 0x1e, 0x0e, 0x8f, 0xb5, 0xff, 0xff, 0x5d, 0x48, 0x73, 0x6c, 0x7e, 0x07, 0x92, 0x4e, 0x09, - 0xd4, 0x42, 0x32, 0x9f, 0xc0, 0xe7, 0x3d, 0x71, 0x8e, 0x7d, 0xb9, 0x89, 0xc0, 0x89, 0x25, 0x5c, - 0xce, 0xbb, 0x24, 0xca, 0x78, 0x7e, 0x1c, 0x2a, 0x16, 0xd2, 0x6b, 0xf0, 0x85, 0x22, 0xd5, 0x10, - 0x93, 0x60, 0x28, 0x5f, 0x32, 0x0d, 0x77, 0x75, 0x6c, 0xfe, 0x58, 0x58, 0xcb, 0xe9, 0xd6, 0x17, - 0xa5, 0x7b, 0xed, 0xaf, 0x25, 0x58, 0xdf, 0x61, 0x81, 0xf6, 0x35, 0xbc, 0x30, 0xff, 0x49, 0xf0, - 0xba, 0x5d, 0xfe, 0xbd, 0x63, 0x97, 0xbd, 0x73, 0x8d, 0xb7, 0x16, 0xf1, 0x2e, 0x6a, 0xf7, 0x0d, - 0xd4, 0x4a, 0xde, 0xce, 0x1b, 0x15, 0xb9, 0xe6, 0xdd, 0x8d, 0xb7, 0x17, 0x72, 0x2f, 0xee, 0xbe, - 0x0d, 0x60, 0xbb, 0xf4, 0xa5, 0xe8, 0x54, 0xe4, 0x2b, 0x0b, 0x30, 0x6e, 0x2c, 0x18, 0x50, 0x40, - 0xc0, 0x70, 0x65, 0x7a, 0xeb, 0xbf, 0x5a, 0x45, 0x64, 0xe2, 0x67, 0xd8, 0xa7, 0xf3, 0x9b, 0x61, - 0x5a, 0xba, 0x6c, 0xab, 0x98, 0x96, 0x05, 0x54, 0x32, 0xad, 0xd2, 0xbc, 0x84, 0x50, 0x26, 0xf8, - 0x4a, 0x08, 0x25, 0x01, 0xd5, 0x10, 0x2a, 0x74, 0x6a, 0x2c, 0xdd, 0x7e, 0x7a, 0xef, 0x2a, 0xe8, - 0xbf, 0xfb, 0xe0, 0xd0, 0x04, 0x0f, 0x0f, 0x4d, 0xf0, 0xc7, 0xa1, 0x09, 0xee, 0x1c, 0x99, 0xb5, - 0x87, 0x47, 0x66, 0xed, 0x97, 0x23, 0xb3, 0xf6, 0xc5, 0x95, 0x99, 0xd5, 0x7c, 0x30, 0xfb, 0x43, - 0x40, 0xac, 0xcc, 0x41, 0x53, 0xd8, 0xde, 0xfc, 0x27, 0x00, 0x00, 0xff, 0xff, 0x7a, 0x79, 0x89, - 0xac, 0x2c, 0x0c, 0x00, 0x00, + // 1001 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x57, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xf6, 0xc4, 0xae, 0x55, 0x4f, 0x4a, 0xa0, 0xab, 0xe0, 0x6e, 0x96, 0xe2, 0x4d, 0x7c, 0x80, + 0xa8, 0x22, 0xbb, 0xb8, 0x40, 0x0b, 0x01, 0x09, 0xd5, 0x09, 0x08, 0x24, 0x2c, 0x95, 0x0d, 0x12, + 0x12, 0x17, 0x6b, 0xbc, 0x3b, 0x1d, 0x8f, 0xba, 0xbb, 0xb3, 0xda, 0x99, 0x4d, 0xe2, 0x4a, 0x48, + 0x15, 0x12, 0xa8, 0xc7, 0x1e, 0x39, 0xf6, 0x84, 0x10, 0xa7, 0x1e, 0xfa, 0x47, 0x54, 0xe2, 0x52, + 0xf5, 0x84, 0x38, 0xb4, 0x28, 0x41, 0x2a, 0x7f, 0x03, 0xe2, 0x80, 0x76, 0x77, 0xbc, 0xb6, 0xe3, + 0xf5, 0xa6, 0xae, 0x92, 0x9e, 0x6c, 0xbf, 0x79, 0x3f, 0xbe, 0xef, 0x9b, 0xf7, 0x66, 0xc6, 0x50, + 0xb7, 0x19, 0xf7, 0x18, 0x37, 0x83, 0x90, 0x09, 0x66, 0x33, 0x37, 0x60, 0xcc, 0x35, 0x77, 0x5b, + 0xa6, 0xd8, 0x37, 0x12, 0x93, 0x52, 0x4f, 0x1d, 0x8c, 0x71, 0x07, 0x63, 0xb7, 0xa5, 0x2d, 0x13, + 0x46, 0x58, 0x62, 0x34, 0xe3, 0x6f, 0xe9, 0xba, 0xd6, 0x90, 0xe9, 0x7a, 0x88, 0x63, 0x73, 0xb7, + 0xd5, 0xc3, 0x02, 0xb5, 0x4c, 0x9b, 0x51, 0x5f, 0xae, 0xaf, 0xa4, 0xeb, 0xdd, 0x34, 0x70, 0x3c, + 0xb5, 0x76, 0x41, 0x86, 0x7a, 0x9c, 0xc4, 0x00, 0x3c, 0x4e, 0xe4, 0x82, 0x4e, 0x18, 0x23, 0x2e, + 0x4e, 0x21, 0xf6, 0xa2, 0x1b, 0xa6, 0xa0, 0x1e, 0xe6, 0x02, 0x79, 0xc1, 0xb0, 0xe8, 0x51, 0x07, + 0x27, 0x0a, 0x91, 0xa0, 0x4c, 0x16, 0x6d, 0xfe, 0x0e, 0xe0, 0x72, 0x87, 0x93, 0xcf, 0x23, 0xdf, + 0xd9, 0x62, 0x9e, 0x17, 0xf9, 0x54, 0x0c, 0xae, 0x33, 0xe6, 0x2a, 0x36, 0xac, 0x22, 0x8f, 0x45, + 0xbe, 0x50, 0xc1, 0x6a, 0x79, 0x7d, 0xf1, 0xf2, 0x8a, 0x21, 0x11, 0xc5, 0xf0, 0x0d, 0x09, 0xdf, + 0xd8, 0x62, 0xd4, 0x6f, 0xbf, 0xfb, 0xf0, 0x89, 0x5e, 0xfa, 0xed, 0xa9, 0xbe, 0x4e, 0xa8, 0xe8, + 0x47, 0x3d, 0xc3, 0x66, 0x9e, 0x84, 0x2f, 0x3f, 0x36, 0xb8, 0x73, 0xd3, 0x14, 0x83, 0x00, 0xf3, + 0x24, 0x80, 0x5b, 0x32, 0xb5, 0x72, 0x05, 0xd6, 0x1c, 0x1c, 0x30, 0x4e, 0x05, 0x0b, 0xd5, 0x85, + 0x55, 0xb0, 0x5e, 0x6b, 0xab, 0x8f, 0x1f, 0x6c, 0x2c, 0xcb, 0x52, 0xd7, 0x1c, 0x27, 0xc4, 0x9c, + 0xef, 0x88, 0x90, 0xfa, 0xc4, 0x1a, 0xb9, 0x6e, 0xd6, 0xef, 0xdc, 0xd3, 0x4b, 0xff, 0xdc, 0xd3, + 0x4b, 0x3f, 0x3c, 0xbb, 0x7f, 0x69, 0x64, 0x6f, 0x36, 0xe0, 0xc5, 0x3c, 0x32, 0x16, 0xe6, 0x01, + 0xf3, 0x39, 0x6e, 0x1e, 0x00, 0xf8, 0x7a, 0x87, 0x93, 0x89, 0xc5, 0x9d, 0x00, 0xfb, 0x4e, 0x8c, + 0x04, 0x45, 0xa2, 0xcf, 0x42, 0x2a, 0x06, 0x2a, 0x38, 0x0e, 0x49, 0xe6, 0xaa, 0x5c, 0x84, 0xb5, + 0x10, 0xdb, 0x34, 0xa0, 0xd8, 0x17, 0x29, 0x03, 0x6b, 0x64, 0x18, 0x13, 0xb1, 0x7c, 0x6a, 0x22, + 0x6e, 0x2e, 0x25, 0x22, 0x64, 0x90, 0x9a, 0x3a, 0x7c, 0x33, 0x97, 0x63, 0xa6, 0xc2, 0x7f, 0x0b, + 0xf0, 0x42, 0x87, 0x93, 0x9d, 0xa8, 0xe7, 0x51, 0xd1, 0x8e, 0x1c, 0x82, 0xc5, 0xf5, 0x90, 0x05, + 0x8c, 0x23, 0xf7, 0x85, 0x75, 0xf8, 0x0c, 0x9e, 0xcf, 0x68, 0x77, 0x51, 0xea, 0x75, 0xec, 0x8e, + 0xbe, 0x96, 0x85, 0x48, 0xbb, 0xf2, 0x09, 0x3c, 0x27, 0x98, 0x40, 0x6e, 0xb7, 0x97, 0xc0, 0x52, + 0xcb, 0xab, 0xa0, 0x50, 0x36, 0x6b, 0x31, 0x71, 0x4f, 0x49, 0x28, 0x9f, 0x42, 0xc8, 0x05, 0x0a, + 0x45, 0x37, 0x9e, 0x02, 0xb5, 0x92, 0xc4, 0x6a, 0x46, 0x3a, 0x01, 0xc6, 0x70, 0x02, 0x8c, 0x6f, + 0x86, 0x23, 0xd2, 0xae, 0xdc, 0x7d, 0xaa, 0x03, 0xab, 0x96, 0xc4, 0xc4, 0x56, 0x45, 0x83, 0x67, + 0x45, 0x88, 0x7c, 0xbb, 0x8f, 0xb9, 0x7a, 0x66, 0x15, 0xac, 0x57, 0xac, 0xec, 0xb7, 0x72, 0x15, + 0x56, 0x03, 0x1c, 0x52, 0xe6, 0xa8, 0x55, 0x09, 0xea, 0x68, 0xe2, 0x6d, 0x39, 0x5a, 0xed, 0xca, + 0xcf, 0x71, 0x5e, 0xe9, 0x3e, 0xb5, 0x3f, 0x6b, 0x50, 0x9f, 0xa1, 0x7e, 0xb6, 0x43, 0x0c, 0x2e, + 0xc5, 0x5b, 0xe8, 0x22, 0xea, 0x49, 0x6a, 0xb9, 0xfa, 0x82, 0x79, 0xf5, 0xdd, 0xac, 0xc7, 0x58, + 0xa6, 0x33, 0x35, 0xbf, 0x87, 0xf5, 0xc9, 0x82, 0x43, 0x28, 0x13, 0xe7, 0x00, 0x38, 0xa5, 0x16, + 0x6e, 0xfe, 0x92, 0x76, 0xe4, 0x56, 0x88, 0x91, 0xc0, 0x5b, 0xcc, 0x17, 0xd4, 0x8f, 0x58, 0xc4, + 0xe3, 0x41, 0x7e, 0xe1, 0x8e, 0xbc, 0x32, 0x35, 0x99, 0x45, 0x71, 0xa3, 0x99, 0xfd, 0x1a, 0xc2, + 0x00, 0x87, 0x36, 0xf6, 0x05, 0x22, 0x38, 0x69, 0xc0, 0x5a, 0xbb, 0x15, 0x33, 0xfb, 0xf3, 0x89, + 0xfe, 0x46, 0x1a, 0xcc, 0x9d, 0x9b, 0x06, 0x65, 0xa6, 0x87, 0x44, 0xdf, 0xf8, 0x0a, 0x13, 0x64, + 0x0f, 0xb6, 0xb1, 0xfd, 0xf8, 0xc1, 0x06, 0x94, 0xb9, 0xb7, 0xb1, 0x6d, 0x8d, 0x25, 0x51, 0x3e, + 0x84, 0x55, 0xbc, 0x1f, 0xd0, 0x70, 0xf0, 0xdc, 0x3d, 0x29, 0xfd, 0x67, 0xf4, 0x4e, 0x9e, 0x4e, + 0x59, 0xef, 0xfc, 0x0a, 0x52, 0x2d, 0x91, 0x6f, 0x63, 0xf7, 0x84, 0xb4, 0x3c, 0x99, 0xe9, 0x9e, + 0x62, 0xf3, 0xf7, 0x42, 0x4a, 0x27, 0x07, 0x6a, 0xd6, 0x7f, 0x5f, 0xc2, 0x57, 0xec, 0x64, 0x1d, + 0x3b, 0xe9, 0x58, 0x83, 0x63, 0x25, 0x3c, 0x1b, 0xef, 0x56, 0x22, 0xe3, 0xb9, 0x61, 0x68, 0x32, + 0xdd, 0x6f, 0xc3, 0x57, 0xb3, 0x54, 0x7d, 0x4c, 0x49, 0x3f, 0xed, 0x8b, 0x8a, 0xb5, 0x34, 0x34, + 0x7f, 0x91, 0x58, 0xf3, 0xe9, 0x96, 0xe7, 0x3e, 0xcc, 0x7e, 0x04, 0x50, 0xdd, 0xa3, 0xa2, 0xef, + 0x84, 0x68, 0xcf, 0xef, 0x22, 0xd7, 0x65, 0x36, 0x12, 0xd8, 0xe9, 0xde, 0x88, 0x7c, 0x47, 0x76, + 0xc2, 0x89, 0x4e, 0x53, 0x3d, 0x2b, 0x76, 0x6d, 0x58, 0x2b, 0x96, 0xb2, 0x79, 0x0b, 0xae, 0x74, + 0x38, 0xf9, 0x56, 0x2e, 0x1e, 0x69, 0x89, 0x53, 0x3e, 0x58, 0xee, 0x00, 0xb8, 0x36, 0xb3, 0xf8, + 0x4b, 0x3d, 0x64, 0x2e, 0xff, 0x5b, 0x85, 0xe5, 0x0e, 0x27, 0xca, 0x1e, 0x3c, 0x3f, 0xfd, 0xdc, + 0x79, 0xc7, 0xc8, 0x7f, 0xcb, 0x19, 0x79, 0xef, 0x09, 0xed, 0xfd, 0x79, 0xbc, 0x33, 0x96, 0xb7, + 0xa0, 0x92, 0xf3, 0xf2, 0xd8, 0x28, 0xc8, 0x35, 0xed, 0xae, 0x7d, 0x30, 0x97, 0x7b, 0x56, 0xfb, + 0x36, 0x80, 0xcb, 0xb9, 0x17, 0xbe, 0x59, 0x90, 0x2f, 0x2f, 0x40, 0xbb, 0x3a, 0x67, 0x40, 0x06, + 0x01, 0xc3, 0xc5, 0xf1, 0x1b, 0xed, 0xad, 0x22, 0x22, 0x23, 0x3f, 0xcd, 0x78, 0x3e, 0xbf, 0x09, + 0xa6, 0xb9, 0x17, 0x49, 0x11, 0xd3, 0xbc, 0x80, 0x42, 0xa6, 0x45, 0x47, 0xb0, 0xf2, 0x13, 0x80, + 0xf5, 0x19, 0xe3, 0xd6, 0x2a, 0xc8, 0x99, 0x1f, 0xa2, 0x7d, 0x34, 0x77, 0xc8, 0xa4, 0x16, 0x79, + 0x17, 0x41, 0xa1, 0x16, 0x39, 0x01, 0xc5, 0x5a, 0x14, 0x9c, 0xdf, 0xda, 0x99, 0xdb, 0xcf, 0xee, + 0x5f, 0x02, 0xed, 0x8f, 0x1f, 0x1e, 0x34, 0xc0, 0xa3, 0x83, 0x06, 0xf8, 0xeb, 0xa0, 0x01, 0xee, + 0x1e, 0x36, 0x4a, 0x8f, 0x0e, 0x1b, 0xa5, 0x3f, 0x0e, 0x1b, 0xa5, 0xef, 0xd6, 0x26, 0xee, 0xd4, + 0xfd, 0xc9, 0x7f, 0x5b, 0xc9, 0x1c, 0xf7, 0xaa, 0x89, 0xed, 0xbd, 0xff, 0x03, 0x00, 0x00, 0xff, + 0xff, 0xbe, 0xf0, 0xd2, 0xdd, 0x91, 0x0d, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -810,6 +878,8 @@ type MsgClient interface { ClaimBudget(ctx context.Context, in *MsgClaimBudget, opts ...grpc.CallOption) (*MsgClaimBudgetResponse, error) // CreateContinuousFund defines a method to add funds continuously. CreateContinuousFund(ctx context.Context, in *MsgCreateContinuousFund, opts ...grpc.CallOption) (*MsgCreateContinuousFundResponse, error) + // WithdrawContinuousFund defines a method to withdraw continuous fund allocated. + WithdrawContinuousFund(ctx context.Context, in *MsgWithdrawContinuousFund, opts ...grpc.CallOption) (*MsgWithdrawContinuousFundResponse, error) // CancelContinuousFund defines a method for cancelling continuous fund. CancelContinuousFund(ctx context.Context, in *MsgCancelContinuousFund, opts ...grpc.CallOption) (*MsgCancelContinuousFundResponse, error) } @@ -867,6 +937,15 @@ func (c *msgClient) CreateContinuousFund(ctx context.Context, in *MsgCreateConti return out, nil } +func (c *msgClient) WithdrawContinuousFund(ctx context.Context, in *MsgWithdrawContinuousFund, opts ...grpc.CallOption) (*MsgWithdrawContinuousFundResponse, error) { + out := new(MsgWithdrawContinuousFundResponse) + err := c.cc.Invoke(ctx, "/cosmos.protocolpool.v1.Msg/WithdrawContinuousFund", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *msgClient) CancelContinuousFund(ctx context.Context, in *MsgCancelContinuousFund, opts ...grpc.CallOption) (*MsgCancelContinuousFundResponse, error) { out := new(MsgCancelContinuousFundResponse) err := c.cc.Invoke(ctx, "/cosmos.protocolpool.v1.Msg/CancelContinuousFund", in, out, opts...) @@ -892,6 +971,8 @@ type MsgServer interface { ClaimBudget(context.Context, *MsgClaimBudget) (*MsgClaimBudgetResponse, error) // CreateContinuousFund defines a method to add funds continuously. CreateContinuousFund(context.Context, *MsgCreateContinuousFund) (*MsgCreateContinuousFundResponse, error) + // WithdrawContinuousFund defines a method to withdraw continuous fund allocated. + WithdrawContinuousFund(context.Context, *MsgWithdrawContinuousFund) (*MsgWithdrawContinuousFundResponse, error) // CancelContinuousFund defines a method for cancelling continuous fund. CancelContinuousFund(context.Context, *MsgCancelContinuousFund) (*MsgCancelContinuousFundResponse, error) } @@ -915,6 +996,9 @@ func (*UnimplementedMsgServer) ClaimBudget(ctx context.Context, req *MsgClaimBud func (*UnimplementedMsgServer) CreateContinuousFund(ctx context.Context, req *MsgCreateContinuousFund) (*MsgCreateContinuousFundResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateContinuousFund not implemented") } +func (*UnimplementedMsgServer) WithdrawContinuousFund(ctx context.Context, req *MsgWithdrawContinuousFund) (*MsgWithdrawContinuousFundResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WithdrawContinuousFund not implemented") +} func (*UnimplementedMsgServer) CancelContinuousFund(ctx context.Context, req *MsgCancelContinuousFund) (*MsgCancelContinuousFundResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CancelContinuousFund not implemented") } @@ -1013,6 +1097,24 @@ func _Msg_CreateContinuousFund_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +func _Msg_WithdrawContinuousFund_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWithdrawContinuousFund) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).WithdrawContinuousFund(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cosmos.protocolpool.v1.Msg/WithdrawContinuousFund", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).WithdrawContinuousFund(ctx, req.(*MsgWithdrawContinuousFund)) + } + return interceptor(ctx, in, info, handler) +} + func _Msg_CancelContinuousFund_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCancelContinuousFund) if err := dec(in); err != nil { @@ -1055,6 +1157,10 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "CreateContinuousFund", Handler: _Msg_CreateContinuousFund_Handler, }, + { + MethodName: "WithdrawContinuousFund", + Handler: _Msg_WithdrawContinuousFund_Handler, + }, { MethodName: "CancelContinuousFund", Handler: _Msg_CancelContinuousFund_Handler, @@ -1393,21 +1499,7 @@ func (m *MsgCreateContinuousFund) MarshalToSizedBuffer(dAtA []byte) (int, error) i -= n5 i = encodeVarintTx(dAtA, i, uint64(n5)) i-- - dAtA[i] = 0x42 - } - if len(m.Cap) > 0 { - for iNdEx := len(m.Cap) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Cap[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintTx(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x3a - } + dAtA[i] = 0x22 } { size := m.Percentage.Size() @@ -1418,40 +1510,19 @@ func (m *MsgCreateContinuousFund) MarshalToSizedBuffer(dAtA []byte) (int, error) i = encodeVarintTx(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x32 - if len(m.Metadata) > 0 { - i -= len(m.Metadata) - copy(dAtA[i:], m.Metadata) - i = encodeVarintTx(dAtA, i, uint64(len(m.Metadata))) - i-- - dAtA[i] = 0x2a - } + dAtA[i] = 0x1a if len(m.Recipient) > 0 { i -= len(m.Recipient) copy(dAtA[i:], m.Recipient) i = encodeVarintTx(dAtA, i, uint64(len(m.Recipient))) i-- - dAtA[i] = 0x22 + dAtA[i] = 0x12 } if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- - dAtA[i] = 0x1a - } - if len(m.Description) > 0 { - i -= len(m.Description) - copy(dAtA[i:], m.Description) - i = encodeVarintTx(dAtA, i, uint64(len(m.Description))) - i-- - dAtA[i] = 0x12 - } - if len(m.Title) > 0 { - i -= len(m.Title) - copy(dAtA[i:], m.Title) - i = encodeVarintTx(dAtA, i, uint64(len(m.Title))) - i-- dAtA[i] = 0xa } return len(dAtA) - i, nil @@ -1537,6 +1608,16 @@ func (m *MsgCancelContinuousFundResponse) MarshalToSizedBuffer(dAtA []byte) (int _ = i var l int _ = l + { + size, err := m.WithdrawnAllocatedFund.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 if len(m.RecipientAddress) > 0 { i -= len(m.RecipientAddress) copy(dAtA[i:], m.RecipientAddress) @@ -1549,12 +1630,75 @@ func (m *MsgCancelContinuousFundResponse) MarshalToSizedBuffer(dAtA []byte) (int i-- dAtA[i] = 0x10 } - n6, err6 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.CanceledTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.CanceledTime):]) - if err6 != nil { - return 0, err6 + n7, err7 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.CanceledTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.CanceledTime):]) + if err7 != nil { + return 0, err7 + } + i -= n7 + i = encodeVarintTx(dAtA, i, uint64(n7)) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *MsgWithdrawContinuousFund) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgWithdrawContinuousFund) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgWithdrawContinuousFund) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.RecipientAddress) > 0 { + i -= len(m.RecipientAddress) + copy(dAtA[i:], m.RecipientAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.RecipientAddress))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgWithdrawContinuousFundResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgWithdrawContinuousFundResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgWithdrawContinuousFundResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) } - i -= n6 - i = encodeVarintTx(dAtA, i, uint64(n6)) i-- dAtA[i] = 0xa return len(dAtA) - i, nil @@ -1702,14 +1846,6 @@ func (m *MsgCreateContinuousFund) Size() (n int) { } var l int _ = l - l = len(m.Title) - if l > 0 { - n += 1 + l + sovTx(uint64(l)) - } - l = len(m.Description) - if l > 0 { - n += 1 + l + sovTx(uint64(l)) - } l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) @@ -1718,18 +1854,8 @@ func (m *MsgCreateContinuousFund) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.Metadata) - if l > 0 { - n += 1 + l + sovTx(uint64(l)) - } l = m.Percentage.Size() n += 1 + l + sovTx(uint64(l)) - if len(m.Cap) > 0 { - for _, e := range m.Cap { - l = e.Size() - n += 1 + l + sovTx(uint64(l)) - } - } if m.Expiry != nil { l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.Expiry) n += 1 + l + sovTx(uint64(l)) @@ -1778,6 +1904,32 @@ func (m *MsgCancelContinuousFundResponse) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } + l = m.WithdrawnAllocatedFund.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgWithdrawContinuousFund) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.RecipientAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgWithdrawContinuousFundResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) return n } @@ -2638,7 +2790,7 @@ func (m *MsgCreateContinuousFund) Unmarshal(dAtA []byte) error { switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2666,11 +2818,11 @@ func (m *MsgCreateContinuousFund) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Title = string(dAtA[iNdEx:postIndex]) + m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2698,11 +2850,11 @@ func (m *MsgCreateContinuousFund) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Description = string(dAtA[iNdEx:postIndex]) + m.Recipient = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Percentage", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2730,13 +2882,15 @@ func (m *MsgCreateContinuousFund) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Authority = string(dAtA[iNdEx:postIndex]) + if err := m.Percentage.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Expiry", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx @@ -2746,155 +2900,23 @@ func (m *MsgCreateContinuousFund) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthTx } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } - m.Recipient = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTx - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthTx - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthTx - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Metadata = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Percentage", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTx - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthTx - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthTx - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Percentage.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 7: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Cap", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTx - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthTx - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthTx - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Cap = append(m.Cap, types.Coin{}) - if err := m.Cap[len(m.Cap)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Expiry", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTx - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthTx - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthTx - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Expiry == nil { - m.Expiry = new(time.Time) + if m.Expiry == nil { + m.Expiry = new(time.Time) } if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.Expiry, dAtA[iNdEx:postIndex]); err != nil { return err @@ -3198,6 +3220,204 @@ func (m *MsgCancelContinuousFundResponse) Unmarshal(dAtA []byte) error { } m.RecipientAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field WithdrawnAllocatedFund", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.WithdrawnAllocatedFund.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgWithdrawContinuousFund) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgWithdrawContinuousFund: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgWithdrawContinuousFund: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RecipientAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RecipientAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgWithdrawContinuousFundResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgWithdrawContinuousFundResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgWithdrawContinuousFundResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) diff --git a/x/protocolpool/types/types.pb.go b/x/protocolpool/types/types.pb.go index ce3bf504aa9a..2632aa829401 100644 --- a/x/protocolpool/types/types.pb.go +++ b/x/protocolpool/types/types.pb.go @@ -4,6 +4,7 @@ package types import ( + cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" _ "github.com/cosmos/cosmos-proto" types "github.com/cosmos/cosmos-sdk/types" @@ -142,8 +143,66 @@ func (m *Budget) GetPeriod() *time.Duration { return nil } +// ContinuousFund defines the fields of continuous fund proposal. +type ContinuousFund struct { + // Recipient address of the account receiving funds. + Recipient string `protobuf:"bytes,1,opt,name=recipient,proto3" json:"recipient,omitempty"` + // Percentage is the percentage of funds to be allocated from Community pool. + Percentage cosmossdk_io_math.LegacyDec `protobuf:"bytes,2,opt,name=percentage,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"percentage"` + // Optional, if expiry is set, removes the state object when expired. + Expiry *time.Time `protobuf:"bytes,3,opt,name=expiry,proto3,stdtime" json:"expiry,omitempty"` +} + +func (m *ContinuousFund) Reset() { *m = ContinuousFund{} } +func (m *ContinuousFund) String() string { return proto.CompactTextString(m) } +func (*ContinuousFund) ProtoMessage() {} +func (*ContinuousFund) Descriptor() ([]byte, []int) { + return fileDescriptor_c1b7d0ea246d7f44, []int{1} +} +func (m *ContinuousFund) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *ContinuousFund) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_ContinuousFund.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *ContinuousFund) XXX_Merge(src proto.Message) { + xxx_messageInfo_ContinuousFund.Merge(m, src) +} +func (m *ContinuousFund) XXX_Size() int { + return m.Size() +} +func (m *ContinuousFund) XXX_DiscardUnknown() { + xxx_messageInfo_ContinuousFund.DiscardUnknown(m) +} + +var xxx_messageInfo_ContinuousFund proto.InternalMessageInfo + +func (m *ContinuousFund) GetRecipient() string { + if m != nil { + return m.Recipient + } + return "" +} + +func (m *ContinuousFund) GetExpiry() *time.Time { + if m != nil { + return m.Expiry + } + return nil +} + func init() { proto.RegisterType((*Budget)(nil), "cosmos.protocolpool.v1.Budget") + proto.RegisterType((*ContinuousFund)(nil), "cosmos.protocolpool.v1.ContinuousFund") } func init() { @@ -151,35 +210,41 @@ func init() { } var fileDescriptor_c1b7d0ea246d7f44 = []byte{ - // 444 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x52, 0x3f, 0x6f, 0xd4, 0x30, - 0x1c, 0xbd, 0xd0, 0xe3, 0x68, 0xdd, 0x1e, 0x7f, 0xa2, 0x0a, 0xb9, 0x19, 0xd2, 0xa3, 0x2c, 0xb7, - 0xe0, 0xe8, 0x60, 0x60, 0x00, 0x09, 0x9a, 0x02, 0x62, 0x60, 0x3a, 0x98, 0x58, 0x2c, 0x27, 0xf1, - 0x05, 0x8b, 0x24, 0xbf, 0xc8, 0xfe, 0xdd, 0xa9, 0x7c, 0x8b, 0x8e, 0x7c, 0x10, 0x3e, 0x04, 0x63, - 0x85, 0x18, 0xd8, 0x40, 0x77, 0x5f, 0x04, 0xc5, 0x76, 0xaa, 0xd2, 0x85, 0x6e, 0xce, 0xfb, 0xbd, - 0xf7, 0xf2, 0xfc, 0xfc, 0x23, 0x47, 0x39, 0x98, 0x1a, 0x4c, 0xd2, 0x6a, 0x40, 0xc8, 0xa1, 0x6a, - 0x01, 0xaa, 0x64, 0x35, 0x4b, 0xf0, 0x4b, 0x2b, 0x0d, 0xb3, 0x68, 0x78, 0xdf, 0x71, 0xd8, 0x65, - 0x0e, 0x5b, 0xcd, 0xa2, 0xfd, 0x12, 0x4a, 0xb0, 0x60, 0xd2, 0x9d, 0xdc, 0x3c, 0x3a, 0x70, 0x6c, - 0xee, 0x06, 0x97, 0xa5, 0x51, 0xec, 0x7f, 0x96, 0x09, 0x23, 0x93, 0xd5, 0x2c, 0x93, 0x28, 0x66, - 0x49, 0x0e, 0xaa, 0xf1, 0xf3, 0xc3, 0x12, 0xa0, 0xac, 0xa4, 0x0b, 0x93, 0x2d, 0x17, 0x09, 0xaa, - 0x5a, 0x1a, 0x14, 0x75, 0xdb, 0x1b, 0x5c, 0x25, 0x14, 0x4b, 0x2d, 0x50, 0x81, 0x37, 0x38, 0xfa, - 0xb9, 0x45, 0x46, 0xe9, 0xb2, 0x28, 0x25, 0x86, 0xaf, 0xc9, 0x3d, 0x2d, 0x73, 0xd5, 0x2a, 0xd9, - 0x20, 0x17, 0x45, 0xa1, 0xa5, 0x31, 0x34, 0x98, 0x04, 0xd3, 0x9d, 0x94, 0xfe, 0xf8, 0xf6, 0x68, - 0xdf, 0x07, 0x3b, 0x76, 0x93, 0xf7, 0xa8, 0x55, 0x53, 0xce, 0xef, 0x5e, 0x48, 0x3c, 0x1e, 0x3e, - 0x27, 0x7b, 0x08, 0x28, 0x2a, 0x9e, 0x59, 0x5b, 0x7a, 0x63, 0x12, 0x4c, 0x77, 0x1f, 0x1f, 0x30, - 0x2f, 0xef, 0x6e, 0xc2, 0xfc, 0x4d, 0xd8, 0x09, 0xa8, 0x66, 0xbe, 0x6b, 0xe9, 0x3e, 0xc4, 0x4b, - 0x72, 0x3b, 0xaf, 0x84, 0xaa, 0x65, 0xc1, 0x45, 0x0d, 0xcb, 0x06, 0xe9, 0xd6, 0xff, 0xf4, 0x63, - 0x2f, 0x38, 0xb6, 0xfc, 0xf0, 0x05, 0x21, 0x06, 0x85, 0x46, 0xde, 0x55, 0x41, 0x87, 0x56, 0x1d, - 0x31, 0x57, 0x03, 0xeb, 0x6b, 0x60, 0x1f, 0xfa, 0x9e, 0xd2, 0xe1, 0xd9, 0xef, 0xc3, 0x60, 0xbe, - 0x63, 0x35, 0x1d, 0x1a, 0xbe, 0x25, 0x77, 0x1a, 0x79, 0x8a, 0xdc, 0xda, 0xf2, 0x85, 0x86, 0x9a, - 0xde, 0xbc, 0xa6, 0xcb, 0xb8, 0x13, 0x9e, 0x74, 0xba, 0x37, 0x1a, 0xea, 0x30, 0x22, 0xdb, 0xa8, - 0x45, 0x93, 0x7f, 0x92, 0x86, 0x8e, 0x26, 0xc1, 0x74, 0x38, 0xbf, 0xf8, 0x0e, 0x1f, 0x92, 0x71, - 0x7f, 0xe6, 0x95, 0x5c, 0x20, 0xbd, 0x65, 0x09, 0x7b, 0x3d, 0xf8, 0x4e, 0x2e, 0x30, 0x7c, 0x4a, - 0x46, 0xad, 0xd4, 0x0a, 0x0a, 0xba, 0xed, 0x5b, 0xb8, 0x9a, 0xe0, 0x95, 0x7f, 0xce, 0x74, 0xf8, - 0xb5, 0x0b, 0xe0, 0xe9, 0xe9, 0xb3, 0xef, 0xeb, 0x38, 0x38, 0x5f, 0xc7, 0xc1, 0x9f, 0x75, 0x1c, - 0x9c, 0x6d, 0xe2, 0xc1, 0xf9, 0x26, 0x1e, 0xfc, 0xda, 0xc4, 0x83, 0x8f, 0x0f, 0x5c, 0x8f, 0xa6, - 0xf8, 0xcc, 0x14, 0x24, 0xa7, 0xff, 0xae, 0xb1, 0xdd, 0xe1, 0x6c, 0x64, 0xb1, 0x27, 0x7f, 0x03, - 0x00, 0x00, 0xff, 0xff, 0x07, 0x16, 0x5b, 0x67, 0xea, 0x02, 0x00, 0x00, + // 531 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x53, 0xc1, 0x6e, 0xd3, 0x40, + 0x14, 0x8c, 0x69, 0x08, 0xcd, 0xb6, 0x29, 0x60, 0x55, 0xc8, 0x0d, 0x92, 0x13, 0xc2, 0x25, 0x97, + 0xda, 0x0a, 0x48, 0x80, 0x04, 0x12, 0xd4, 0x09, 0x15, 0x87, 0x5e, 0x08, 0x9c, 0xb8, 0x58, 0x1b, + 0xfb, 0xc5, 0x5d, 0x61, 0xfb, 0x59, 0xbb, 0xeb, 0x28, 0xf9, 0x8b, 0x1e, 0xf9, 0x90, 0x7e, 0x44, + 0x8f, 0x55, 0x05, 0x12, 0xe2, 0x50, 0x50, 0xf2, 0x23, 0xc8, 0xeb, 0x4d, 0x48, 0x7b, 0x09, 0xb7, + 0xf5, 0xbc, 0x99, 0xf1, 0xec, 0x3c, 0x2d, 0xe9, 0x04, 0x28, 0x12, 0x14, 0x6e, 0xc6, 0x51, 0x62, + 0x80, 0x71, 0x86, 0x18, 0xbb, 0x93, 0x9e, 0x2b, 0x67, 0x19, 0x08, 0x47, 0xa1, 0xe6, 0xa3, 0x92, + 0xe3, 0xac, 0x73, 0x9c, 0x49, 0xaf, 0xb9, 0x1f, 0x61, 0x84, 0x0a, 0x74, 0x8b, 0x53, 0x39, 0x6f, + 0x1e, 0x94, 0x6c, 0xbf, 0x1c, 0xac, 0x4b, 0x9b, 0xb6, 0xfe, 0xd9, 0x88, 0x0a, 0x70, 0x27, 0xbd, + 0x11, 0x48, 0xda, 0x73, 0x03, 0x64, 0xa9, 0x9e, 0xb7, 0x22, 0xc4, 0x28, 0x86, 0x32, 0xcc, 0x28, + 0x1f, 0xbb, 0x92, 0x25, 0x20, 0x24, 0x4d, 0xb2, 0xa5, 0xc1, 0x6d, 0x42, 0x98, 0x73, 0x2a, 0x19, + 0x6a, 0x83, 0xce, 0xf7, 0x2d, 0x52, 0xf3, 0xf2, 0x30, 0x02, 0x69, 0xbe, 0x27, 0x0f, 0x39, 0x04, + 0x2c, 0x63, 0x90, 0x4a, 0x9f, 0x86, 0x21, 0x07, 0x21, 0x2c, 0xa3, 0x6d, 0x74, 0xeb, 0x9e, 0x75, + 0x75, 0x7e, 0xb8, 0xaf, 0x83, 0x1d, 0x95, 0x93, 0x4f, 0x92, 0xb3, 0x34, 0x1a, 0x3e, 0x58, 0x49, + 0x34, 0x6e, 0xbe, 0x21, 0xbb, 0x12, 0x25, 0x8d, 0xfd, 0x91, 0xb2, 0xb5, 0xee, 0xb4, 0x8d, 0xee, + 0xce, 0xb3, 0x03, 0x47, 0xcb, 0x8b, 0x9b, 0x38, 0xfa, 0x26, 0x4e, 0x1f, 0x59, 0x3a, 0xdc, 0x51, + 0x74, 0x1d, 0xe2, 0x1d, 0xd9, 0x0b, 0x62, 0xca, 0x12, 0x08, 0x7d, 0x9a, 0x60, 0x9e, 0x4a, 0x6b, + 0x6b, 0x93, 0xbe, 0xa1, 0x05, 0x47, 0x8a, 0x6f, 0xbe, 0x25, 0x44, 0x48, 0xca, 0xa5, 0x5f, 0x54, + 0x61, 0x55, 0x95, 0xba, 0xe9, 0x94, 0x35, 0x38, 0xcb, 0x1a, 0x9c, 0xcf, 0xcb, 0x9e, 0xbc, 0xea, + 0xd9, 0xef, 0x96, 0x31, 0xac, 0x2b, 0x4d, 0x81, 0x9a, 0x1f, 0xc8, 0xfd, 0x14, 0xa6, 0xd2, 0x57, + 0xb6, 0xfe, 0x98, 0x63, 0x62, 0xdd, 0xfd, 0x4f, 0x97, 0x46, 0x21, 0xec, 0x17, 0xba, 0x63, 0x8e, + 0x89, 0xd9, 0x24, 0xdb, 0x92, 0xd3, 0x34, 0x38, 0x05, 0x61, 0xd5, 0xda, 0x46, 0xb7, 0x3a, 0x5c, + 0x7d, 0x9b, 0x4f, 0x49, 0x63, 0x79, 0xf6, 0x63, 0x18, 0x4b, 0xeb, 0x9e, 0x22, 0xec, 0x2e, 0xc1, + 0x13, 0x18, 0x4b, 0xf3, 0x25, 0xa9, 0x65, 0xc0, 0x19, 0x86, 0xd6, 0xb6, 0x6e, 0xe1, 0x76, 0x82, + 0x81, 0x5e, 0xa7, 0x57, 0xfd, 0x56, 0x04, 0xd0, 0xf4, 0xce, 0x0f, 0x83, 0xec, 0xf5, 0x31, 0x95, + 0x2c, 0xcd, 0x31, 0x17, 0xc7, 0x79, 0x1a, 0x9a, 0x2f, 0x48, 0x7d, 0xb5, 0xab, 0x8d, 0x6b, 0xfd, + 0x47, 0x35, 0x3f, 0x12, 0x92, 0x01, 0x0f, 0x20, 0x95, 0x34, 0x02, 0xb5, 0xcd, 0xba, 0xd7, 0xbb, + 0xb8, 0x6e, 0x55, 0x7e, 0x5d, 0xb7, 0x1e, 0x97, 0x62, 0x11, 0x7e, 0x75, 0x18, 0xba, 0x09, 0x95, + 0xa7, 0xce, 0x09, 0x44, 0x34, 0x98, 0x0d, 0x20, 0xb8, 0x3a, 0x3f, 0x24, 0xda, 0x7b, 0x00, 0xc1, + 0x70, 0xcd, 0xc4, 0x7c, 0x45, 0x6a, 0x30, 0xcd, 0x18, 0x9f, 0xe9, 0xe5, 0x6e, 0x2e, 0x56, 0xf3, + 0xbd, 0xd7, 0x17, 0x73, 0xdb, 0xb8, 0x9c, 0xdb, 0xc6, 0x9f, 0xb9, 0x6d, 0x9c, 0x2d, 0xec, 0xca, + 0xe5, 0xc2, 0xae, 0xfc, 0x5c, 0xd8, 0x95, 0x2f, 0x4f, 0x6e, 0x44, 0x99, 0xde, 0x7c, 0x9e, 0xea, + 0x6d, 0x8e, 0x6a, 0x0a, 0x7b, 0xfe, 0x37, 0x00, 0x00, 0xff, 0xff, 0xb0, 0x0b, 0xb8, 0xdb, 0xc2, + 0x03, 0x00, 0x00, } func (m *Budget) Marshal() (dAtA []byte, err error) { @@ -276,6 +341,56 @@ func (m *Budget) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *ContinuousFund) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ContinuousFund) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *ContinuousFund) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Expiry != nil { + n6, err6 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.Expiry, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.Expiry):]) + if err6 != nil { + return 0, err6 + } + i -= n6 + i = encodeVarintTypes(dAtA, i, uint64(n6)) + i-- + dAtA[i] = 0x1a + } + { + size := m.Percentage.Size() + i -= size + if _, err := m.Percentage.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + if len(m.Recipient) > 0 { + i -= len(m.Recipient) + copy(dAtA[i:], m.Recipient) + i = encodeVarintTypes(dAtA, i, uint64(len(m.Recipient))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset @@ -326,6 +441,25 @@ func (m *Budget) Size() (n int) { return n } +func (m *ContinuousFund) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Recipient) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } + l = m.Percentage.Size() + n += 1 + l + sovTypes(uint64(l)) + if m.Expiry != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.Expiry) + n += 1 + l + sovTypes(uint64(l)) + } + return n +} + func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -632,6 +766,158 @@ func (m *Budget) Unmarshal(dAtA []byte) error { } return nil } +func (m *ContinuousFund) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ContinuousFund: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ContinuousFund: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Recipient = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Percentage", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Percentage.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Expiry", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Expiry == nil { + m.Expiry = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.Expiry, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTypes(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTypes + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 From e1f478da4114bd5eec93ec1b62826b4c8355bfa9 Mon Sep 17 00:00:00 2001 From: testinginprod <98415576+testinginprod@users.noreply.github.com> Date: Tue, 9 Jan 2024 19:23:41 +0100 Subject: [PATCH 11/28] feat(accounts): implement Account Number query (#18989) Co-authored-by: unknown unknown Co-authored-by: Marko Co-authored-by: Facundo Medica <14063057+facundomedica@users.noreply.github.com> --- api/cosmos/accounts/v1/query.pulsar.go | 1438 +++++++++++++++++++---- api/cosmos/accounts/v1/query_grpc.pb.go | 39 + proto/cosmos/accounts/v1/query.proto | 15 + x/accounts/query_server.go | 13 + x/accounts/query_server_test.go | 37 +- x/accounts/v1/query.pb.go | 447 ++++++- 6 files changed, 1689 insertions(+), 300 deletions(-) diff --git a/api/cosmos/accounts/v1/query.pulsar.go b/api/cosmos/accounts/v1/query.pulsar.go index 73f12ef52015..8bcaa173d3e5 100644 --- a/api/cosmos/accounts/v1/query.pulsar.go +++ b/api/cosmos/accounts/v1/query.pulsar.go @@ -2100,7 +2100,7 @@ func (x *SchemaResponse_Handler) ProtoReflect() protoreflect.Message { } func (x *SchemaResponse_Handler) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2563,26 +2563,866 @@ func (x *fastReflection_SchemaResponse_Handler) ProtoMethods() *protoiface.Metho } var ( - md_AccountTypeRequest protoreflect.MessageDescriptor - fd_AccountTypeRequest_address protoreflect.FieldDescriptor + md_AccountTypeRequest protoreflect.MessageDescriptor + fd_AccountTypeRequest_address protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_accounts_v1_query_proto_init() + md_AccountTypeRequest = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountTypeRequest") + fd_AccountTypeRequest_address = md_AccountTypeRequest.Fields().ByName("address") +} + +var _ protoreflect.Message = (*fastReflection_AccountTypeRequest)(nil) + +type fastReflection_AccountTypeRequest AccountTypeRequest + +func (x *AccountTypeRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_AccountTypeRequest)(x) +} + +func (x *AccountTypeRequest) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_AccountTypeRequest_messageType fastReflection_AccountTypeRequest_messageType +var _ protoreflect.MessageType = fastReflection_AccountTypeRequest_messageType{} + +type fastReflection_AccountTypeRequest_messageType struct{} + +func (x fastReflection_AccountTypeRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_AccountTypeRequest)(nil) +} +func (x fastReflection_AccountTypeRequest_messageType) New() protoreflect.Message { + return new(fastReflection_AccountTypeRequest) +} +func (x fastReflection_AccountTypeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_AccountTypeRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_AccountTypeRequest) Descriptor() protoreflect.MessageDescriptor { + return md_AccountTypeRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_AccountTypeRequest) Type() protoreflect.MessageType { + return _fastReflection_AccountTypeRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_AccountTypeRequest) New() protoreflect.Message { + return new(fastReflection_AccountTypeRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_AccountTypeRequest) Interface() protoreflect.ProtoMessage { + return (*AccountTypeRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_AccountTypeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_AccountTypeRequest_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_AccountTypeRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + return x.Address != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + x.Address = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_AccountTypeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + x.Address = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + panic(fmt.Errorf("field address of message cosmos.accounts.v1.AccountTypeRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_AccountTypeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeRequest.address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_AccountTypeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountTypeRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_AccountTypeRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_AccountTypeRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*AccountTypeRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*AccountTypeRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*AccountTypeRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_AccountTypeResponse protoreflect.MessageDescriptor + fd_AccountTypeResponse_account_type protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_accounts_v1_query_proto_init() + md_AccountTypeResponse = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountTypeResponse") + fd_AccountTypeResponse_account_type = md_AccountTypeResponse.Fields().ByName("account_type") +} + +var _ protoreflect.Message = (*fastReflection_AccountTypeResponse)(nil) + +type fastReflection_AccountTypeResponse AccountTypeResponse + +func (x *AccountTypeResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_AccountTypeResponse)(x) +} + +func (x *AccountTypeResponse) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_AccountTypeResponse_messageType fastReflection_AccountTypeResponse_messageType +var _ protoreflect.MessageType = fastReflection_AccountTypeResponse_messageType{} + +type fastReflection_AccountTypeResponse_messageType struct{} + +func (x fastReflection_AccountTypeResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_AccountTypeResponse)(nil) +} +func (x fastReflection_AccountTypeResponse_messageType) New() protoreflect.Message { + return new(fastReflection_AccountTypeResponse) +} +func (x fastReflection_AccountTypeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_AccountTypeResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_AccountTypeResponse) Descriptor() protoreflect.MessageDescriptor { + return md_AccountTypeResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_AccountTypeResponse) Type() protoreflect.MessageType { + return _fastReflection_AccountTypeResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_AccountTypeResponse) New() protoreflect.Message { + return new(fastReflection_AccountTypeResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_AccountTypeResponse) Interface() protoreflect.ProtoMessage { + return (*AccountTypeResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_AccountTypeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.AccountType != "" { + value := protoreflect.ValueOfString(x.AccountType) + if !f(fd_AccountTypeResponse_account_type, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_AccountTypeResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + return x.AccountType != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + x.AccountType = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_AccountTypeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + value := x.AccountType + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + x.AccountType = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + panic(fmt.Errorf("field account_type of message cosmos.accounts.v1.AccountTypeResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_AccountTypeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.accounts.v1.AccountTypeResponse.account_type": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + } + panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_AccountTypeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountTypeResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_AccountTypeResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountTypeResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_AccountTypeResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*AccountTypeResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.AccountType) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*AccountTypeResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.AccountType) > 0 { + i -= len(x.AccountType) + copy(dAtA[i:], x.AccountType) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AccountType))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*AccountTypeResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountType", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.AccountType = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_AccountNumberRequest protoreflect.MessageDescriptor + fd_AccountNumberRequest_address protoreflect.FieldDescriptor ) func init() { file_cosmos_accounts_v1_query_proto_init() - md_AccountTypeRequest = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountTypeRequest") - fd_AccountTypeRequest_address = md_AccountTypeRequest.Fields().ByName("address") + md_AccountNumberRequest = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountNumberRequest") + fd_AccountNumberRequest_address = md_AccountNumberRequest.Fields().ByName("address") } -var _ protoreflect.Message = (*fastReflection_AccountTypeRequest)(nil) +var _ protoreflect.Message = (*fastReflection_AccountNumberRequest)(nil) -type fastReflection_AccountTypeRequest AccountTypeRequest +type fastReflection_AccountNumberRequest AccountNumberRequest -func (x *AccountTypeRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_AccountTypeRequest)(x) +func (x *AccountNumberRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_AccountNumberRequest)(x) } -func (x *AccountTypeRequest) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[4] +func (x *AccountNumberRequest) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2593,43 +3433,43 @@ func (x *AccountTypeRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_AccountTypeRequest_messageType fastReflection_AccountTypeRequest_messageType -var _ protoreflect.MessageType = fastReflection_AccountTypeRequest_messageType{} +var _fastReflection_AccountNumberRequest_messageType fastReflection_AccountNumberRequest_messageType +var _ protoreflect.MessageType = fastReflection_AccountNumberRequest_messageType{} -type fastReflection_AccountTypeRequest_messageType struct{} +type fastReflection_AccountNumberRequest_messageType struct{} -func (x fastReflection_AccountTypeRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_AccountTypeRequest)(nil) +func (x fastReflection_AccountNumberRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_AccountNumberRequest)(nil) } -func (x fastReflection_AccountTypeRequest_messageType) New() protoreflect.Message { - return new(fastReflection_AccountTypeRequest) +func (x fastReflection_AccountNumberRequest_messageType) New() protoreflect.Message { + return new(fastReflection_AccountNumberRequest) } -func (x fastReflection_AccountTypeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_AccountTypeRequest +func (x fastReflection_AccountNumberRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_AccountNumberRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_AccountTypeRequest) Descriptor() protoreflect.MessageDescriptor { - return md_AccountTypeRequest +func (x *fastReflection_AccountNumberRequest) Descriptor() protoreflect.MessageDescriptor { + return md_AccountNumberRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_AccountTypeRequest) Type() protoreflect.MessageType { - return _fastReflection_AccountTypeRequest_messageType +func (x *fastReflection_AccountNumberRequest) Type() protoreflect.MessageType { + return _fastReflection_AccountNumberRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_AccountTypeRequest) New() protoreflect.Message { - return new(fastReflection_AccountTypeRequest) +func (x *fastReflection_AccountNumberRequest) New() protoreflect.Message { + return new(fastReflection_AccountNumberRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_AccountTypeRequest) Interface() protoreflect.ProtoMessage { - return (*AccountTypeRequest)(x) +func (x *fastReflection_AccountNumberRequest) Interface() protoreflect.ProtoMessage { + return (*AccountNumberRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -2637,10 +3477,10 @@ func (x *fastReflection_AccountTypeRequest) Interface() protoreflect.ProtoMessag // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_AccountTypeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_AccountNumberRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if x.Address != "" { value := protoreflect.ValueOfString(x.Address) - if !f(fd_AccountTypeRequest_address, value) { + if !f(fd_AccountNumberRequest_address, value) { return } } @@ -2657,15 +3497,15 @@ func (x *fastReflection_AccountTypeRequest) Range(f func(protoreflect.FieldDescr // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_AccountTypeRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_AccountNumberRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": + case "cosmos.accounts.v1.AccountNumberRequest.address": return x.Address != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", fd.FullName())) } } @@ -2675,15 +3515,15 @@ func (x *fastReflection_AccountTypeRequest) Has(fd protoreflect.FieldDescriptor) // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_AccountNumberRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": + case "cosmos.accounts.v1.AccountNumberRequest.address": x.Address = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", fd.FullName())) } } @@ -2693,16 +3533,16 @@ func (x *fastReflection_AccountTypeRequest) Clear(fd protoreflect.FieldDescripto // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_AccountTypeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": + case "cosmos.accounts.v1.AccountNumberRequest.address": value := x.Address return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", descriptor.FullName())) } } @@ -2716,15 +3556,15 @@ func (x *fastReflection_AccountTypeRequest) Get(descriptor protoreflect.FieldDes // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_AccountNumberRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": + case "cosmos.accounts.v1.AccountNumberRequest.address": x.Address = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", fd.FullName())) } } @@ -2738,40 +3578,40 @@ func (x *fastReflection_AccountTypeRequest) Set(fd protoreflect.FieldDescriptor, // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": - panic(fmt.Errorf("field address of message cosmos.accounts.v1.AccountTypeRequest is not mutable")) + case "cosmos.accounts.v1.AccountNumberRequest.address": + panic(fmt.Errorf("field address of message cosmos.accounts.v1.AccountNumberRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_AccountTypeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeRequest.address": + case "cosmos.accounts.v1.AccountNumberRequest.address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberRequest")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_AccountTypeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_AccountNumberRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountTypeRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountNumberRequest", d.FullName())) } panic("unreachable") } @@ -2779,7 +3619,7 @@ func (x *fastReflection_AccountTypeRequest) WhichOneof(d protoreflect.OneofDescr // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_AccountTypeRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_AccountNumberRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -2790,7 +3630,7 @@ func (x *fastReflection_AccountTypeRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_AccountNumberRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -2802,7 +3642,7 @@ func (x *fastReflection_AccountTypeRequest) SetUnknown(fields protoreflect.RawFi // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_AccountTypeRequest) IsValid() bool { +func (x *fastReflection_AccountNumberRequest) IsValid() bool { return x != nil } @@ -2812,9 +3652,9 @@ func (x *fastReflection_AccountTypeRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_AccountNumberRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*AccountTypeRequest) + x := input.Message.Interface().(*AccountNumberRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2840,7 +3680,7 @@ func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*AccountTypeRequest) + x := input.Message.Interface().(*AccountNumberRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2877,7 +3717,7 @@ func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*AccountTypeRequest) + x := input.Message.Interface().(*AccountNumberRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2909,10 +3749,10 @@ func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountNumberRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountNumberRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -2983,26 +3823,26 @@ func (x *fastReflection_AccountTypeRequest) ProtoMethods() *protoiface.Methods { } var ( - md_AccountTypeResponse protoreflect.MessageDescriptor - fd_AccountTypeResponse_account_type protoreflect.FieldDescriptor + md_AccountNumberResponse protoreflect.MessageDescriptor + fd_AccountNumberResponse_number protoreflect.FieldDescriptor ) func init() { file_cosmos_accounts_v1_query_proto_init() - md_AccountTypeResponse = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountTypeResponse") - fd_AccountTypeResponse_account_type = md_AccountTypeResponse.Fields().ByName("account_type") + md_AccountNumberResponse = File_cosmos_accounts_v1_query_proto.Messages().ByName("AccountNumberResponse") + fd_AccountNumberResponse_number = md_AccountNumberResponse.Fields().ByName("number") } -var _ protoreflect.Message = (*fastReflection_AccountTypeResponse)(nil) +var _ protoreflect.Message = (*fastReflection_AccountNumberResponse)(nil) -type fastReflection_AccountTypeResponse AccountTypeResponse +type fastReflection_AccountNumberResponse AccountNumberResponse -func (x *AccountTypeResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_AccountTypeResponse)(x) +func (x *AccountNumberResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_AccountNumberResponse)(x) } -func (x *AccountTypeResponse) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[5] +func (x *AccountNumberResponse) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3013,43 +3853,43 @@ func (x *AccountTypeResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_AccountTypeResponse_messageType fastReflection_AccountTypeResponse_messageType -var _ protoreflect.MessageType = fastReflection_AccountTypeResponse_messageType{} +var _fastReflection_AccountNumberResponse_messageType fastReflection_AccountNumberResponse_messageType +var _ protoreflect.MessageType = fastReflection_AccountNumberResponse_messageType{} -type fastReflection_AccountTypeResponse_messageType struct{} +type fastReflection_AccountNumberResponse_messageType struct{} -func (x fastReflection_AccountTypeResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_AccountTypeResponse)(nil) +func (x fastReflection_AccountNumberResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_AccountNumberResponse)(nil) } -func (x fastReflection_AccountTypeResponse_messageType) New() protoreflect.Message { - return new(fastReflection_AccountTypeResponse) +func (x fastReflection_AccountNumberResponse_messageType) New() protoreflect.Message { + return new(fastReflection_AccountNumberResponse) } -func (x fastReflection_AccountTypeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_AccountTypeResponse +func (x fastReflection_AccountNumberResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_AccountNumberResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_AccountTypeResponse) Descriptor() protoreflect.MessageDescriptor { - return md_AccountTypeResponse +func (x *fastReflection_AccountNumberResponse) Descriptor() protoreflect.MessageDescriptor { + return md_AccountNumberResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_AccountTypeResponse) Type() protoreflect.MessageType { - return _fastReflection_AccountTypeResponse_messageType +func (x *fastReflection_AccountNumberResponse) Type() protoreflect.MessageType { + return _fastReflection_AccountNumberResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_AccountTypeResponse) New() protoreflect.Message { - return new(fastReflection_AccountTypeResponse) +func (x *fastReflection_AccountNumberResponse) New() protoreflect.Message { + return new(fastReflection_AccountNumberResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_AccountTypeResponse) Interface() protoreflect.ProtoMessage { - return (*AccountTypeResponse)(x) +func (x *fastReflection_AccountNumberResponse) Interface() protoreflect.ProtoMessage { + return (*AccountNumberResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -3057,10 +3897,10 @@ func (x *fastReflection_AccountTypeResponse) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_AccountTypeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.AccountType != "" { - value := protoreflect.ValueOfString(x.AccountType) - if !f(fd_AccountTypeResponse_account_type, value) { +func (x *fastReflection_AccountNumberResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Number != uint64(0) { + value := protoreflect.ValueOfUint64(x.Number) + if !f(fd_AccountNumberResponse_number, value) { return } } @@ -3077,15 +3917,15 @@ func (x *fastReflection_AccountTypeResponse) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_AccountTypeResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_AccountNumberResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - return x.AccountType != "" + case "cosmos.accounts.v1.AccountNumberResponse.number": + return x.Number != uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", fd.FullName())) } } @@ -3095,15 +3935,15 @@ func (x *fastReflection_AccountTypeResponse) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_AccountNumberResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - x.AccountType = "" + case "cosmos.accounts.v1.AccountNumberResponse.number": + x.Number = uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", fd.FullName())) } } @@ -3113,16 +3953,16 @@ func (x *fastReflection_AccountTypeResponse) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_AccountTypeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - value := x.AccountType - return protoreflect.ValueOfString(value) + case "cosmos.accounts.v1.AccountNumberResponse.number": + value := x.Number + return protoreflect.ValueOfUint64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", descriptor.FullName())) } } @@ -3136,15 +3976,15 @@ func (x *fastReflection_AccountTypeResponse) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_AccountNumberResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - x.AccountType = value.Interface().(string) + case "cosmos.accounts.v1.AccountNumberResponse.number": + x.Number = value.Uint() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", fd.FullName())) } } @@ -3158,40 +3998,40 @@ func (x *fastReflection_AccountTypeResponse) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - panic(fmt.Errorf("field account_type of message cosmos.accounts.v1.AccountTypeResponse is not mutable")) + case "cosmos.accounts.v1.AccountNumberResponse.number": + panic(fmt.Errorf("field number of message cosmos.accounts.v1.AccountNumberResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_AccountTypeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_AccountNumberResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.accounts.v1.AccountTypeResponse.account_type": - return protoreflect.ValueOfString("") + case "cosmos.accounts.v1.AccountNumberResponse.number": + return protoreflect.ValueOfUint64(uint64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountTypeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.accounts.v1.AccountNumberResponse")) } - panic(fmt.Errorf("message cosmos.accounts.v1.AccountTypeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message cosmos.accounts.v1.AccountNumberResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_AccountTypeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_AccountNumberResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountTypeResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in cosmos.accounts.v1.AccountNumberResponse", d.FullName())) } panic("unreachable") } @@ -3199,7 +4039,7 @@ func (x *fastReflection_AccountTypeResponse) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_AccountTypeResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_AccountNumberResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -3210,7 +4050,7 @@ func (x *fastReflection_AccountTypeResponse) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_AccountTypeResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_AccountNumberResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -3222,7 +4062,7 @@ func (x *fastReflection_AccountTypeResponse) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_AccountTypeResponse) IsValid() bool { +func (x *fastReflection_AccountNumberResponse) IsValid() bool { return x != nil } @@ -3232,9 +4072,9 @@ func (x *fastReflection_AccountTypeResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_AccountNumberResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*AccountTypeResponse) + x := input.Message.Interface().(*AccountNumberResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3246,9 +4086,8 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.AccountType) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) + if x.Number != 0 { + n += 1 + runtime.Sov(uint64(x.Number)) } if x.unknownFields != nil { n += len(x.unknownFields) @@ -3260,7 +4099,7 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*AccountTypeResponse) + x := input.Message.Interface().(*AccountNumberResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3279,12 +4118,10 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.AccountType) > 0 { - i -= len(x.AccountType) - copy(dAtA[i:], x.AccountType) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AccountType))) + if x.Number != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Number)) i-- - dAtA[i] = 0xa + dAtA[i] = 0x8 } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -3297,7 +4134,7 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*AccountTypeResponse) + x := input.Message.Interface().(*AccountNumberResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3329,17 +4166,17 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountNumberResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountTypeResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountNumberResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountType", wireType) + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Number", wireType) } - var stringLen uint64 + x.Number = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -3349,24 +4186,11 @@ func (x *fastReflection_AccountTypeResponse) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + x.Number |= uint64(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.AccountType = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -3424,7 +4248,7 @@ func (x *SimulateUserOperationRequest) ProtoReflect() protoreflect.Message { } func (x *SimulateUserOperationRequest) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3921,7 +4745,7 @@ func (x *SimulateUserOperationResponse) ProtoReflect() protoreflect.Message { } func (x *SimulateUserOperationResponse) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4598,6 +5422,81 @@ func (x *AccountTypeResponse) GetAccountType() string { return "" } +// AccountNumberRequest returns the account number given the address. +type AccountNumberRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // address is the address of the account we want to know the number of. + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` +} + +func (x *AccountNumberRequest) Reset() { + *x = AccountNumberRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AccountNumberRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AccountNumberRequest) ProtoMessage() {} + +// Deprecated: Use AccountNumberRequest.ProtoReflect.Descriptor instead. +func (*AccountNumberRequest) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{6} +} + +func (x *AccountNumberRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +// AccountNumberResponse is the response returned when querying the +// account number by address. +type AccountNumberResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // number is the account number of the provided address. + Number uint64 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"` +} + +func (x *AccountNumberResponse) Reset() { + *x = AccountNumberResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AccountNumberResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AccountNumberResponse) ProtoMessage() {} + +// Deprecated: Use AccountNumberResponse.ProtoReflect.Descriptor instead. +func (*AccountNumberResponse) Descriptor() ([]byte, []int) { + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{7} +} + +func (x *AccountNumberResponse) GetNumber() uint64 { + if x != nil { + return x.Number + } + return 0 +} + // SimulateUserOperationRequest is the query request used to simulate a // UserOperation. type SimulateUserOperationRequest struct { @@ -4615,7 +5514,7 @@ type SimulateUserOperationRequest struct { func (x *SimulateUserOperationRequest) Reset() { *x = SimulateUserOperationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[6] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4629,7 +5528,7 @@ func (*SimulateUserOperationRequest) ProtoMessage() {} // Deprecated: Use SimulateUserOperationRequest.ProtoReflect.Descriptor instead. func (*SimulateUserOperationRequest) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{6} + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{8} } func (x *SimulateUserOperationRequest) GetBundler() string { @@ -4660,7 +5559,7 @@ type SimulateUserOperationResponse struct { func (x *SimulateUserOperationResponse) Reset() { *x = SimulateUserOperationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[7] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4674,7 +5573,7 @@ func (*SimulateUserOperationResponse) ProtoMessage() {} // Deprecated: Use SimulateUserOperationResponse.ProtoReflect.Descriptor instead. func (*SimulateUserOperationResponse) Descriptor() ([]byte, []int) { - return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{7} + return file_cosmos_accounts_v1_query_proto_rawDescGZIP(), []int{9} } func (x *SimulateUserOperationResponse) GetUserOperationResponse() *UserOperationResponse { @@ -4701,7 +5600,7 @@ type SchemaResponse_Handler struct { func (x *SchemaResponse_Handler) Reset() { *x = SchemaResponse_Handler{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_accounts_v1_query_proto_msgTypes[8] + mi := &file_cosmos_accounts_v1_query_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4784,62 +5683,75 @@ var file_cosmos_accounts_v1_query_proto_rawDesc = []byte{ 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x22, - 0x82, 0x01, 0x0a, 0x1c, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, - 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x18, 0x0a, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x12, 0x48, 0x0a, 0x0e, 0x75, 0x73, - 0x65, 0x72, 0x5f, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0d, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x82, 0x01, 0x0a, 0x1d, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, - 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x61, 0x0a, 0x17, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x6f, - 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x73, 0x65, - 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x52, 0x15, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0xa1, 0x03, 0x0a, 0x05, 0x51, 0x75, - 0x65, 0x72, 0x79, 0x12, 0x63, 0x0a, 0x0c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, - 0x65, 0x72, 0x79, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, - 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x06, 0x53, 0x63, 0x68, 0x65, - 0x6d, 0x61, 0x12, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, - 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, - 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0b, 0x41, - 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, + 0x30, 0x0a, 0x14, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x22, 0x2f, 0x0a, 0x15, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, + 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x6e, 0x75, 0x6d, 0x62, + 0x65, 0x72, 0x22, 0x82, 0x01, 0x0a, 0x1c, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, + 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x12, 0x48, 0x0a, + 0x0e, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x4f, + 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0d, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, + 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x82, 0x01, 0x0a, 0x1d, 0x53, 0x69, 0x6d, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x61, 0x0a, 0x17, 0x75, 0x73, 0x65, + 0x72, 0x5f, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, - 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, - 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, - 0x15, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x30, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x6d, 0x75, + 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x15, 0x75, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0x89, 0x04, 0x0a, + 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x63, 0x0a, 0x0c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x06, 0x53, + 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, + 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x63, + 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x60, + 0x0a, 0x0b, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, + 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, + 0x12, 0x66, 0x0a, 0x0d, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, 0x65, + 0x72, 0x12, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, + 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, 0x15, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, - 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0xbe, 0x01, - 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, - 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, - 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x41, 0x58, 0xaa, 0x02, 0x12, 0x43, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56, - 0x31, 0xca, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, - 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x14, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x3a, 0x3a, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6e, 0x12, 0x30, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x55, + 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, + 0x65, 0x55, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0xbe, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, + 0x01, 0x5a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x76, + 0x31, 0xa2, 0x02, 0x03, 0x43, 0x41, 0x58, 0xaa, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x12, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c, 0x56, + 0x31, 0xe2, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x14, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -4854,7 +5766,7 @@ func file_cosmos_accounts_v1_query_proto_rawDescGZIP() []byte { return file_cosmos_accounts_v1_query_proto_rawDescData } -var file_cosmos_accounts_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 9) +var file_cosmos_accounts_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 11) var file_cosmos_accounts_v1_query_proto_goTypes = []interface{}{ (*AccountQueryRequest)(nil), // 0: cosmos.accounts.v1.AccountQueryRequest (*AccountQueryResponse)(nil), // 1: cosmos.accounts.v1.AccountQueryResponse @@ -4862,31 +5774,35 @@ var file_cosmos_accounts_v1_query_proto_goTypes = []interface{}{ (*SchemaResponse)(nil), // 3: cosmos.accounts.v1.SchemaResponse (*AccountTypeRequest)(nil), // 4: cosmos.accounts.v1.AccountTypeRequest (*AccountTypeResponse)(nil), // 5: cosmos.accounts.v1.AccountTypeResponse - (*SimulateUserOperationRequest)(nil), // 6: cosmos.accounts.v1.SimulateUserOperationRequest - (*SimulateUserOperationResponse)(nil), // 7: cosmos.accounts.v1.SimulateUserOperationResponse - (*SchemaResponse_Handler)(nil), // 8: cosmos.accounts.v1.SchemaResponse.Handler - (*anypb.Any)(nil), // 9: google.protobuf.Any - (*UserOperation)(nil), // 10: cosmos.accounts.v1.UserOperation - (*UserOperationResponse)(nil), // 11: cosmos.accounts.v1.UserOperationResponse + (*AccountNumberRequest)(nil), // 6: cosmos.accounts.v1.AccountNumberRequest + (*AccountNumberResponse)(nil), // 7: cosmos.accounts.v1.AccountNumberResponse + (*SimulateUserOperationRequest)(nil), // 8: cosmos.accounts.v1.SimulateUserOperationRequest + (*SimulateUserOperationResponse)(nil), // 9: cosmos.accounts.v1.SimulateUserOperationResponse + (*SchemaResponse_Handler)(nil), // 10: cosmos.accounts.v1.SchemaResponse.Handler + (*anypb.Any)(nil), // 11: google.protobuf.Any + (*UserOperation)(nil), // 12: cosmos.accounts.v1.UserOperation + (*UserOperationResponse)(nil), // 13: cosmos.accounts.v1.UserOperationResponse } var file_cosmos_accounts_v1_query_proto_depIdxs = []int32{ - 9, // 0: cosmos.accounts.v1.AccountQueryRequest.request:type_name -> google.protobuf.Any - 9, // 1: cosmos.accounts.v1.AccountQueryResponse.response:type_name -> google.protobuf.Any - 8, // 2: cosmos.accounts.v1.SchemaResponse.init_schema:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 8, // 3: cosmos.accounts.v1.SchemaResponse.execute_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 8, // 4: cosmos.accounts.v1.SchemaResponse.query_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler - 10, // 5: cosmos.accounts.v1.SimulateUserOperationRequest.user_operation:type_name -> cosmos.accounts.v1.UserOperation - 11, // 6: cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response:type_name -> cosmos.accounts.v1.UserOperationResponse + 11, // 0: cosmos.accounts.v1.AccountQueryRequest.request:type_name -> google.protobuf.Any + 11, // 1: cosmos.accounts.v1.AccountQueryResponse.response:type_name -> google.protobuf.Any + 10, // 2: cosmos.accounts.v1.SchemaResponse.init_schema:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 10, // 3: cosmos.accounts.v1.SchemaResponse.execute_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 10, // 4: cosmos.accounts.v1.SchemaResponse.query_handlers:type_name -> cosmos.accounts.v1.SchemaResponse.Handler + 12, // 5: cosmos.accounts.v1.SimulateUserOperationRequest.user_operation:type_name -> cosmos.accounts.v1.UserOperation + 13, // 6: cosmos.accounts.v1.SimulateUserOperationResponse.user_operation_response:type_name -> cosmos.accounts.v1.UserOperationResponse 0, // 7: cosmos.accounts.v1.Query.AccountQuery:input_type -> cosmos.accounts.v1.AccountQueryRequest 2, // 8: cosmos.accounts.v1.Query.Schema:input_type -> cosmos.accounts.v1.SchemaRequest 4, // 9: cosmos.accounts.v1.Query.AccountType:input_type -> cosmos.accounts.v1.AccountTypeRequest - 6, // 10: cosmos.accounts.v1.Query.SimulateUserOperation:input_type -> cosmos.accounts.v1.SimulateUserOperationRequest - 1, // 11: cosmos.accounts.v1.Query.AccountQuery:output_type -> cosmos.accounts.v1.AccountQueryResponse - 3, // 12: cosmos.accounts.v1.Query.Schema:output_type -> cosmos.accounts.v1.SchemaResponse - 5, // 13: cosmos.accounts.v1.Query.AccountType:output_type -> cosmos.accounts.v1.AccountTypeResponse - 7, // 14: cosmos.accounts.v1.Query.SimulateUserOperation:output_type -> cosmos.accounts.v1.SimulateUserOperationResponse - 11, // [11:15] is the sub-list for method output_type - 7, // [7:11] is the sub-list for method input_type + 6, // 10: cosmos.accounts.v1.Query.AccountNumber:input_type -> cosmos.accounts.v1.AccountNumberRequest + 8, // 11: cosmos.accounts.v1.Query.SimulateUserOperation:input_type -> cosmos.accounts.v1.SimulateUserOperationRequest + 1, // 12: cosmos.accounts.v1.Query.AccountQuery:output_type -> cosmos.accounts.v1.AccountQueryResponse + 3, // 13: cosmos.accounts.v1.Query.Schema:output_type -> cosmos.accounts.v1.SchemaResponse + 5, // 14: cosmos.accounts.v1.Query.AccountType:output_type -> cosmos.accounts.v1.AccountTypeResponse + 7, // 15: cosmos.accounts.v1.Query.AccountNumber:output_type -> cosmos.accounts.v1.AccountNumberResponse + 9, // 16: cosmos.accounts.v1.Query.SimulateUserOperation:output_type -> cosmos.accounts.v1.SimulateUserOperationResponse + 12, // [12:17] is the sub-list for method output_type + 7, // [7:12] is the sub-list for method input_type 7, // [7:7] is the sub-list for extension type_name 7, // [7:7] is the sub-list for extension extendee 0, // [0:7] is the sub-list for field type_name @@ -4972,7 +5888,7 @@ func file_cosmos_accounts_v1_query_proto_init() { } } file_cosmos_accounts_v1_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SimulateUserOperationRequest); i { + switch v := v.(*AccountNumberRequest); i { case 0: return &v.state case 1: @@ -4984,7 +5900,7 @@ func file_cosmos_accounts_v1_query_proto_init() { } } file_cosmos_accounts_v1_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SimulateUserOperationResponse); i { + switch v := v.(*AccountNumberResponse); i { case 0: return &v.state case 1: @@ -4996,6 +5912,30 @@ func file_cosmos_accounts_v1_query_proto_init() { } } file_cosmos_accounts_v1_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SimulateUserOperationRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_accounts_v1_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SimulateUserOperationResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_accounts_v1_query_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*SchemaResponse_Handler); i { case 0: return &v.state @@ -5014,7 +5954,7 @@ func file_cosmos_accounts_v1_query_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_accounts_v1_query_proto_rawDesc, NumEnums: 0, - NumMessages: 9, + NumMessages: 11, NumExtensions: 0, NumServices: 1, }, diff --git a/api/cosmos/accounts/v1/query_grpc.pb.go b/api/cosmos/accounts/v1/query_grpc.pb.go index 7e1b2d97e814..0f895be835dd 100644 --- a/api/cosmos/accounts/v1/query_grpc.pb.go +++ b/api/cosmos/accounts/v1/query_grpc.pb.go @@ -22,6 +22,7 @@ const ( Query_AccountQuery_FullMethodName = "/cosmos.accounts.v1.Query/AccountQuery" Query_Schema_FullMethodName = "/cosmos.accounts.v1.Query/Schema" Query_AccountType_FullMethodName = "/cosmos.accounts.v1.Query/AccountType" + Query_AccountNumber_FullMethodName = "/cosmos.accounts.v1.Query/AccountNumber" Query_SimulateUserOperation_FullMethodName = "/cosmos.accounts.v1.Query/SimulateUserOperation" ) @@ -35,6 +36,8 @@ type QueryClient interface { Schema(ctx context.Context, in *SchemaRequest, opts ...grpc.CallOption) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(ctx context.Context, in *AccountTypeRequest, opts ...grpc.CallOption) (*AccountTypeResponse, error) + // AccountNumber returns the account number given the account address. + AccountNumber(ctx context.Context, in *AccountNumberRequest, opts ...grpc.CallOption) (*AccountNumberResponse, error) // SimulateUserOperation simulates a user operation. SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) } @@ -74,6 +77,15 @@ func (c *queryClient) AccountType(ctx context.Context, in *AccountTypeRequest, o return out, nil } +func (c *queryClient) AccountNumber(ctx context.Context, in *AccountNumberRequest, opts ...grpc.CallOption) (*AccountNumberResponse, error) { + out := new(AccountNumberResponse) + err := c.cc.Invoke(ctx, Query_AccountNumber_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *queryClient) SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) { out := new(SimulateUserOperationResponse) err := c.cc.Invoke(ctx, Query_SimulateUserOperation_FullMethodName, in, out, opts...) @@ -93,6 +105,8 @@ type QueryServer interface { Schema(context.Context, *SchemaRequest) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) + // AccountNumber returns the account number given the account address. + AccountNumber(context.Context, *AccountNumberRequest) (*AccountNumberResponse, error) // SimulateUserOperation simulates a user operation. SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) mustEmbedUnimplementedQueryServer() @@ -111,6 +125,9 @@ func (UnimplementedQueryServer) Schema(context.Context, *SchemaRequest) (*Schema func (UnimplementedQueryServer) AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method AccountType not implemented") } +func (UnimplementedQueryServer) AccountNumber(context.Context, *AccountNumberRequest) (*AccountNumberResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AccountNumber not implemented") +} func (UnimplementedQueryServer) SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SimulateUserOperation not implemented") } @@ -181,6 +198,24 @@ func _Query_AccountType_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_AccountNumber_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(AccountNumberRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).AccountNumber(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_AccountNumber_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).AccountNumber(ctx, req.(*AccountNumberRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Query_SimulateUserOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(SimulateUserOperationRequest) if err := dec(in); err != nil { @@ -218,6 +253,10 @@ var Query_ServiceDesc = grpc.ServiceDesc{ MethodName: "AccountType", Handler: _Query_AccountType_Handler, }, + { + MethodName: "AccountNumber", + Handler: _Query_AccountNumber_Handler, + }, { MethodName: "SimulateUserOperation", Handler: _Query_SimulateUserOperation_Handler, diff --git a/proto/cosmos/accounts/v1/query.proto b/proto/cosmos/accounts/v1/query.proto index 7e779d130870..297b3a95b60f 100644 --- a/proto/cosmos/accounts/v1/query.proto +++ b/proto/cosmos/accounts/v1/query.proto @@ -15,6 +15,8 @@ service Query { rpc Schema(SchemaRequest) returns (SchemaResponse) {}; // AccountType returns the account type for an address. rpc AccountType(AccountTypeRequest) returns (AccountTypeResponse) {}; + // AccountNumber returns the account number given the account address. + rpc AccountNumber(AccountNumberRequest) returns (AccountNumberResponse) {}; // SimulateUserOperation simulates a user operation. rpc SimulateUserOperation(SimulateUserOperationRequest) returns (SimulateUserOperationResponse) {}; } @@ -70,6 +72,19 @@ message AccountTypeResponse { string account_type = 1; } +// AccountNumberRequest returns the account number given the address. +message AccountNumberRequest { + // address is the address of the account we want to know the number of. + string address = 1; +} + +// AccountNumberResponse is the response returned when querying the +// account number by address. +message AccountNumberResponse { + // number is the account number of the provided address. + uint64 number = 1; +} + // SimulateUserOperationRequest is the query request used to simulate a // UserOperation. message SimulateUserOperationRequest { diff --git a/x/accounts/query_server.go b/x/accounts/query_server.go index 8f0ea2e79b2e..a5b25782016b 100644 --- a/x/accounts/query_server.go +++ b/x/accounts/query_server.go @@ -72,7 +72,20 @@ func (q queryServer) AccountType(ctx context.Context, request *v1.AccountTypeReq }, nil } +func (q queryServer) AccountNumber(ctx context.Context, request *v1.AccountNumberRequest) (*v1.AccountNumberResponse, error) { + addr, err := q.k.addressCodec.StringToBytes(request.Address) + if err != nil { + return nil, err + } + number, err := q.k.AccountByNumber.Get(ctx, addr) + if err != nil { + return nil, err + } + return &v1.AccountNumberResponse{Number: number}, nil +} + const ( + // TODO(tip): evaluate if the following numbers should be parametrised over state, or over the node. SimulateAuthenticateGasLimit = 1_000_000 SimulateBundlerPaymentGasLimit = SimulateAuthenticateGasLimit ExecuteGasLimit = SimulateAuthenticateGasLimit diff --git a/x/accounts/query_server_test.go b/x/accounts/query_server_test.go index 6ff2ee30bcc3..bc4913458a28 100644 --- a/x/accounts/query_server_test.go +++ b/x/accounts/query_server_test.go @@ -23,7 +23,7 @@ func TestQueryServer(t *testing.T) { ms := NewMsgServer(k) qs := NewQueryServer(k) - // create + // create account initMsg, err := implementation.PackAny(&emptypb.Empty{}) require.NoError(t, err) @@ -34,19 +34,32 @@ func TestQueryServer(t *testing.T) { }) require.NoError(t, err) - // query - req := &wrapperspb.UInt64Value{Value: 10} - anypbReq, err := implementation.PackAny(req) - require.NoError(t, err) + t.Run("account query", func(t *testing.T) { + // query + req := &wrapperspb.UInt64Value{Value: 10} + anypbReq, err := implementation.PackAny(req) + require.NoError(t, err) + + queryResp, err := qs.AccountQuery(ctx, &v1.AccountQueryRequest{ + Target: initResp.AccountAddress, + Request: anypbReq, + }) + require.NoError(t, err) - queryResp, err := qs.AccountQuery(ctx, &v1.AccountQueryRequest{ - Target: initResp.AccountAddress, - Request: anypbReq, + resp, err := implementation.UnpackAnyRaw(queryResp.Response) + require.NoError(t, err) + require.Equal(t, "10", resp.(*types.StringValue).Value) }) - require.NoError(t, err) - resp, err := implementation.UnpackAnyRaw(queryResp.Response) - require.NoError(t, err) + t.Run("account number", func(t *testing.T) { + numResp, err := qs.AccountNumber(ctx, &v1.AccountNumberRequest{Address: initResp.AccountAddress}) + require.NoError(t, err) + require.Equal(t, 0, int(numResp.Number)) + }) - require.Equal(t, "10", resp.(*types.StringValue).Value) + t.Run("account type", func(t *testing.T) { + typ, err := qs.AccountType(ctx, &v1.AccountTypeRequest{Address: initResp.AccountAddress}) + require.NoError(t, err) + require.Equal(t, "test", typ.AccountType) + }) } diff --git a/x/accounts/v1/query.pb.go b/x/accounts/v1/query.pb.go index 70aa10ff7a4f..9e96f6e6545a 100644 --- a/x/accounts/v1/query.pb.go +++ b/x/accounts/v1/query.pb.go @@ -388,6 +388,99 @@ func (m *AccountTypeResponse) GetAccountType() string { return "" } +// AccountNumberRequest returns the account number given the address. +type AccountNumberRequest struct { + // address is the address of the account we want to know the number of. + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` +} + +func (m *AccountNumberRequest) Reset() { *m = AccountNumberRequest{} } +func (m *AccountNumberRequest) String() string { return proto.CompactTextString(m) } +func (*AccountNumberRequest) ProtoMessage() {} +func (*AccountNumberRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_16ad14c22e3080d2, []int{6} +} +func (m *AccountNumberRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *AccountNumberRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_AccountNumberRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *AccountNumberRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_AccountNumberRequest.Merge(m, src) +} +func (m *AccountNumberRequest) XXX_Size() int { + return m.Size() +} +func (m *AccountNumberRequest) XXX_DiscardUnknown() { + xxx_messageInfo_AccountNumberRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_AccountNumberRequest proto.InternalMessageInfo + +func (m *AccountNumberRequest) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + +// AccountNumberResponse is the response returned when querying the +// account number by address. +type AccountNumberResponse struct { + // number is the account number of the provided address. + Number uint64 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"` +} + +func (m *AccountNumberResponse) Reset() { *m = AccountNumberResponse{} } +func (m *AccountNumberResponse) String() string { return proto.CompactTextString(m) } +func (*AccountNumberResponse) ProtoMessage() {} +func (*AccountNumberResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_16ad14c22e3080d2, []int{7} +} +func (m *AccountNumberResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *AccountNumberResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_AccountNumberResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *AccountNumberResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_AccountNumberResponse.Merge(m, src) +} +func (m *AccountNumberResponse) XXX_Size() int { + return m.Size() +} +func (m *AccountNumberResponse) XXX_DiscardUnknown() { + xxx_messageInfo_AccountNumberResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_AccountNumberResponse proto.InternalMessageInfo + +func (m *AccountNumberResponse) GetNumber() uint64 { + if m != nil { + return m.Number + } + return 0 +} + // SimulateUserOperationRequest is the query request used to simulate a // UserOperation. type SimulateUserOperationRequest struct { @@ -402,7 +495,7 @@ func (m *SimulateUserOperationRequest) Reset() { *m = SimulateUserOperat func (m *SimulateUserOperationRequest) String() string { return proto.CompactTextString(m) } func (*SimulateUserOperationRequest) ProtoMessage() {} func (*SimulateUserOperationRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_16ad14c22e3080d2, []int{6} + return fileDescriptor_16ad14c22e3080d2, []int{8} } func (m *SimulateUserOperationRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -456,7 +549,7 @@ func (m *SimulateUserOperationResponse) Reset() { *m = SimulateUserOpera func (m *SimulateUserOperationResponse) String() string { return proto.CompactTextString(m) } func (*SimulateUserOperationResponse) ProtoMessage() {} func (*SimulateUserOperationResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_16ad14c22e3080d2, []int{7} + return fileDescriptor_16ad14c22e3080d2, []int{9} } func (m *SimulateUserOperationResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -500,6 +593,8 @@ func init() { proto.RegisterType((*SchemaResponse_Handler)(nil), "cosmos.accounts.v1.SchemaResponse.Handler") proto.RegisterType((*AccountTypeRequest)(nil), "cosmos.accounts.v1.AccountTypeRequest") proto.RegisterType((*AccountTypeResponse)(nil), "cosmos.accounts.v1.AccountTypeResponse") + proto.RegisterType((*AccountNumberRequest)(nil), "cosmos.accounts.v1.AccountNumberRequest") + proto.RegisterType((*AccountNumberResponse)(nil), "cosmos.accounts.v1.AccountNumberResponse") proto.RegisterType((*SimulateUserOperationRequest)(nil), "cosmos.accounts.v1.SimulateUserOperationRequest") proto.RegisterType((*SimulateUserOperationResponse)(nil), "cosmos.accounts.v1.SimulateUserOperationResponse") } @@ -507,43 +602,45 @@ func init() { func init() { proto.RegisterFile("cosmos/accounts/v1/query.proto", fileDescriptor_16ad14c22e3080d2) } var fileDescriptor_16ad14c22e3080d2 = []byte{ - // 563 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0xcd, 0x8e, 0x12, 0x41, - 0x10, 0x66, 0xd8, 0x08, 0x5a, 0x2c, 0x68, 0xda, 0x5d, 0xc5, 0x89, 0x4e, 0x60, 0x0e, 0x2e, 0x1a, - 0xd3, 0xb3, 0xa0, 0x07, 0x6f, 0x06, 0x4f, 0x24, 0x1e, 0x0c, 0xac, 0x7b, 0x31, 0x31, 0xd8, 0x0c, - 0x2d, 0x4b, 0x84, 0x69, 0xb6, 0x7f, 0x36, 0xcb, 0xc5, 0x83, 0x4f, 0xe0, 0x2b, 0xf8, 0x36, 0x7b, - 0xdc, 0xa3, 0x47, 0x03, 0x2f, 0x62, 0x98, 0xee, 0x86, 0x41, 0x67, 0x41, 0x6e, 0x53, 0x5d, 0x5f, - 0x7d, 0x5f, 0x75, 0xd5, 0xd7, 0x03, 0x5e, 0xc8, 0xc4, 0x98, 0x89, 0x80, 0x84, 0x21, 0x53, 0x91, - 0x14, 0xc1, 0x45, 0x3d, 0x38, 0x57, 0x94, 0x4f, 0xf1, 0x84, 0x33, 0xc9, 0x10, 0xd2, 0x79, 0x6c, - 0xf3, 0xf8, 0xa2, 0xee, 0x3e, 0x1a, 0x30, 0x36, 0x18, 0xd1, 0x20, 0x46, 0xf4, 0xd4, 0x97, 0x80, - 0x44, 0x06, 0xee, 0xbe, 0x48, 0xa1, 0x33, 0xdf, 0x5d, 0xd2, 0x13, 0x92, 0x93, 0x50, 0x0e, 0x59, - 0xa4, 0xd1, 0xfe, 0x27, 0xb8, 0xdf, 0xd4, 0xc9, 0xf6, 0x42, 0xb2, 0x43, 0xcf, 0x15, 0x15, 0x12, - 0x3d, 0x80, 0x9c, 0x24, 0x7c, 0x40, 0x65, 0xd9, 0xa9, 0x38, 0xb5, 0x3b, 0x1d, 0x13, 0x21, 0x0c, - 0x79, 0xae, 0x21, 0xe5, 0x6c, 0xc5, 0xa9, 0x15, 0x1a, 0x07, 0x58, 0x77, 0x82, 0x6d, 0x27, 0xb8, - 0x19, 0x4d, 0x3b, 0x16, 0xe4, 0xb7, 0xe0, 0x60, 0x9d, 0x5e, 0x4c, 0x58, 0x24, 0x28, 0x3a, 0x86, - 0xdb, 0xdc, 0x7c, 0xc7, 0x0a, 0x37, 0x11, 0x2d, 0x51, 0x7e, 0x03, 0x8a, 0x27, 0xe1, 0x19, 0x1d, - 0x13, 0xdb, 0x62, 0x15, 0xf6, 0xed, 0xb5, 0xe4, 0x74, 0x42, 0x4d, 0xa3, 0x05, 0x73, 0xf6, 0x61, - 0x3a, 0xa1, 0xfe, 0x55, 0x16, 0x4a, 0xb6, 0xc8, 0x08, 0xbf, 0x83, 0xc2, 0x30, 0x1a, 0xca, 0xae, - 0x88, 0x8f, 0x8d, 0xf6, 0x73, 0xfc, 0xef, 0x88, 0xf1, 0x7a, 0x21, 0x6e, 0x91, 0xa8, 0x3f, 0xa2, - 0xbc, 0x03, 0x8b, 0x72, 0x9d, 0x43, 0xa7, 0x70, 0x8f, 0x5e, 0xd2, 0x50, 0x49, 0xda, 0x3d, 0xd3, - 0x69, 0x51, 0xce, 0x56, 0xf6, 0x76, 0x64, 0xbc, 0x6b, 0x38, 0x4c, 0x2c, 0x50, 0x1b, 0x4a, 0xf1, - 0xfe, 0x57, 0xa4, 0x7b, 0x3b, 0x93, 0x16, 0x63, 0x06, 0x4b, 0xe9, 0xbe, 0x81, 0xbc, 0xf9, 0x46, - 0xe5, 0xd5, 0x0a, 0xf5, 0xc8, 0x6c, 0x88, 0xdc, 0xc4, 0x52, 0xb2, 0x71, 0x6a, 0x35, 0x7e, 0x0c, - 0xa8, 0xb9, 0x9a, 0xac, 0xdd, 0x41, 0x19, 0xf2, 0xa4, 0xdf, 0xe7, 0x54, 0x08, 0xcb, 0x65, 0x42, - 0xff, 0xf5, 0xd2, 0x57, 0x1a, 0x6f, 0xc6, 0xff, 0x1f, 0x4b, 0xfb, 0xee, 0xc0, 0xe3, 0x93, 0xe1, - 0x58, 0x8d, 0x88, 0xa4, 0xa7, 0x82, 0xf2, 0xf7, 0x13, 0xca, 0xc9, 0xc2, 0xb1, 0x09, 0xd1, 0x9e, - 0x8a, 0xef, 0x62, 0x45, 0x4d, 0x88, 0x5a, 0x50, 0x52, 0x82, 0xf2, 0x2e, 0xb3, 0x25, 0xc6, 0xa4, - 0xd5, 0xb4, 0xc1, 0xad, 0x73, 0x17, 0x55, 0x32, 0x5c, 0x34, 0xf1, 0xe4, 0x86, 0x26, 0xcc, 0x4d, - 0x08, 0x3c, 0x5c, 0xd7, 0xea, 0xfe, 0x65, 0xe8, 0x67, 0xdb, 0x45, 0x4d, 0x41, 0xe7, 0x50, 0xa5, - 0x1d, 0x37, 0x7e, 0xee, 0xc1, 0xad, 0xf8, 0xd9, 0xa0, 0x10, 0xf6, 0x93, 0xcf, 0x08, 0x1d, 0xa5, - 0x71, 0xa7, 0xbc, 0x63, 0xb7, 0xb6, 0x1d, 0x68, 0x16, 0x9c, 0x41, 0x6d, 0xc8, 0x19, 0x5f, 0x57, - 0x37, 0x19, 0x4d, 0x13, 0xfb, 0xdb, 0xbd, 0xe8, 0x67, 0xd0, 0x67, 0x28, 0x24, 0x5c, 0x80, 0x9e, - 0x6e, 0xe8, 0x26, 0x61, 0x2b, 0xf7, 0x68, 0x2b, 0x6e, 0xa9, 0xf0, 0x0d, 0x0e, 0x53, 0xf7, 0x84, - 0x8e, 0x53, 0x1b, 0xdc, 0xe0, 0x2b, 0xb7, 0xbe, 0x43, 0x85, 0xd5, 0x7f, 0xfb, 0xea, 0x6a, 0xe6, - 0x39, 0xd7, 0x33, 0xcf, 0xf9, 0x3d, 0xf3, 0x9c, 0x1f, 0x73, 0x2f, 0x73, 0x3d, 0xf7, 0x32, 0xbf, - 0xe6, 0x5e, 0xe6, 0xa3, 0xab, 0xd9, 0x44, 0xff, 0x2b, 0x1e, 0xb2, 0xe0, 0x32, 0xf9, 0x3f, 0xee, - 0xe5, 0xe2, 0x9f, 0xdc, 0xcb, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x77, 0xb6, 0x2c, 0xc3, 0xfb, - 0x05, 0x00, 0x00, + // 608 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x55, 0xcf, 0x6f, 0x12, 0x41, + 0x14, 0x66, 0x69, 0xa5, 0xfa, 0x28, 0xd5, 0x8c, 0xa5, 0xe2, 0x46, 0x37, 0xb0, 0x07, 0x4b, 0x8d, + 0x99, 0x05, 0xf4, 0xe0, 0xcd, 0xe0, 0x89, 0xc4, 0x44, 0xc3, 0xd6, 0x5e, 0x4c, 0x0c, 0x2e, 0xcb, + 0x94, 0x12, 0x61, 0x97, 0xce, 0xec, 0x34, 0xe5, 0xe2, 0xc1, 0x9b, 0x37, 0xff, 0xac, 0x1e, 0x7b, + 0xf4, 0x68, 0xe0, 0x1f, 0x31, 0xcc, 0x0f, 0xd8, 0xad, 0x5b, 0x28, 0xb7, 0x79, 0xf3, 0xde, 0xfb, + 0xbe, 0xb7, 0xef, 0x7d, 0x6f, 0x16, 0x2c, 0x3f, 0x64, 0xa3, 0x90, 0x39, 0x9e, 0xef, 0x87, 0x3c, + 0x88, 0x98, 0x73, 0x51, 0x77, 0xce, 0x39, 0xa1, 0x13, 0x3c, 0xa6, 0x61, 0x14, 0x22, 0x24, 0xfd, + 0x58, 0xfb, 0xf1, 0x45, 0xdd, 0x7c, 0xda, 0x0f, 0xc3, 0xfe, 0x90, 0x38, 0x22, 0xa2, 0xcb, 0x4f, + 0x1d, 0x2f, 0x50, 0xe1, 0xe6, 0xab, 0x14, 0x38, 0x75, 0xee, 0x78, 0x5d, 0x16, 0x51, 0xcf, 0x8f, + 0x06, 0x61, 0x20, 0xa3, 0xed, 0xaf, 0xf0, 0xb8, 0x29, 0x9d, 0xed, 0x39, 0xa5, 0x4b, 0xce, 0x39, + 0x61, 0x11, 0x3a, 0x80, 0x5c, 0xe4, 0xd1, 0x3e, 0x89, 0x4a, 0x46, 0xd9, 0xa8, 0x3e, 0x70, 0x95, + 0x85, 0x30, 0xec, 0x50, 0x19, 0x52, 0xca, 0x96, 0x8d, 0x6a, 0xbe, 0xb1, 0x8f, 0x65, 0x25, 0x58, + 0x57, 0x82, 0x9b, 0xc1, 0xc4, 0xd5, 0x41, 0x76, 0x0b, 0xf6, 0x93, 0xf0, 0x6c, 0x1c, 0x06, 0x8c, + 0xa0, 0x1a, 0xdc, 0xa7, 0xea, 0x2c, 0x18, 0x6e, 0x03, 0x5a, 0x44, 0xd9, 0x0d, 0x28, 0x1c, 0xfb, + 0x67, 0x64, 0xe4, 0xe9, 0x12, 0x2b, 0xb0, 0xab, 0x3f, 0x2b, 0x9a, 0x8c, 0x89, 0x2a, 0x34, 0xaf, + 0xee, 0x3e, 0x4f, 0xc6, 0xc4, 0xbe, 0xca, 0xc2, 0x9e, 0x4e, 0x52, 0xc4, 0x1f, 0x20, 0x3f, 0x08, + 0x06, 0x51, 0x87, 0x89, 0x6b, 0xc5, 0xfd, 0x12, 0xff, 0xdf, 0x62, 0x9c, 0x4c, 0xc4, 0x2d, 0x2f, + 0xe8, 0x0d, 0x09, 0x75, 0x61, 0x9e, 0x2e, 0x7d, 0xe8, 0x04, 0x1e, 0x91, 0x4b, 0xe2, 0xf3, 0x88, + 0x74, 0xce, 0xa4, 0x9b, 0x95, 0xb2, 0xe5, 0xad, 0x0d, 0x11, 0x1f, 0x2a, 0x0c, 0x65, 0x33, 0xd4, + 0x86, 0x3d, 0x31, 0xff, 0x25, 0xe8, 0xd6, 0xc6, 0xa0, 0x05, 0x81, 0xa0, 0x21, 0xcd, 0x77, 0xb0, + 0xa3, 0xce, 0xa8, 0xb4, 0x1c, 0xa1, 0x6c, 0x99, 0x36, 0x91, 0x19, 0x1b, 0x4a, 0x56, 0xb8, 0x96, + 0xed, 0xc7, 0x80, 0x9a, 0xcb, 0xce, 0xea, 0x19, 0x94, 0x60, 0xc7, 0xeb, 0xf5, 0x28, 0x61, 0x4c, + 0x63, 0x29, 0xd3, 0x7e, 0xbb, 0xd0, 0x95, 0x8c, 0x57, 0xed, 0xbf, 0xc3, 0xd0, 0x6a, 0x0b, 0xc9, + 0x7c, 0xe4, 0xa3, 0x2e, 0xa1, 0xeb, 0xb9, 0x1c, 0x28, 0xde, 0xc8, 0x50, 0x6c, 0x07, 0x90, 0x0b, + 0xc4, 0x8d, 0xc8, 0xd8, 0x76, 0x95, 0x65, 0xff, 0x34, 0xe0, 0xd9, 0xf1, 0x60, 0xc4, 0x87, 0x5e, + 0x44, 0x4e, 0x18, 0xa1, 0x9f, 0xc6, 0x84, 0x7a, 0xf3, 0xa5, 0x88, 0x71, 0x75, 0xb9, 0x68, 0x97, + 0xe6, 0x52, 0x26, 0x6a, 0xc1, 0x1e, 0x67, 0x84, 0x76, 0x42, 0x9d, 0xa2, 0xf6, 0xa0, 0x92, 0x36, + 0x9b, 0x24, 0x76, 0x81, 0xc7, 0xcd, 0x79, 0x11, 0xcf, 0x6f, 0x29, 0x42, 0x95, 0xef, 0xc1, 0x93, + 0x24, 0x57, 0xe7, 0xc6, 0xce, 0x1c, 0xad, 0x27, 0x55, 0x09, 0x6e, 0x91, 0xa7, 0x5d, 0x37, 0x7e, + 0x6d, 0xc3, 0x3d, 0xb1, 0x99, 0xc8, 0x87, 0xdd, 0xf8, 0xa6, 0xa2, 0xc3, 0x34, 0xec, 0x94, 0xa7, + 0xc2, 0xac, 0xae, 0x0f, 0x54, 0x1a, 0xca, 0xa0, 0x36, 0xe4, 0xd4, 0xea, 0x54, 0x56, 0x69, 0x59, + 0x02, 0xdb, 0xeb, 0xe5, 0x6e, 0x67, 0xd0, 0x37, 0xc8, 0xc7, 0x84, 0x86, 0x5e, 0xac, 0xa8, 0x26, + 0xa6, 0x5c, 0xf3, 0x70, 0x6d, 0xdc, 0x82, 0xe1, 0x14, 0x0a, 0x09, 0x79, 0xa1, 0x55, 0x5f, 0x9c, + 0xd0, 0xac, 0x79, 0x74, 0x87, 0xc8, 0x05, 0xcf, 0x0f, 0x28, 0xa6, 0xea, 0x01, 0xd5, 0x52, 0x1b, + 0xb1, 0x42, 0xbf, 0x66, 0x7d, 0x83, 0x0c, 0xcd, 0xff, 0xfe, 0xcd, 0xd5, 0xd4, 0x32, 0xae, 0xa7, + 0x96, 0xf1, 0x77, 0x6a, 0x19, 0xbf, 0x67, 0x56, 0xe6, 0x7a, 0x66, 0x65, 0xfe, 0xcc, 0xac, 0xcc, + 0x17, 0x53, 0xa2, 0xb1, 0xde, 0x77, 0x3c, 0x08, 0x9d, 0xcb, 0xf8, 0xaf, 0xa5, 0x9b, 0x13, 0xef, + 0xf5, 0xeb, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff, 0xcd, 0xc0, 0xe6, 0x63, 0xc6, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -564,6 +661,8 @@ type QueryClient interface { Schema(ctx context.Context, in *SchemaRequest, opts ...grpc.CallOption) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(ctx context.Context, in *AccountTypeRequest, opts ...grpc.CallOption) (*AccountTypeResponse, error) + // AccountNumber returns the account number given the account address. + AccountNumber(ctx context.Context, in *AccountNumberRequest, opts ...grpc.CallOption) (*AccountNumberResponse, error) // SimulateUserOperation simulates a user operation. SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) } @@ -603,6 +702,15 @@ func (c *queryClient) AccountType(ctx context.Context, in *AccountTypeRequest, o return out, nil } +func (c *queryClient) AccountNumber(ctx context.Context, in *AccountNumberRequest, opts ...grpc.CallOption) (*AccountNumberResponse, error) { + out := new(AccountNumberResponse) + err := c.cc.Invoke(ctx, "/cosmos.accounts.v1.Query/AccountNumber", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *queryClient) SimulateUserOperation(ctx context.Context, in *SimulateUserOperationRequest, opts ...grpc.CallOption) (*SimulateUserOperationResponse, error) { out := new(SimulateUserOperationResponse) err := c.cc.Invoke(ctx, "/cosmos.accounts.v1.Query/SimulateUserOperation", in, out, opts...) @@ -620,6 +728,8 @@ type QueryServer interface { Schema(context.Context, *SchemaRequest) (*SchemaResponse, error) // AccountType returns the account type for an address. AccountType(context.Context, *AccountTypeRequest) (*AccountTypeResponse, error) + // AccountNumber returns the account number given the account address. + AccountNumber(context.Context, *AccountNumberRequest) (*AccountNumberResponse, error) // SimulateUserOperation simulates a user operation. SimulateUserOperation(context.Context, *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) } @@ -637,6 +747,9 @@ func (*UnimplementedQueryServer) Schema(ctx context.Context, req *SchemaRequest) func (*UnimplementedQueryServer) AccountType(ctx context.Context, req *AccountTypeRequest) (*AccountTypeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method AccountType not implemented") } +func (*UnimplementedQueryServer) AccountNumber(ctx context.Context, req *AccountNumberRequest) (*AccountNumberResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AccountNumber not implemented") +} func (*UnimplementedQueryServer) SimulateUserOperation(ctx context.Context, req *SimulateUserOperationRequest) (*SimulateUserOperationResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SimulateUserOperation not implemented") } @@ -699,6 +812,24 @@ func _Query_AccountType_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_AccountNumber_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(AccountNumberRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).AccountNumber(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cosmos.accounts.v1.Query/AccountNumber", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).AccountNumber(ctx, req.(*AccountNumberRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Query_SimulateUserOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(SimulateUserOperationRequest) if err := dec(in); err != nil { @@ -733,6 +864,10 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "AccountType", Handler: _Query_AccountType_Handler, }, + { + MethodName: "AccountNumber", + Handler: _Query_AccountNumber_Handler, + }, { MethodName: "SimulateUserOperation", Handler: _Query_SimulateUserOperation_Handler, @@ -1009,6 +1144,64 @@ func (m *AccountTypeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *AccountNumberRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AccountNumberRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *AccountNumberRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintQuery(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *AccountNumberResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AccountNumberResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *AccountNumberResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Number != 0 { + i = encodeVarintQuery(dAtA, i, uint64(m.Number)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + func (m *SimulateUserOperationRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1208,6 +1401,31 @@ func (m *AccountTypeResponse) Size() (n int) { return n } +func (m *AccountNumberRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Address) + if l > 0 { + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + +func (m *AccountNumberResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Number != 0 { + n += 1 + sovQuery(uint64(m.Number)) + } + return n +} + func (m *SimulateUserOperationRequest) Size() (n int) { if m == nil { return 0 @@ -1962,6 +2180,157 @@ func (m *AccountTypeResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *AccountNumberRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AccountNumberRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AccountNumberRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *AccountNumberResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AccountNumberResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AccountNumberResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Number", wireType) + } + m.Number = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Number |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *SimulateUserOperationRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 From dee20ad62168df4c7c708d6e6011f0c041524b61 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Wed, 10 Jan 2024 08:11:28 +0100 Subject: [PATCH 12/28] chore: clean-up buf workspace (#18993) --- buf.work.yaml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/buf.work.yaml b/buf.work.yaml index d8175d0ef814..7a18eb0259c6 100644 --- a/buf.work.yaml +++ b/buf.work.yaml @@ -1,9 +1,3 @@ -# Generated by "buf config migrate-v1beta1". Edit as necessary, and -# remove this comment when you're finished. -# -# This workspace file points to the roots found in your -# previous "buf.yaml" configuration. version: v1 directories: - - proto - - orm/internal + - proto \ No newline at end of file From 8d71191a4876c81c3d73750c2f5cd07e2190cdde Mon Sep 17 00:00:00 2001 From: Halimao <1065621723@qq.com> Date: Wed, 10 Jan 2024 16:53:49 +0800 Subject: [PATCH 13/28] fix(x/protocolpool): fix potential panic and missing error handling (#18995) --- x/protocolpool/keeper/genesis.go | 4 ++-- x/protocolpool/keeper/keeper.go | 7 +++---- x/protocolpool/keeper/msg_server.go | 6 ++---- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/x/protocolpool/keeper/genesis.go b/x/protocolpool/keeper/genesis.go index bd29d4afce16..2af4fb7ad15b 100644 --- a/x/protocolpool/keeper/genesis.go +++ b/x/protocolpool/keeper/genesis.go @@ -28,11 +28,11 @@ func (k Keeper) InitGenesis(ctx context.Context, data *types.GenesisState) error } for _, budget := range data.Budget { // Validate StartTime - if budget.StartTime.IsZero() || budget.StartTime == nil { + if budget.StartTime == nil || budget.StartTime.IsZero() { budget.StartTime = ¤tTime } // ignore budget with start time < currentTime - if budget.StartTime != nil && budget.StartTime.Before(currentTime) { + if budget.StartTime.Before(currentTime) { continue } diff --git a/x/protocolpool/keeper/keeper.go b/x/protocolpool/keeper/keeper.go index abac09d30841..53c49a3a5b85 100644 --- a/x/protocolpool/keeper/keeper.go +++ b/x/protocolpool/keeper/keeper.go @@ -111,6 +111,7 @@ func (k Keeper) withdrawContinuousFund(ctx context.Context, recipient sdk.AccAdd if errors.Is(err, collections.ErrNotFound) { return sdk.Coin{}, fmt.Errorf("no continuous fund found for recipient: %s", recipient.String()) } + return sdk.Coin{}, fmt.Errorf("get continuous fund failed for recipient: %s", recipient.String()) } if cf.Expiry != nil && cf.Expiry.Before(sdkCtx.HeaderInfo().Time) { return sdk.Coin{}, fmt.Errorf("cannot withdraw continuous funds: continuous fund expired for recipient: %s", recipient.String()) @@ -412,10 +413,8 @@ func (k Keeper) validateContinuousFund(ctx context.Context, msg types.MsgCreateC // Validate expiry currentTime := sdk.UnwrapSDKContext(ctx).BlockTime() - if msg.Expiry != nil { - if msg.Expiry.Compare(currentTime) == -1 { - return fmt.Errorf("expiry time cannot be less than the current block time") - } + if msg.Expiry != nil && msg.Expiry.Compare(currentTime) == -1 { + return fmt.Errorf("expiry time cannot be less than the current block time") } return nil diff --git a/x/protocolpool/keeper/msg_server.go b/x/protocolpool/keeper/msg_server.go index 475378a6f35f..8f3965e3af3e 100644 --- a/x/protocolpool/keeper/msg_server.go +++ b/x/protocolpool/keeper/msg_server.go @@ -190,10 +190,8 @@ func (k MsgServer) CancelContinuousFund(ctx context.Context, msg *types.MsgCance // withdraw funds if any are allocated withdrawnFunds, err := k.withdrawRecipientFunds(ctx, recipient) - if err != nil { - if !errorspkg.Is(err, types.ErrNoRecipientFund) { - return nil, fmt.Errorf("error while withdrawing already allocated funds for recipient %s: %v", msg.RecipientAddress, err) - } + if err != nil && !errorspkg.Is(err, types.ErrNoRecipientFund) { + return nil, fmt.Errorf("error while withdrawing already allocated funds for recipient %s: %v", msg.RecipientAddress, err) } if err := k.ContinuousFund.Remove(ctx, recipient); err != nil { From 78ce70d4851c7971f24632be43198f5007a91690 Mon Sep 17 00:00:00 2001 From: gluax <16431709+gluax@users.noreply.github.com> Date: Wed, 10 Jan 2024 00:54:32 -0800 Subject: [PATCH 14/28] fix(testutil): fix FreeTCPAddr localhost usage (#18996) --- testutil/network/util.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testutil/network/util.go b/testutil/network/util.go index e78f82ce82fd..3b75cc3d6e06 100644 --- a/testutil/network/util.go +++ b/testutil/network/util.go @@ -223,7 +223,7 @@ func writeFile(name, dir string, contents []byte) error { // Get a free address for a test CometBFT server // protocol is either tcp, http, etc func FreeTCPAddr() (addr, port string, closeFn func() error, err error) { - l, err := net.Listen("tcp", "localhost:0") + l, err := net.Listen("tcp", "127.0.0.1:0") if err != nil { return "", "", nil, err } From 0b1299573095c852548760eeec2b14bb13c79111 Mon Sep 17 00:00:00 2001 From: Aleksandr Bezobchuk Date: Wed, 10 Jan 2024 03:55:24 -0500 Subject: [PATCH 15/28] fix(store/v2): Fix PebbleDB Iteration Edge Cases (#18948) --- store/storage/pebbledb/comparator.go | 13 +++++--- store/storage/pebbledb/iterator.go | 37 +++++++++++++++++------ store/storage/storage_test_suite.go | 44 ++++++++++++++++++++++++++++ 3 files changed, 81 insertions(+), 13 deletions(-) diff --git a/store/storage/pebbledb/comparator.go b/store/storage/pebbledb/comparator.go index b6f5aef24a66..08b360e6c079 100644 --- a/store/storage/pebbledb/comparator.go +++ b/store/storage/pebbledb/comparator.go @@ -137,20 +137,25 @@ func (f mvccKeyFormatter) Format(s fmt.State, verb rune) { // SplitMVCCKey accepts an MVCC key and returns the "user" key, the MVCC version, // and a boolean indicating if the provided key is an MVCC key. +// +// Note, internally, we must make a copy of the provided mvccKey argument, which +// typically comes from the Key() method as it's not safe. func SplitMVCCKey(mvccKey []byte) (key, version []byte, ok bool) { if len(mvccKey) == 0 { return nil, nil, false } - n := len(mvccKey) - 1 - tsLen := int(mvccKey[n]) + mvccKeyCopy := bytes.Clone(mvccKey) + + n := len(mvccKeyCopy) - 1 + tsLen := int(mvccKeyCopy[n]) if n < tsLen { return nil, nil, false } - key = mvccKey[:n-tsLen] + key = mvccKeyCopy[:n-tsLen] if tsLen > 0 { - version = mvccKey[n-tsLen+1 : len(mvccKey)-1] + version = mvccKeyCopy[n-tsLen+1 : len(mvccKeyCopy)-1] } return key, version, true diff --git a/store/storage/pebbledb/iterator.go b/store/storage/pebbledb/iterator.go index 10b03bbe1143..abb746863d88 100644 --- a/store/storage/pebbledb/iterator.go +++ b/store/storage/pebbledb/iterator.go @@ -113,15 +113,15 @@ func (itr *iterator) Value() []byte { } func (itr *iterator) Next() { + currKey, _, ok := SplitMVCCKey(itr.source.Key()) + if !ok { + // XXX: This should not happen as that would indicate we have a malformed + // MVCC key. + panic(fmt.Sprintf("invalid PebbleDB MVCC key: %s", itr.source.Key())) + } + var next bool if itr.reverse { - currKey, _, ok := SplitMVCCKey(itr.source.Key()) - if !ok { - // XXX: This should not happen as that would indicate we have a malformed - // MVCC key. - panic(fmt.Sprintf("invalid PebbleDB MVCC key: %s", itr.source.Key())) - } - // Since PebbleDB has no PrevPrefix API, we must manually seek to the next // key that is lexicographically less than the current key. next = itr.source.SeekLT(MVCCEncode(currKey, 0)) @@ -132,7 +132,7 @@ func (itr *iterator) Next() { // First move the iterator to the next prefix, which may not correspond to the // desired version for that key, e.g. if the key was written at a later version, - // so we seek back to the latest desired version, s.t. the version is <= itr.version. + // so we seek back to the latest desired version, s.t. the version <= itr.version. if next { nextKey, _, ok := SplitMVCCKey(itr.source.Key()) if !ok { @@ -147,10 +147,29 @@ func (itr *iterator) Next() { return } - // Move the iterator to the closest version to the desired version, so we + // Move the iterator to the closest version of the desired version, so we // append the current iterator key to the prefix and seek to that key. itr.valid = itr.source.SeekLT(MVCCEncode(nextKey, itr.version+1)) + tmpKey, _, ok := SplitMVCCKey(itr.source.Key()) + if !ok { + // XXX: This should not happen as that would indicate we have a malformed + // MVCC key. + itr.valid = false + return + } + + // There exists cases where the SeekLT() call moved us back to the same key + // we started at, so we must move to next key, i.e. two keys forward. + if bytes.Equal(tmpKey, currKey) { + if itr.source.NextPrefix() { + itr.Next() + } else { + itr.valid = false + return + } + } + // The cursor might now be pointing at a key/value pair that is tombstoned. // If so, we must move the cursor. if itr.valid && itr.cursorTombstoned() { diff --git a/store/storage/storage_test_suite.go b/store/storage/storage_test_suite.go index 303d77bd13c2..b43ed408958a 100644 --- a/store/storage/storage_test_suite.go +++ b/store/storage/storage_test_suite.go @@ -391,10 +391,54 @@ func (s *StorageTestSuite) TestDatabase_IteratorMultiVersion() { i = (i + 1) % 10 count++ } + s.Require().Equal(10, count) s.Require().NoError(itr.Error()) } +func (s *StorageTestSuite) TestDatabaseIterator_SkipVersion() { + db, err := s.NewDB(s.T().TempDir()) + s.Require().NoError(err) + + defer db.Close() + + cs := store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: { + {Key: []byte("keyC"), Value: []byte("value003")}, + }}) + s.Require().NoError(db.ApplyChangeset(58827506, cs)) + + cs = store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: { + {Key: []byte("keyE"), Value: []byte("value000")}, + }}) + s.Require().NoError(db.ApplyChangeset(58827506, cs)) + + cs = store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: { + {Key: []byte("keyF"), Value: []byte("value000")}, + }}) + s.Require().NoError(db.ApplyChangeset(58827506, cs)) + + cs = store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: { + {Key: []byte("keyC"), Value: []byte("value004")}, + }}) + s.Require().NoError(db.ApplyChangeset(58833605, cs)) + + cs = store.NewChangesetWithPairs(map[string]store.KVPairs{storeKey1: { + {Key: []byte("keyD"), Value: []byte("value006")}, + }}) + s.Require().NoError(db.ApplyChangeset(58833606, cs)) + + itr, err := db.Iterator(storeKey1, 58831525, []byte("key"), nil) + s.Require().NoError(err) + defer itr.Close() + + count := make(map[string]struct{}) + for ; itr.Valid(); itr.Next() { + count[string(itr.Key())] = struct{}{} + } + + s.Require().Equal(3, len(count)) +} + func (s *StorageTestSuite) TestDatabase_IteratorNoDomain() { db, err := s.NewDB(s.T().TempDir()) s.Require().NoError(err) From dee9eda5e40131ce855ddc268b12d230c67bbcb4 Mon Sep 17 00:00:00 2001 From: gsai967 <153279976+gsai967@users.noreply.github.com> Date: Wed, 10 Jan 2024 20:01:18 +0530 Subject: [PATCH 16/28] feat(x/bank): adding DenomOwnersByQuery for denom owners for token (#18956) Co-authored-by: Sai Kumar --- CHANGELOG.md | 2 +- api/cosmos/bank/v1beta1/query.pulsar.go | 1675 +++++++++++++++++++--- api/cosmos/bank/v1beta1/query_grpc.pb.go | 53 +- client/docs/swagger-ui/swagger.yaml | 645 ++++++++- proto/cosmos/bank/v1beta1/query.proto | 36 +- proto/cosmos/protocolpool/v1/tx.proto | 1 - x/bank/CHANGELOG.md | 4 + x/bank/keeper/grpc_query.go | 39 +- x/bank/keeper/grpc_query_test.go | 108 ++ x/bank/types/query.pb.go | 705 +++++++-- x/bank/types/query.pb.gw.go | 83 ++ 11 files changed, 2985 insertions(+), 366 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f014579d9206..d8fda2655afc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,7 +52,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (runtime) [#18475](https://github.com/cosmos/cosmos-sdk/pull/18475) Adds an implementation for core.branch.Service. * (baseapp) [#18499](https://github.com/cosmos/cosmos-sdk/pull/18499) Add `MsgRouter` response type from message name function. * (types) [#18768](https://github.com/cosmos/cosmos-sdk/pull/18768) Add MustValAddressFromBech32 function. - + ### Improvements * (client/keys) [#18950](https://github.com/cosmos/cosmos-sdk/pull/18950) Improve ` keys add`, ` keys import` and ` keys rename` by checking name validation. diff --git a/api/cosmos/bank/v1beta1/query.pulsar.go b/api/cosmos/bank/v1beta1/query.pulsar.go index 28a54ee63ac2..ff7c91b7aff5 100644 --- a/api/cosmos/bank/v1beta1/query.pulsar.go +++ b/api/cosmos/bank/v1beta1/query.pulsar.go @@ -10998,6 +10998,1078 @@ func (x *fastReflection_QueryDenomOwnersResponse) ProtoMethods() *protoiface.Met } } +var ( + md_QueryDenomOwnersByQueryRequest protoreflect.MessageDescriptor + fd_QueryDenomOwnersByQueryRequest_denom protoreflect.FieldDescriptor + fd_QueryDenomOwnersByQueryRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_bank_v1beta1_query_proto_init() + md_QueryDenomOwnersByQueryRequest = File_cosmos_bank_v1beta1_query_proto.Messages().ByName("QueryDenomOwnersByQueryRequest") + fd_QueryDenomOwnersByQueryRequest_denom = md_QueryDenomOwnersByQueryRequest.Fields().ByName("denom") + fd_QueryDenomOwnersByQueryRequest_pagination = md_QueryDenomOwnersByQueryRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDenomOwnersByQueryRequest)(nil) + +type fastReflection_QueryDenomOwnersByQueryRequest QueryDenomOwnersByQueryRequest + +func (x *QueryDenomOwnersByQueryRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDenomOwnersByQueryRequest)(x) +} + +func (x *QueryDenomOwnersByQueryRequest) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[23] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDenomOwnersByQueryRequest_messageType fastReflection_QueryDenomOwnersByQueryRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryDenomOwnersByQueryRequest_messageType{} + +type fastReflection_QueryDenomOwnersByQueryRequest_messageType struct{} + +func (x fastReflection_QueryDenomOwnersByQueryRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDenomOwnersByQueryRequest)(nil) +} +func (x fastReflection_QueryDenomOwnersByQueryRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDenomOwnersByQueryRequest) +} +func (x fastReflection_QueryDenomOwnersByQueryRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDenomOwnersByQueryRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDenomOwnersByQueryRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryDenomOwnersByQueryRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) New() protoreflect.Message { + return new(fastReflection_QueryDenomOwnersByQueryRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Interface() protoreflect.ProtoMessage { + return (*QueryDenomOwnersByQueryRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Denom != "" { + value := protoreflect.ValueOfString(x.Denom) + if !f(fd_QueryDenomOwnersByQueryRequest_denom, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDenomOwnersByQueryRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + return x.Denom != "" + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + x.Denom = "" + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + value := x.Denom + return protoreflect.ValueOfString(value) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + x.Denom = value.Interface().(string) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta11.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta11.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + panic(fmt.Errorf("field denom of message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.denom": + return protoreflect.ValueOfString("") + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination": + m := new(v1beta11.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDenomOwnersByQueryRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDenomOwnersByQueryRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Denom) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDenomOwnersByQueryRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Denom) > 0 { + i -= len(x.Denom) + copy(dAtA[i:], x.Denom) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Denom))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDenomOwnersByQueryRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDenomOwnersByQueryRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDenomOwnersByQueryRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta11.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryDenomOwnersByQueryResponse_1_list)(nil) + +type _QueryDenomOwnersByQueryResponse_1_list struct { + list *[]*DenomOwner +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*DenomOwner) + (*x.list)[i] = concreteValue +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*DenomOwner) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) AppendMutable() protoreflect.Value { + v := new(DenomOwner) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) NewElement() protoreflect.Value { + v := new(DenomOwner) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDenomOwnersByQueryResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryDenomOwnersByQueryResponse protoreflect.MessageDescriptor + fd_QueryDenomOwnersByQueryResponse_denom_owners protoreflect.FieldDescriptor + fd_QueryDenomOwnersByQueryResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_cosmos_bank_v1beta1_query_proto_init() + md_QueryDenomOwnersByQueryResponse = File_cosmos_bank_v1beta1_query_proto.Messages().ByName("QueryDenomOwnersByQueryResponse") + fd_QueryDenomOwnersByQueryResponse_denom_owners = md_QueryDenomOwnersByQueryResponse.Fields().ByName("denom_owners") + fd_QueryDenomOwnersByQueryResponse_pagination = md_QueryDenomOwnersByQueryResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDenomOwnersByQueryResponse)(nil) + +type fastReflection_QueryDenomOwnersByQueryResponse QueryDenomOwnersByQueryResponse + +func (x *QueryDenomOwnersByQueryResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDenomOwnersByQueryResponse)(x) +} + +func (x *QueryDenomOwnersByQueryResponse) slowProtoReflect() protoreflect.Message { + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[24] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDenomOwnersByQueryResponse_messageType fastReflection_QueryDenomOwnersByQueryResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryDenomOwnersByQueryResponse_messageType{} + +type fastReflection_QueryDenomOwnersByQueryResponse_messageType struct{} + +func (x fastReflection_QueryDenomOwnersByQueryResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDenomOwnersByQueryResponse)(nil) +} +func (x fastReflection_QueryDenomOwnersByQueryResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDenomOwnersByQueryResponse) +} +func (x fastReflection_QueryDenomOwnersByQueryResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDenomOwnersByQueryResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDenomOwnersByQueryResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryDenomOwnersByQueryResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) New() protoreflect.Message { + return new(fastReflection_QueryDenomOwnersByQueryResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Interface() protoreflect.ProtoMessage { + return (*QueryDenomOwnersByQueryResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.DenomOwners) != 0 { + value := protoreflect.ValueOfList(&_QueryDenomOwnersByQueryResponse_1_list{list: &x.DenomOwners}) + if !f(fd_QueryDenomOwnersByQueryResponse_denom_owners, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDenomOwnersByQueryResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + return len(x.DenomOwners) != 0 + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + x.DenomOwners = nil + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + if len(x.DenomOwners) == 0 { + return protoreflect.ValueOfList(&_QueryDenomOwnersByQueryResponse_1_list{}) + } + listValue := &_QueryDenomOwnersByQueryResponse_1_list{list: &x.DenomOwners} + return protoreflect.ValueOfList(listValue) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + lv := value.List() + clv := lv.(*_QueryDenomOwnersByQueryResponse_1_list) + x.DenomOwners = *clv.list + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta11.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + if x.DenomOwners == nil { + x.DenomOwners = []*DenomOwner{} + } + value := &_QueryDenomOwnersByQueryResponse_1_list{list: &x.DenomOwners} + return protoreflect.ValueOfList(value) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta11.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners": + list := []*DenomOwner{} + return protoreflect.ValueOfList(&_QueryDenomOwnersByQueryResponse_1_list{list: &list}) + case "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination": + m := new(v1beta11.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse")) + } + panic(fmt.Errorf("message cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDenomOwnersByQueryResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDenomOwnersByQueryResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.DenomOwners) > 0 { + for _, e := range x.DenomOwners { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDenomOwnersByQueryResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.DenomOwners) > 0 { + for iNdEx := len(x.DenomOwners) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.DenomOwners[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDenomOwnersByQueryResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDenomOwnersByQueryResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDenomOwnersByQueryResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DenomOwners", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DenomOwners = append(x.DenomOwners, &DenomOwner{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.DenomOwners[len(x.DenomOwners)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta11.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + var _ protoreflect.List = (*_QuerySendEnabledRequest_1_list)(nil) type _QuerySendEnabledRequest_1_list struct { @@ -11066,7 +12138,7 @@ func (x *QuerySendEnabledRequest) ProtoReflect() protoreflect.Message { } func (x *QuerySendEnabledRequest) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[23] + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11632,7 +12704,7 @@ func (x *QuerySendEnabledResponse) ProtoReflect() protoreflect.Message { } func (x *QuerySendEnabledResponse) slowProtoReflect() protoreflect.Message { - mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[24] + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -13128,6 +14200,103 @@ func (x *QueryDenomOwnersResponse) GetPagination() *v1beta11.PageResponse { return nil } +// QueryDenomOwnersByQueryRequest defines the request type for the DenomOwnersByQuery RPC query, +// which queries for a paginated set of all account holders of a particular +// denomination. +// +// Since: cosmos-sdk 0.50.3 +type QueryDenomOwnersByQueryRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // denom defines the coin denomination to query all account holders for. + Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"` + // pagination defines an optional pagination for the request. + Pagination *v1beta11.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDenomOwnersByQueryRequest) Reset() { + *x = QueryDenomOwnersByQueryRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDenomOwnersByQueryRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDenomOwnersByQueryRequest) ProtoMessage() {} + +// Deprecated: Use QueryDenomOwnersByQueryRequest.ProtoReflect.Descriptor instead. +func (*QueryDenomOwnersByQueryRequest) Descriptor() ([]byte, []int) { + return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{23} +} + +func (x *QueryDenomOwnersByQueryRequest) GetDenom() string { + if x != nil { + return x.Denom + } + return "" +} + +func (x *QueryDenomOwnersByQueryRequest) GetPagination() *v1beta11.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryDenomOwnersByQueryResponse defines the RPC response of a DenomOwnersByQuery RPC query. +// +// Since: cosmos-sdk 0.50.3 +type QueryDenomOwnersByQueryResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + DenomOwners []*DenomOwner `protobuf:"bytes,1,rep,name=denom_owners,json=denomOwners,proto3" json:"denom_owners,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta11.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDenomOwnersByQueryResponse) Reset() { + *x = QueryDenomOwnersByQueryResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDenomOwnersByQueryResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDenomOwnersByQueryResponse) ProtoMessage() {} + +// Deprecated: Use QueryDenomOwnersByQueryResponse.ProtoReflect.Descriptor instead. +func (*QueryDenomOwnersByQueryResponse) Descriptor() ([]byte, []int) { + return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{24} +} + +func (x *QueryDenomOwnersByQueryResponse) GetDenomOwners() []*DenomOwner { + if x != nil { + return x.DenomOwners + } + return nil +} + +func (x *QueryDenomOwnersByQueryResponse) GetPagination() *v1beta11.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + // QuerySendEnabledRequest defines the RPC request for looking up SendEnabled entries. // // Since: cosmos-sdk 0.47 @@ -13146,7 +14315,7 @@ type QuerySendEnabledRequest struct { func (x *QuerySendEnabledRequest) Reset() { *x = QuerySendEnabledRequest{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[23] + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -13160,7 +14329,7 @@ func (*QuerySendEnabledRequest) ProtoMessage() {} // Deprecated: Use QuerySendEnabledRequest.ProtoReflect.Descriptor instead. func (*QuerySendEnabledRequest) Descriptor() ([]byte, []int) { - return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{23} + return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{25} } func (x *QuerySendEnabledRequest) GetDenoms() []string { @@ -13194,7 +14363,7 @@ type QuerySendEnabledResponse struct { func (x *QuerySendEnabledResponse) Reset() { *x = QuerySendEnabledResponse{} if protoimpl.UnsafeEnabled { - mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[24] + mi := &file_cosmos_bank_v1beta1_query_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -13208,7 +14377,7 @@ func (*QuerySendEnabledResponse) ProtoMessage() {} // Deprecated: Use QuerySendEnabledResponse.ProtoReflect.Descriptor instead. func (*QuerySendEnabledResponse) Descriptor() ([]byte, []int) { - return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{24} + return file_cosmos_bank_v1beta1_query_proto_rawDescGZIP(), []int{26} } func (x *QuerySendEnabledResponse) GetSendEnabled() []*SendEnabled { @@ -13423,167 +14592,198 @@ var file_cosmos_bank_v1beta1_query_proto_rawDesc = []byte{ 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x79, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, - 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x16, 0x0a, 0x06, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, - 0x52, 0x06, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, - 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x63, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, - 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0xa8, 0x01, 0x0a, 0x18, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, - 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x43, 0x0a, - 0x0c, 0x73, 0x65, 0x6e, 0x64, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, - 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, - 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x0b, 0x73, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, - 0x65, 0x64, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x63, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, - 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, - 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, 0x8f, 0x10, 0x0a, 0x05, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x9d, 0x01, 0x0a, 0x07, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, - 0x65, 0x12, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, - 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, - 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, - 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3d, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x32, 0x12, 0x30, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, - 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, - 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x2f, 0x62, 0x79, 0x5f, - 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0xa0, 0x01, 0x0a, 0x0b, 0x41, 0x6c, 0x6c, 0x42, 0x61, 0x6c, - 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, - 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x41, 0x6c, 0x6c, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, - 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, - 0x6c, 0x6c, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x34, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x29, 0x12, - 0x27, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x7b, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xbc, 0x01, 0x0a, 0x11, 0x53, 0x70, 0x65, - 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x32, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, - 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x61, - 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x33, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, - 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x70, - 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3e, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x33, 0x12, 0x31, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, - 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x73, 0x70, 0x65, 0x6e, 0x64, - 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x7b, 0x61, - 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xd7, 0x01, 0x0a, 0x17, 0x53, 0x70, 0x65, 0x6e, - 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x79, 0x44, 0x65, - 0x6e, 0x6f, 0x6d, 0x12, 0x38, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x7e, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, + 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x65, 0x6e, 0x6f, 0x6d, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0x46, 0x0a, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, + 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, + 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xae, 0x01, 0x0a, 0x1f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, + 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x0c, 0x64, 0x65, 0x6e, + 0x6f, 0x6d, 0x5f, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, + 0x52, 0x0b, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x12, 0x47, 0x0a, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, + 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, + 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x79, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, + 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x09, 0x52, 0x06, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x63, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, + 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0xa8, 0x01, 0x0a, 0x18, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, 0x45, + 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x43, + 0x0a, 0x0c, 0x73, 0x65, 0x6e, 0x64, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, + 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x45, + 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x0b, 0x73, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, + 0x6c, 0x65, 0x64, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x63, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, 0xca, 0x11, 0x0a, + 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x9d, 0x01, 0x0a, 0x07, 0x42, 0x61, 0x6c, 0x61, 0x6e, + 0x63, 0x65, 0x12, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, + 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3d, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x32, 0x12, 0x30, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, + 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, + 0x63, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x2f, 0x62, 0x79, + 0x5f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0xa0, 0x01, 0x0a, 0x0b, 0x41, 0x6c, 0x6c, 0x42, 0x61, + 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x41, 0x6c, 0x6c, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, + 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x41, 0x6c, 0x6c, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x34, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x29, + 0x12, 0x27, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, + 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xbc, 0x01, 0x0a, 0x11, 0x53, 0x70, + 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, + 0x32, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x70, 0x65, 0x6e, 0x64, + 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x33, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, - 0x70, 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, - 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x39, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, - 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x61, 0x62, - 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x47, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x3c, 0x12, 0x3a, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, + 0x70, 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3e, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x33, 0x12, 0x31, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x7b, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x2f, 0x62, 0x79, 0x5f, 0x64, 0x65, 0x6e, 0x6f, - 0x6d, 0x12, 0x94, 0x01, 0x0a, 0x0b, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x75, 0x70, 0x70, 0x6c, - 0x79, 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, - 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x6f, 0x74, - 0x61, 0x6c, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x6f, 0x74, 0x61, 0x6c, - 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, + 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xd7, 0x01, 0x0a, 0x17, 0x53, 0x70, 0x65, + 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x79, 0x44, + 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0x38, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, + 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x53, 0x70, 0x65, 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, + 0x42, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x39, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x70, 0x65, 0x6e, 0x64, 0x61, + 0x62, 0x6c, 0x65, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x79, 0x44, 0x65, 0x6e, 0x6f, + 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x47, 0x88, 0xe7, 0xb0, 0x2a, 0x01, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3c, 0x12, 0x3a, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x73, 0x70, 0x65, + 0x6e, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, + 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x2f, 0x62, 0x79, 0x5f, 0x64, 0x65, 0x6e, + 0x6f, 0x6d, 0x12, 0x94, 0x01, 0x0a, 0x0b, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x75, 0x70, 0x70, + 0x6c, 0x79, 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x6f, + 0x74, 0x61, 0x6c, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x6f, 0x74, 0x61, + 0x6c, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x28, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2f, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x12, 0x94, 0x01, 0x0a, 0x08, 0x53, 0x75, + 0x70, 0x70, 0x6c, 0x79, 0x4f, 0x66, 0x12, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x4f, 0x66, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x75, 0x70, + 0x70, 0x6c, 0x79, 0x4f, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0x88, + 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, + 0x2f, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x2f, 0x62, 0x79, 0x5f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, + 0x12, 0x85, 0x01, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x27, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, + 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, - 0x31, 0x2f, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x12, 0x94, 0x01, 0x0a, 0x08, 0x53, 0x75, 0x70, - 0x70, 0x6c, 0x79, 0x4f, 0x66, 0x12, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, - 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x4f, 0x66, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, - 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x75, 0x70, 0x70, - 0x6c, 0x79, 0x4f, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0x88, 0xe7, - 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, - 0x73, 0x75, 0x70, 0x70, 0x6c, 0x79, 0x2f, 0x62, 0x79, 0x5f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x12, - 0x85, 0x01, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, + 0x31, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0xab, 0x01, 0x0a, 0x0d, 0x44, 0x65, 0x6e, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, - 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, - 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, - 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x88, - 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, - 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0xab, 0x01, 0x0a, 0x0d, 0x44, 0x65, 0x6e, 0x6f, - 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x39, 0x88, 0xe7, 0xb0, 0x2a, - 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2e, 0x12, 0x2c, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, - 0x6e, 0x6f, 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2f, 0x7b, 0x64, - 0x65, 0x6e, 0x6f, 0x6d, 0x7d, 0x12, 0xda, 0x01, 0x0a, 0x1a, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, - 0x72, 0x69, 0x6e, 0x67, 0x12, 0x3b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, - 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, 0x51, - 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x3c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, - 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, - 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x41, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x36, 0x12, 0x34, 0x2f, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, - 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x5f, 0x62, 0x79, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x73, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x12, 0xa6, 0x01, 0x0a, 0x0e, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x39, 0x88, 0xe7, 0xb0, + 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2e, 0x12, 0x2c, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, + 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2f, 0x7b, + 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x7d, 0x12, 0xda, 0x01, 0x0a, 0x1a, 0x44, 0x65, 0x6e, 0x6f, 0x6d, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, + 0x74, 0x72, 0x69, 0x6e, 0x67, 0x12, 0x3b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x3c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, + 0x6e, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0x79, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x41, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x36, 0x12, 0x34, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0x5f, 0x62, 0x79, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x73, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x12, 0xa6, 0x01, 0x0a, 0x0e, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, - 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, 0x6f, - 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0xa2, 0x01, 0x0a, 0x0b, - 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x12, 0x2c, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, - 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x36, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x2b, 0x12, 0x29, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, - 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, 0x6f, - 0x6d, 0x5f, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x2f, 0x7b, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x7d, - 0x12, 0x9a, 0x01, 0x0a, 0x0b, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, - 0x12, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, - 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, - 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, - 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, - 0x61, 0x62, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x88, - 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x12, 0x21, 0x2f, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, - 0x2f, 0x73, 0x65, 0x6e, 0x64, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x42, 0xc5, 0x01, - 0x0a, 0x17, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, - 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, - 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x3b, 0x62, 0x61, - 0x6e, 0x6b, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x42, 0x58, 0xaa, - 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x42, 0x61, 0x6e, 0x6b, 0x2e, 0x56, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x42, - 0x61, 0x6e, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xe2, 0x02, 0x1f, 0x43, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x42, 0x61, 0x6e, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, - 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x15, - 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x42, 0x61, 0x6e, 0x6b, 0x3a, 0x3a, 0x56, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x73, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0x88, 0xe7, 0xb0, 0x2a, 0x01, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, + 0x6f, 0x6d, 0x73, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0xa2, 0x01, 0x0a, + 0x0b, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x12, 0x2c, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x36, 0x88, 0xe7, 0xb0, 0x2a, 0x01, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2b, 0x12, 0x29, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, + 0x6f, 0x6d, 0x5f, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x2f, 0x7b, 0x64, 0x65, 0x6e, 0x6f, 0x6d, + 0x7d, 0x12, 0xb8, 0x01, 0x0a, 0x12, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, + 0x73, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x33, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x73, 0x42, + 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x34, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x73, 0x42, 0x79, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x37, 0x88, 0xe7, 0xb0, 0x2a, 0x01, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2c, + 0x12, 0x2a, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x5f, 0x6f, 0x77, 0x6e, + 0x65, 0x72, 0x73, 0x5f, 0x62, 0x79, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x9a, 0x01, 0x0a, + 0x0b, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x2c, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, + 0x6c, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x6e, 0x64, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, + 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x88, 0xe7, 0xb0, 0x2a, 0x01, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x12, 0x21, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x62, 0x61, 0x6e, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x73, 0x65, 0x6e, + 0x64, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x42, 0xc5, 0x01, 0x0a, 0x17, 0x63, 0x6f, + 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x6e, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x6e, + 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x3b, 0x62, 0x61, 0x6e, 0x6b, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x42, 0x58, 0xaa, 0x02, 0x13, 0x43, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x42, 0x61, 0x6e, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x42, 0x61, 0x6e, 0x6b, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xe2, 0x02, 0x1f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x5c, 0x42, 0x61, 0x6e, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x15, 0x43, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x3a, 0x3a, 0x42, 0x61, 0x6e, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -13598,7 +14798,7 @@ func file_cosmos_bank_v1beta1_query_proto_rawDescGZIP() []byte { return file_cosmos_bank_v1beta1_query_proto_rawDescData } -var file_cosmos_bank_v1beta1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_cosmos_bank_v1beta1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_cosmos_bank_v1beta1_query_proto_goTypes = []interface{}{ (*QueryBalanceRequest)(nil), // 0: cosmos.bank.v1beta1.QueryBalanceRequest (*QueryBalanceResponse)(nil), // 1: cosmos.bank.v1beta1.QueryBalanceResponse @@ -13623,70 +14823,77 @@ var file_cosmos_bank_v1beta1_query_proto_goTypes = []interface{}{ (*QueryDenomOwnersRequest)(nil), // 20: cosmos.bank.v1beta1.QueryDenomOwnersRequest (*DenomOwner)(nil), // 21: cosmos.bank.v1beta1.DenomOwner (*QueryDenomOwnersResponse)(nil), // 22: cosmos.bank.v1beta1.QueryDenomOwnersResponse - (*QuerySendEnabledRequest)(nil), // 23: cosmos.bank.v1beta1.QuerySendEnabledRequest - (*QuerySendEnabledResponse)(nil), // 24: cosmos.bank.v1beta1.QuerySendEnabledResponse - (*v1beta1.Coin)(nil), // 25: cosmos.base.v1beta1.Coin - (*v1beta11.PageRequest)(nil), // 26: cosmos.base.query.v1beta1.PageRequest - (*v1beta11.PageResponse)(nil), // 27: cosmos.base.query.v1beta1.PageResponse - (*Params)(nil), // 28: cosmos.bank.v1beta1.Params - (*Metadata)(nil), // 29: cosmos.bank.v1beta1.Metadata - (*SendEnabled)(nil), // 30: cosmos.bank.v1beta1.SendEnabled + (*QueryDenomOwnersByQueryRequest)(nil), // 23: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest + (*QueryDenomOwnersByQueryResponse)(nil), // 24: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse + (*QuerySendEnabledRequest)(nil), // 25: cosmos.bank.v1beta1.QuerySendEnabledRequest + (*QuerySendEnabledResponse)(nil), // 26: cosmos.bank.v1beta1.QuerySendEnabledResponse + (*v1beta1.Coin)(nil), // 27: cosmos.base.v1beta1.Coin + (*v1beta11.PageRequest)(nil), // 28: cosmos.base.query.v1beta1.PageRequest + (*v1beta11.PageResponse)(nil), // 29: cosmos.base.query.v1beta1.PageResponse + (*Params)(nil), // 30: cosmos.bank.v1beta1.Params + (*Metadata)(nil), // 31: cosmos.bank.v1beta1.Metadata + (*SendEnabled)(nil), // 32: cosmos.bank.v1beta1.SendEnabled } var file_cosmos_bank_v1beta1_query_proto_depIdxs = []int32{ - 25, // 0: cosmos.bank.v1beta1.QueryBalanceResponse.balance:type_name -> cosmos.base.v1beta1.Coin - 26, // 1: cosmos.bank.v1beta1.QueryAllBalancesRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 25, // 2: cosmos.bank.v1beta1.QueryAllBalancesResponse.balances:type_name -> cosmos.base.v1beta1.Coin - 27, // 3: cosmos.bank.v1beta1.QueryAllBalancesResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 26, // 4: cosmos.bank.v1beta1.QuerySpendableBalancesRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 25, // 5: cosmos.bank.v1beta1.QuerySpendableBalancesResponse.balances:type_name -> cosmos.base.v1beta1.Coin - 27, // 6: cosmos.bank.v1beta1.QuerySpendableBalancesResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 25, // 7: cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse.balance:type_name -> cosmos.base.v1beta1.Coin - 26, // 8: cosmos.bank.v1beta1.QueryTotalSupplyRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 25, // 9: cosmos.bank.v1beta1.QueryTotalSupplyResponse.supply:type_name -> cosmos.base.v1beta1.Coin - 27, // 10: cosmos.bank.v1beta1.QueryTotalSupplyResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 25, // 11: cosmos.bank.v1beta1.QuerySupplyOfResponse.amount:type_name -> cosmos.base.v1beta1.Coin - 28, // 12: cosmos.bank.v1beta1.QueryParamsResponse.params:type_name -> cosmos.bank.v1beta1.Params - 26, // 13: cosmos.bank.v1beta1.QueryDenomsMetadataRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 29, // 14: cosmos.bank.v1beta1.QueryDenomsMetadataResponse.metadatas:type_name -> cosmos.bank.v1beta1.Metadata - 27, // 15: cosmos.bank.v1beta1.QueryDenomsMetadataResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 29, // 16: cosmos.bank.v1beta1.QueryDenomMetadataResponse.metadata:type_name -> cosmos.bank.v1beta1.Metadata - 29, // 17: cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringResponse.metadata:type_name -> cosmos.bank.v1beta1.Metadata - 26, // 18: cosmos.bank.v1beta1.QueryDenomOwnersRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 25, // 19: cosmos.bank.v1beta1.DenomOwner.balance:type_name -> cosmos.base.v1beta1.Coin + 27, // 0: cosmos.bank.v1beta1.QueryBalanceResponse.balance:type_name -> cosmos.base.v1beta1.Coin + 28, // 1: cosmos.bank.v1beta1.QueryAllBalancesRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 27, // 2: cosmos.bank.v1beta1.QueryAllBalancesResponse.balances:type_name -> cosmos.base.v1beta1.Coin + 29, // 3: cosmos.bank.v1beta1.QueryAllBalancesResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 28, // 4: cosmos.bank.v1beta1.QuerySpendableBalancesRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 27, // 5: cosmos.bank.v1beta1.QuerySpendableBalancesResponse.balances:type_name -> cosmos.base.v1beta1.Coin + 29, // 6: cosmos.bank.v1beta1.QuerySpendableBalancesResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 27, // 7: cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse.balance:type_name -> cosmos.base.v1beta1.Coin + 28, // 8: cosmos.bank.v1beta1.QueryTotalSupplyRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 27, // 9: cosmos.bank.v1beta1.QueryTotalSupplyResponse.supply:type_name -> cosmos.base.v1beta1.Coin + 29, // 10: cosmos.bank.v1beta1.QueryTotalSupplyResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 27, // 11: cosmos.bank.v1beta1.QuerySupplyOfResponse.amount:type_name -> cosmos.base.v1beta1.Coin + 30, // 12: cosmos.bank.v1beta1.QueryParamsResponse.params:type_name -> cosmos.bank.v1beta1.Params + 28, // 13: cosmos.bank.v1beta1.QueryDenomsMetadataRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 31, // 14: cosmos.bank.v1beta1.QueryDenomsMetadataResponse.metadatas:type_name -> cosmos.bank.v1beta1.Metadata + 29, // 15: cosmos.bank.v1beta1.QueryDenomsMetadataResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 31, // 16: cosmos.bank.v1beta1.QueryDenomMetadataResponse.metadata:type_name -> cosmos.bank.v1beta1.Metadata + 31, // 17: cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringResponse.metadata:type_name -> cosmos.bank.v1beta1.Metadata + 28, // 18: cosmos.bank.v1beta1.QueryDenomOwnersRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 27, // 19: cosmos.bank.v1beta1.DenomOwner.balance:type_name -> cosmos.base.v1beta1.Coin 21, // 20: cosmos.bank.v1beta1.QueryDenomOwnersResponse.denom_owners:type_name -> cosmos.bank.v1beta1.DenomOwner - 27, // 21: cosmos.bank.v1beta1.QueryDenomOwnersResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 26, // 22: cosmos.bank.v1beta1.QuerySendEnabledRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 30, // 23: cosmos.bank.v1beta1.QuerySendEnabledResponse.send_enabled:type_name -> cosmos.bank.v1beta1.SendEnabled - 27, // 24: cosmos.bank.v1beta1.QuerySendEnabledResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 0, // 25: cosmos.bank.v1beta1.Query.Balance:input_type -> cosmos.bank.v1beta1.QueryBalanceRequest - 2, // 26: cosmos.bank.v1beta1.Query.AllBalances:input_type -> cosmos.bank.v1beta1.QueryAllBalancesRequest - 4, // 27: cosmos.bank.v1beta1.Query.SpendableBalances:input_type -> cosmos.bank.v1beta1.QuerySpendableBalancesRequest - 6, // 28: cosmos.bank.v1beta1.Query.SpendableBalanceByDenom:input_type -> cosmos.bank.v1beta1.QuerySpendableBalanceByDenomRequest - 8, // 29: cosmos.bank.v1beta1.Query.TotalSupply:input_type -> cosmos.bank.v1beta1.QueryTotalSupplyRequest - 10, // 30: cosmos.bank.v1beta1.Query.SupplyOf:input_type -> cosmos.bank.v1beta1.QuerySupplyOfRequest - 12, // 31: cosmos.bank.v1beta1.Query.Params:input_type -> cosmos.bank.v1beta1.QueryParamsRequest - 16, // 32: cosmos.bank.v1beta1.Query.DenomMetadata:input_type -> cosmos.bank.v1beta1.QueryDenomMetadataRequest - 18, // 33: cosmos.bank.v1beta1.Query.DenomMetadataByQueryString:input_type -> cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringRequest - 14, // 34: cosmos.bank.v1beta1.Query.DenomsMetadata:input_type -> cosmos.bank.v1beta1.QueryDenomsMetadataRequest - 20, // 35: cosmos.bank.v1beta1.Query.DenomOwners:input_type -> cosmos.bank.v1beta1.QueryDenomOwnersRequest - 23, // 36: cosmos.bank.v1beta1.Query.SendEnabled:input_type -> cosmos.bank.v1beta1.QuerySendEnabledRequest - 1, // 37: cosmos.bank.v1beta1.Query.Balance:output_type -> cosmos.bank.v1beta1.QueryBalanceResponse - 3, // 38: cosmos.bank.v1beta1.Query.AllBalances:output_type -> cosmos.bank.v1beta1.QueryAllBalancesResponse - 5, // 39: cosmos.bank.v1beta1.Query.SpendableBalances:output_type -> cosmos.bank.v1beta1.QuerySpendableBalancesResponse - 7, // 40: cosmos.bank.v1beta1.Query.SpendableBalanceByDenom:output_type -> cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse - 9, // 41: cosmos.bank.v1beta1.Query.TotalSupply:output_type -> cosmos.bank.v1beta1.QueryTotalSupplyResponse - 11, // 42: cosmos.bank.v1beta1.Query.SupplyOf:output_type -> cosmos.bank.v1beta1.QuerySupplyOfResponse - 13, // 43: cosmos.bank.v1beta1.Query.Params:output_type -> cosmos.bank.v1beta1.QueryParamsResponse - 17, // 44: cosmos.bank.v1beta1.Query.DenomMetadata:output_type -> cosmos.bank.v1beta1.QueryDenomMetadataResponse - 19, // 45: cosmos.bank.v1beta1.Query.DenomMetadataByQueryString:output_type -> cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringResponse - 15, // 46: cosmos.bank.v1beta1.Query.DenomsMetadata:output_type -> cosmos.bank.v1beta1.QueryDenomsMetadataResponse - 22, // 47: cosmos.bank.v1beta1.Query.DenomOwners:output_type -> cosmos.bank.v1beta1.QueryDenomOwnersResponse - 24, // 48: cosmos.bank.v1beta1.Query.SendEnabled:output_type -> cosmos.bank.v1beta1.QuerySendEnabledResponse - 37, // [37:49] is the sub-list for method output_type - 25, // [25:37] is the sub-list for method input_type - 25, // [25:25] is the sub-list for extension type_name - 25, // [25:25] is the sub-list for extension extendee - 0, // [0:25] is the sub-list for field type_name + 29, // 21: cosmos.bank.v1beta1.QueryDenomOwnersResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 28, // 22: cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 21, // 23: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.denom_owners:type_name -> cosmos.bank.v1beta1.DenomOwner + 29, // 24: cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 28, // 25: cosmos.bank.v1beta1.QuerySendEnabledRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 32, // 26: cosmos.bank.v1beta1.QuerySendEnabledResponse.send_enabled:type_name -> cosmos.bank.v1beta1.SendEnabled + 29, // 27: cosmos.bank.v1beta1.QuerySendEnabledResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 0, // 28: cosmos.bank.v1beta1.Query.Balance:input_type -> cosmos.bank.v1beta1.QueryBalanceRequest + 2, // 29: cosmos.bank.v1beta1.Query.AllBalances:input_type -> cosmos.bank.v1beta1.QueryAllBalancesRequest + 4, // 30: cosmos.bank.v1beta1.Query.SpendableBalances:input_type -> cosmos.bank.v1beta1.QuerySpendableBalancesRequest + 6, // 31: cosmos.bank.v1beta1.Query.SpendableBalanceByDenom:input_type -> cosmos.bank.v1beta1.QuerySpendableBalanceByDenomRequest + 8, // 32: cosmos.bank.v1beta1.Query.TotalSupply:input_type -> cosmos.bank.v1beta1.QueryTotalSupplyRequest + 10, // 33: cosmos.bank.v1beta1.Query.SupplyOf:input_type -> cosmos.bank.v1beta1.QuerySupplyOfRequest + 12, // 34: cosmos.bank.v1beta1.Query.Params:input_type -> cosmos.bank.v1beta1.QueryParamsRequest + 16, // 35: cosmos.bank.v1beta1.Query.DenomMetadata:input_type -> cosmos.bank.v1beta1.QueryDenomMetadataRequest + 18, // 36: cosmos.bank.v1beta1.Query.DenomMetadataByQueryString:input_type -> cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringRequest + 14, // 37: cosmos.bank.v1beta1.Query.DenomsMetadata:input_type -> cosmos.bank.v1beta1.QueryDenomsMetadataRequest + 20, // 38: cosmos.bank.v1beta1.Query.DenomOwners:input_type -> cosmos.bank.v1beta1.QueryDenomOwnersRequest + 23, // 39: cosmos.bank.v1beta1.Query.DenomOwnersByQuery:input_type -> cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest + 25, // 40: cosmos.bank.v1beta1.Query.SendEnabled:input_type -> cosmos.bank.v1beta1.QuerySendEnabledRequest + 1, // 41: cosmos.bank.v1beta1.Query.Balance:output_type -> cosmos.bank.v1beta1.QueryBalanceResponse + 3, // 42: cosmos.bank.v1beta1.Query.AllBalances:output_type -> cosmos.bank.v1beta1.QueryAllBalancesResponse + 5, // 43: cosmos.bank.v1beta1.Query.SpendableBalances:output_type -> cosmos.bank.v1beta1.QuerySpendableBalancesResponse + 7, // 44: cosmos.bank.v1beta1.Query.SpendableBalanceByDenom:output_type -> cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse + 9, // 45: cosmos.bank.v1beta1.Query.TotalSupply:output_type -> cosmos.bank.v1beta1.QueryTotalSupplyResponse + 11, // 46: cosmos.bank.v1beta1.Query.SupplyOf:output_type -> cosmos.bank.v1beta1.QuerySupplyOfResponse + 13, // 47: cosmos.bank.v1beta1.Query.Params:output_type -> cosmos.bank.v1beta1.QueryParamsResponse + 17, // 48: cosmos.bank.v1beta1.Query.DenomMetadata:output_type -> cosmos.bank.v1beta1.QueryDenomMetadataResponse + 19, // 49: cosmos.bank.v1beta1.Query.DenomMetadataByQueryString:output_type -> cosmos.bank.v1beta1.QueryDenomMetadataByQueryStringResponse + 15, // 50: cosmos.bank.v1beta1.Query.DenomsMetadata:output_type -> cosmos.bank.v1beta1.QueryDenomsMetadataResponse + 22, // 51: cosmos.bank.v1beta1.Query.DenomOwners:output_type -> cosmos.bank.v1beta1.QueryDenomOwnersResponse + 24, // 52: cosmos.bank.v1beta1.Query.DenomOwnersByQuery:output_type -> cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse + 26, // 53: cosmos.bank.v1beta1.Query.SendEnabled:output_type -> cosmos.bank.v1beta1.QuerySendEnabledResponse + 41, // [41:54] is the sub-list for method output_type + 28, // [28:41] is the sub-list for method input_type + 28, // [28:28] is the sub-list for extension type_name + 28, // [28:28] is the sub-list for extension extendee + 0, // [0:28] is the sub-list for field type_name } func init() { file_cosmos_bank_v1beta1_query_proto_init() } @@ -13973,7 +15180,7 @@ func file_cosmos_bank_v1beta1_query_proto_init() { } } file_cosmos_bank_v1beta1_query_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QuerySendEnabledRequest); i { + switch v := v.(*QueryDenomOwnersByQueryRequest); i { case 0: return &v.state case 1: @@ -13985,6 +15192,30 @@ func file_cosmos_bank_v1beta1_query_proto_init() { } } file_cosmos_bank_v1beta1_query_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryDenomOwnersByQueryResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_bank_v1beta1_query_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySendEnabledRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cosmos_bank_v1beta1_query_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*QuerySendEnabledResponse); i { case 0: return &v.state @@ -14003,7 +15234,7 @@ func file_cosmos_bank_v1beta1_query_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_bank_v1beta1_query_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/api/cosmos/bank/v1beta1/query_grpc.pb.go b/api/cosmos/bank/v1beta1/query_grpc.pb.go index 57fcf155e846..d22562e99fd9 100644 --- a/api/cosmos/bank/v1beta1/query_grpc.pb.go +++ b/api/cosmos/bank/v1beta1/query_grpc.pb.go @@ -30,6 +30,7 @@ const ( Query_DenomMetadataByQueryString_FullMethodName = "/cosmos.bank.v1beta1.Query/DenomMetadataByQueryString" Query_DenomsMetadata_FullMethodName = "/cosmos.bank.v1beta1.Query/DenomsMetadata" Query_DenomOwners_FullMethodName = "/cosmos.bank.v1beta1.Query/DenomOwners" + Query_DenomOwnersByQuery_FullMethodName = "/cosmos.bank.v1beta1.Query/DenomOwnersByQuery" Query_SendEnabled_FullMethodName = "/cosmos.bank.v1beta1.Query/SendEnabled" ) @@ -72,9 +73,9 @@ type QueryClient interface { SupplyOf(ctx context.Context, in *QuerySupplyOfRequest, opts ...grpc.CallOption) (*QuerySupplyOfResponse, error) // Params queries the parameters of x/bank module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadata queries the client metadata of a given coin denomination. DenomMetadata(ctx context.Context, in *QueryDenomMetadataRequest, opts ...grpc.CallOption) (*QueryDenomMetadataResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadataByQueryString queries the client metadata of a given coin denomination. DenomMetadataByQueryString(ctx context.Context, in *QueryDenomMetadataByQueryStringRequest, opts ...grpc.CallOption) (*QueryDenomMetadataByQueryStringResponse, error) // DenomsMetadata queries the client metadata for all registered coin // denominations. @@ -87,6 +88,11 @@ type QueryClient interface { // // Since: cosmos-sdk 0.46 DenomOwners(ctx context.Context, in *QueryDenomOwnersRequest, opts ...grpc.CallOption) (*QueryDenomOwnersResponse, error) + // DenomOwnersByQuery queries for all account addresses that own a particular token + // denomination. + // + // Since: cosmos-sdk 0.50.3 + DenomOwnersByQuery(ctx context.Context, in *QueryDenomOwnersByQueryRequest, opts ...grpc.CallOption) (*QueryDenomOwnersByQueryResponse, error) // SendEnabled queries for SendEnabled entries. // // This query only returns denominations that have specific SendEnabled settings. @@ -204,6 +210,15 @@ func (c *queryClient) DenomOwners(ctx context.Context, in *QueryDenomOwnersReque return out, nil } +func (c *queryClient) DenomOwnersByQuery(ctx context.Context, in *QueryDenomOwnersByQueryRequest, opts ...grpc.CallOption) (*QueryDenomOwnersByQueryResponse, error) { + out := new(QueryDenomOwnersByQueryResponse) + err := c.cc.Invoke(ctx, Query_DenomOwnersByQuery_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *queryClient) SendEnabled(ctx context.Context, in *QuerySendEnabledRequest, opts ...grpc.CallOption) (*QuerySendEnabledResponse, error) { out := new(QuerySendEnabledResponse) err := c.cc.Invoke(ctx, Query_SendEnabled_FullMethodName, in, out, opts...) @@ -252,9 +267,9 @@ type QueryServer interface { SupplyOf(context.Context, *QuerySupplyOfRequest) (*QuerySupplyOfResponse, error) // Params queries the parameters of x/bank module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadata queries the client metadata of a given coin denomination. DenomMetadata(context.Context, *QueryDenomMetadataRequest) (*QueryDenomMetadataResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadataByQueryString queries the client metadata of a given coin denomination. DenomMetadataByQueryString(context.Context, *QueryDenomMetadataByQueryStringRequest) (*QueryDenomMetadataByQueryStringResponse, error) // DenomsMetadata queries the client metadata for all registered coin // denominations. @@ -267,6 +282,11 @@ type QueryServer interface { // // Since: cosmos-sdk 0.46 DenomOwners(context.Context, *QueryDenomOwnersRequest) (*QueryDenomOwnersResponse, error) + // DenomOwnersByQuery queries for all account addresses that own a particular token + // denomination. + // + // Since: cosmos-sdk 0.50.3 + DenomOwnersByQuery(context.Context, *QueryDenomOwnersByQueryRequest) (*QueryDenomOwnersByQueryResponse, error) // SendEnabled queries for SendEnabled entries. // // This query only returns denominations that have specific SendEnabled settings. @@ -315,6 +335,9 @@ func (UnimplementedQueryServer) DenomsMetadata(context.Context, *QueryDenomsMeta func (UnimplementedQueryServer) DenomOwners(context.Context, *QueryDenomOwnersRequest) (*QueryDenomOwnersResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DenomOwners not implemented") } +func (UnimplementedQueryServer) DenomOwnersByQuery(context.Context, *QueryDenomOwnersByQueryRequest) (*QueryDenomOwnersByQueryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DenomOwnersByQuery not implemented") +} func (UnimplementedQueryServer) SendEnabled(context.Context, *QuerySendEnabledRequest) (*QuerySendEnabledResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SendEnabled not implemented") } @@ -529,6 +552,24 @@ func _Query_DenomOwners_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_DenomOwnersByQuery_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryDenomOwnersByQueryRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).DenomOwnersByQuery(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_DenomOwnersByQuery_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).DenomOwnersByQuery(ctx, req.(*QueryDenomOwnersByQueryRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Query_SendEnabled_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySendEnabledRequest) if err := dec(in); err != nil { @@ -598,6 +639,10 @@ var Query_ServiceDesc = grpc.ServiceDesc{ MethodName: "DenomOwners", Handler: _Query_DenomOwners_Handler, }, + { + MethodName: "DenomOwnersByQuery", + Handler: _Query_DenomOwnersByQuery_Handler, + }, { MethodName: "SendEnabled", Handler: _Query_SendEnabled_Handler, diff --git a/client/docs/swagger-ui/swagger.yaml b/client/docs/swagger-ui/swagger.yaml index b60f2c0f4466..173676b0b5f9 100644 --- a/client/docs/swagger-ui/swagger.yaml +++ b/client/docs/swagger-ui/swagger.yaml @@ -3583,6 +3583,166 @@ paths: descending order. + Since: cosmos-sdk 0.43 + in: query + required: false + type: boolean + tags: + - Query + /cosmos/bank/v1beta1/denom_owners_by_query: + get: + summary: >- + DenomOwners queries for all account addresses that own a particular + token + + denomination. + operationId: DenomOwnersByQuery + responses: + '200': + description: A successful response. + schema: + type: object + properties: + denom_owners: + type: array + items: + type: object + properties: + address: + type: string + description: >- + address defines the address that owns a particular + denomination. + balance: + type: object + properties: + denom: + type: string + amount: + type: string + description: >- + Coin defines a token with a denomination and an amount. + + + NOTE: The amount field is an Int which implements the + custom method + + signatures required by gogoproto. + description: >- + DenomOwner defines structure representing an account that + owns or holds a + + particular denominated token. It contains the account + address and account + + balance of the denominated token. + + + Since: cosmos-sdk 0.46 + pagination: + description: pagination defines the pagination in the response. + type: object + properties: + next_key: + type: string + format: byte + description: |- + next_key is the key to be passed to PageRequest.key to + query the next page most efficiently. It will be empty if + there are no more results. + total: + type: string + format: uint64 + title: >- + total is total number of results available if + PageRequest.count_total + + was set, its value is undefined otherwise + description: >- + QueryDenomOwnersByQueryResponse defines the RPC response of a + DenomOwnersByQuery RPC query. + default: + description: An unexpected error response. + schema: + type: object + properties: + error: + type: string + code: + type: integer + format: int32 + message: + type: string + details: + type: array + items: + type: object + properties: + type_url: + type: string + value: + type: string + format: byte + parameters: + - name: denom + description: >- + denom defines the coin denomination to query all account holders + for. + in: query + required: false + type: string + - name: pagination.key + description: |- + key is a value returned in PageResponse.next_key to begin + querying the next page most efficiently. Only one of offset or key + should be set. + in: query + required: false + type: string + format: byte + - name: pagination.offset + description: >- + offset is a numeric offset that can be used when key is unavailable. + + It is less efficient than using key. Only one of offset or key + should + + be set. + in: query + required: false + type: string + format: uint64 + - name: pagination.limit + description: >- + limit is the total number of results to be returned in the result + page. + + If left empty it will default to a value to be set by each app. + in: query + required: false + type: string + format: uint64 + - name: pagination.count_total + description: >- + count_total is set to true to indicate that the result set should + include + + a count of the total number of items available for pagination in + UIs. + + count_total is only respected when offset is used. It is ignored + when key + + is set. + in: query + required: false + type: boolean + - name: pagination.reverse + description: >- + reverse is set to true if results are to be returned in the + descending order. + + Since: cosmos-sdk 0.43 in: query required: false @@ -14281,12 +14441,15 @@ paths: period. burn_vote_quorum: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if quorum with vote type no_veto is met min_deposit_ratio: type: string @@ -14301,6 +14464,41 @@ paths: Since: cosmos-sdk 0.50 + proposal_cancel_max_period: + type: string + description: >- + proposal_cancel_max_period defines how far in the voting + period a proposer can cancel a proposal. + + If the proposal is cancelled before the max cancel period, + the deposit will be returned/burn to the + + depositors, according to the proposal_cancel_ratio and + proposal_cancel_dest parameters. + + After the max cancel period, the proposal cannot be + cancelled anymore. + optimistic_authorized_addresses: + type: array + items: + type: string + description: 'Since: x/gov v1.0.0' + title: >- + optimistic_authorized_addresses is an optional governance + parameter that limits the authorized accounts than can + + submit optimistic proposals + optimistic_rejected_threshold: + type: string + description: >- + optimistic rejected threshold defines at which percentage + of NO votes, the optimistic proposal should fail and be + + converted to a standard proposal. The threshold is + expressed as a percentage of the total bonded tokens. + + + Since: x/gov v1.0.0 description: >- QueryParamsResponse is the response type for the Query/Params RPC method. @@ -14756,6 +14954,11 @@ paths: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: >- + spam_count is the number of spam votes on a + proposal. submit_time: type: string format: date-time @@ -14817,12 +15020,25 @@ paths: title: proposer is the address of the proposal sumbitter expedited: type: boolean - description: 'Since: cosmos-sdk 0.50' + description: |- + Since: cosmos-sdk 0.50 + Deprecated: Use ProposalType instead. title: expedited defines if the proposal is expedited failed_reason: type: string description: 'Since: cosmos-sdk 0.50' title: failed_reason defines the reason why the proposal failed + proposal_type: + description: 'Since: cosmos-sdk 0.51' + title: proposal_type defines the type of the proposal + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED description: >- Proposal defines the core field members of a governance proposal. @@ -15384,6 +15600,9 @@ paths: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. submit_time: type: string format: date-time @@ -15444,12 +15663,25 @@ paths: title: proposer is the address of the proposal sumbitter expedited: type: boolean - description: 'Since: cosmos-sdk 0.50' + description: |- + Since: cosmos-sdk 0.50 + Deprecated: Use ProposalType instead. title: expedited defines if the proposal is expedited failed_reason: type: string description: 'Since: cosmos-sdk 0.50' title: failed_reason defines the reason why the proposal failed + proposal_type: + description: 'Since: cosmos-sdk 0.51' + title: proposal_type defines the type of the proposal + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED description: >- Proposal defines the core field members of a governance proposal. @@ -16280,6 +16512,9 @@ paths: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. @@ -16521,10 +16756,15 @@ paths: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -16863,10 +17103,15 @@ paths: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -30320,6 +30565,7 @@ paths: summary: >- BalancebyQueryString queries the number of NFTs of a given class owned by the owner, same as balanceOf in ERC721 + description: 'Since: nft v0.1.1' operationId: BalanceByQueryString responses: '200': @@ -30333,6 +30579,7 @@ paths: title: >- amount is the number of all NFTs of a given class owned by the owner + description: 'Since: nft v0.1.1' title: >- QueryBalanceByQueryStringResponse is the response type for the Query/Balance RPC method @@ -30776,6 +31023,7 @@ paths: /cosmos/nft/v1beta1/class: get: summary: Class queries an NFT class based on its id + description: 'Since: nft v0.1.1' operationId: ClassByQueryString responses: '200': @@ -31001,6 +31249,7 @@ paths: title: >- data is the app specific metadata of the NFT class. Optional + description: 'Since: nft v0.1.1' title: >- QueryClassByQueryStringResponse is the response type for the Query/Class RPC method @@ -32155,6 +32404,7 @@ paths: /cosmos/nft/v1beta1/nft: get: summary: NFTByQueryString queries an NFT based on its class and id. + description: 'Since: nft v0.1.1' operationId: NFTByQueryString responses: '200': @@ -32363,6 +32613,7 @@ paths: } title: data is an app specific data of the NFT. Optional description: NFT defines the NFT. + description: 'Since: nft v0.1.1' title: >- QueryNFTByQueryStringResponse is the response type for the Query/NFT RPC method @@ -33504,6 +33755,7 @@ paths: summary: >- OwnerByQueryString queries the owner of the NFT based on its class and id, same as ownerOf in ERC721 + description: 'Since: nft v0.1.1' operationId: OwnerByQueryString responses: '200': @@ -33514,6 +33766,7 @@ paths: owner: type: string title: owner is the owner address of the nft + description: 'Since: nft v0.1.1' title: >- QueryOwnerByQueryStringResponse is the response type for the Query/Owner RPC method @@ -33956,6 +34209,7 @@ paths: summary: >- SupplyByQueryString queries the number of NFTs from the given class, same as totalSupply of ERC721. + description: 'Since: nft v0.1.1' operationId: SupplyByQueryString responses: '200': @@ -33967,6 +34221,7 @@ paths: type: string format: uint64 title: amount is the number of all NFTs from the given class + description: 'Since: nft v0.1.1' title: >- QuerySupplyByQueryStringResponse is the response type for the Query/Supply RPC method @@ -42218,6 +42473,65 @@ definitions: Query/DenomMetadata RPC method. + cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse: + type: object + properties: + denom_owners: + type: array + items: + type: object + properties: + address: + type: string + description: address defines the address that owns a particular denomination. + balance: + type: object + properties: + denom: + type: string + amount: + type: string + description: >- + Coin defines a token with a denomination and an amount. + + + NOTE: The amount field is an Int which implements the custom + method + + signatures required by gogoproto. + description: >- + DenomOwner defines structure representing an account that owns or + holds a + + particular denominated token. It contains the account address and + account + + balance of the denominated token. + + + Since: cosmos-sdk 0.46 + pagination: + description: pagination defines the pagination in the response. + type: object + properties: + next_key: + type: string + format: byte + description: |- + next_key is the key to be passed to PageRequest.key to + query the next page most efficiently. It will be empty if + there are no more results. + total: + type: string + format: uint64 + title: >- + total is total number of results available if + PageRequest.count_total + + was set, its value is undefined otherwise + description: >- + QueryDenomOwnersByQueryResponse defines the RPC response of a + DenomOwnersByQuery RPC query. cosmos.bank.v1beta1.QueryDenomOwnersResponse: type: object properties: @@ -51350,12 +51664,15 @@ definitions: description: Minimum expedited deposit for a proposal to enter voting period. burn_vote_quorum: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if quorum with vote type no_veto is met min_deposit_ratio: type: string @@ -51370,6 +51687,40 @@ definitions: Since: cosmos-sdk 0.50 + proposal_cancel_max_period: + type: string + description: >- + proposal_cancel_max_period defines how far in the voting period a + proposer can cancel a proposal. + + If the proposal is cancelled before the max cancel period, the deposit + will be returned/burn to the + + depositors, according to the proposal_cancel_ratio and + proposal_cancel_dest parameters. + + After the max cancel period, the proposal cannot be cancelled anymore. + optimistic_authorized_addresses: + type: array + items: + type: string + description: 'Since: x/gov v1.0.0' + title: >- + optimistic_authorized_addresses is an optional governance parameter + that limits the authorized accounts than can + + submit optimistic proposals + optimistic_rejected_threshold: + type: string + description: >- + optimistic rejected threshold defines at which percentage of NO votes, + the optimistic proposal should fail and be + + converted to a standard proposal. The threshold is expressed as a + percentage of the total bonded tokens. + + + Since: x/gov v1.0.0 description: |- Params defines the parameters for the x/gov module. @@ -51586,6 +51937,9 @@ definitions: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. submit_time: type: string format: date-time @@ -51637,12 +51991,25 @@ definitions: title: proposer is the address of the proposal sumbitter expedited: type: boolean - description: 'Since: cosmos-sdk 0.50' + description: |- + Since: cosmos-sdk 0.50 + Deprecated: Use ProposalType instead. title: expedited defines if the proposal is expedited failed_reason: type: string description: 'Since: cosmos-sdk 0.50' title: failed_reason defines the reason why the proposal failed + proposal_type: + description: 'Since: cosmos-sdk 0.51' + title: proposal_type defines the type of the proposal + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED description: Proposal defines the core field members of a governance proposal. cosmos.gov.v1.ProposalStatus: type: string @@ -51668,6 +52035,26 @@ definitions: been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. + cosmos.gov.v1.ProposalType: + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED + description: >- + ProposalType enumerates the valid proposal types. + + All proposal types are v1.Proposal which have different voting periods or + tallying logic. + + - PROPOSAL_TYPE_UNSPECIFIED: PROPOSAL_TYPE_UNSPECIFIED defines no proposal type, which fallback to PROPOSAL_TYPE_STANDARD. + - PROPOSAL_TYPE_STANDARD: PROPOSAL_TYPE_STANDARD defines the type for a standard proposal. + - PROPOSAL_TYPE_MULTIPLE_CHOICE: PROPOSAL_TYPE_MULTIPLE_CHOICE defines the type for a multiple choice proposal. + - PROPOSAL_TYPE_OPTIMISTIC: PROPOSAL_TYPE_OPTIMISTIC defines the type for an optimistic proposal. + - PROPOSAL_TYPE_EXPEDITED: PROPOSAL_TYPE_EXPEDITED defines the type for an expedited proposal. cosmos.gov.v1.QueryConstitutionResponse: type: object properties: @@ -51952,12 +52339,15 @@ definitions: description: Minimum expedited deposit for a proposal to enter voting period. burn_vote_quorum: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean + description: 'Since: cosmos-sdk 0.47' title: burn deposits if quorum with vote type no_veto is met min_deposit_ratio: type: string @@ -51972,6 +52362,41 @@ definitions: Since: cosmos-sdk 0.50 + proposal_cancel_max_period: + type: string + description: >- + proposal_cancel_max_period defines how far in the voting period a + proposer can cancel a proposal. + + If the proposal is cancelled before the max cancel period, the + deposit will be returned/burn to the + + depositors, according to the proposal_cancel_ratio and + proposal_cancel_dest parameters. + + After the max cancel period, the proposal cannot be cancelled + anymore. + optimistic_authorized_addresses: + type: array + items: + type: string + description: 'Since: x/gov v1.0.0' + title: >- + optimistic_authorized_addresses is an optional governance + parameter that limits the authorized accounts than can + + submit optimistic proposals + optimistic_rejected_threshold: + type: string + description: >- + optimistic rejected threshold defines at which percentage of NO + votes, the optimistic proposal should fail and be + + converted to a standard proposal. The threshold is expressed as a + percentage of the total bonded tokens. + + + Since: x/gov v1.0.0 description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.gov.v1.QueryProposalResponse: type: object @@ -52198,6 +52623,9 @@ definitions: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. submit_time: type: string format: date-time @@ -52252,12 +52680,25 @@ definitions: title: proposer is the address of the proposal sumbitter expedited: type: boolean - description: 'Since: cosmos-sdk 0.50' + description: |- + Since: cosmos-sdk 0.50 + Deprecated: Use ProposalType instead. title: expedited defines if the proposal is expedited failed_reason: type: string description: 'Since: cosmos-sdk 0.50' title: failed_reason defines the reason why the proposal failed + proposal_type: + description: 'Since: cosmos-sdk 0.51' + title: proposal_type defines the type of the proposal + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED description: Proposal defines the core field members of a governance proposal. description: >- QueryProposalResponse is the response type for the Query/Proposal RPC @@ -52492,6 +52933,9 @@ definitions: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. submit_time: type: string format: date-time @@ -52546,12 +52990,25 @@ definitions: title: proposer is the address of the proposal sumbitter expedited: type: boolean - description: 'Since: cosmos-sdk 0.50' + description: |- + Since: cosmos-sdk 0.50 + Deprecated: Use ProposalType instead. title: expedited defines if the proposal is expedited failed_reason: type: string description: 'Since: cosmos-sdk 0.50' title: failed_reason defines the reason why the proposal failed + proposal_type: + description: 'Since: cosmos-sdk 0.51' + title: proposal_type defines the type of the proposal + type: string + enum: + - PROPOSAL_TYPE_UNSPECIFIED + - PROPOSAL_TYPE_STANDARD + - PROPOSAL_TYPE_MULTIPLE_CHOICE + - PROPOSAL_TYPE_OPTIMISTIC + - PROPOSAL_TYPE_EXPEDITED + default: PROPOSAL_TYPE_UNSPECIFIED description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: @@ -52597,6 +53054,9 @@ definitions: description: >- no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. @@ -52625,10 +53085,15 @@ definitions: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -52673,10 +53138,15 @@ definitions: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -52748,6 +53218,9 @@ definitions: no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. + spam_count: + type: string + description: spam_count is the number of spam votes on a proposal. description: TallyResult defines a standard tally for a governance proposal. cosmos.gov.v1.Vote: type: object @@ -52771,10 +53244,15 @@ definitions: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -52795,20 +53273,30 @@ definitions: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED description: >- VoteOption enumerates the valid vote options for a given governance proposal. - VOTE_OPTION_UNSPECIFIED: VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - - VOTE_OPTION_YES: VOTE_OPTION_YES defines a yes vote option. - - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines an abstain vote option. - - VOTE_OPTION_NO: VOTE_OPTION_NO defines a no vote option. - - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. + - VOTE_OPTION_ONE: VOTE_OPTION_ONE defines the first proposal vote option. + - VOTE_OPTION_YES: VOTE_OPTION_YES defines the yes proposal vote option. + - VOTE_OPTION_TWO: VOTE_OPTION_TWO defines the second proposal vote option. + - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines the abstain proposal vote option. + - VOTE_OPTION_THREE: VOTE_OPTION_THREE defines the third proposal vote option. + - VOTE_OPTION_NO: VOTE_OPTION_NO defines the no proposal vote option. + - VOTE_OPTION_FOUR: VOTE_OPTION_FOUR defines the fourth proposal vote option. + - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines the no with veto proposal vote option. + - VOTE_OPTION_SPAM: VOTE_OPTION_SPAM defines the spam proposal vote option. cosmos.gov.v1.VotingParams: type: object properties: @@ -52826,10 +53314,15 @@ definitions: type: string enum: - VOTE_OPTION_UNSPECIFIED + - VOTE_OPTION_ONE - VOTE_OPTION_YES + - VOTE_OPTION_TWO - VOTE_OPTION_ABSTAIN + - VOTE_OPTION_THREE - VOTE_OPTION_NO + - VOTE_OPTION_FOUR - VOTE_OPTION_NO_WITH_VETO + - VOTE_OPTION_SPAM default: VOTE_OPTION_UNSPECIFIED weight: type: string @@ -55060,8 +55553,8 @@ definitions: type: string format: uint64 title: >- - list of unbonding ids, each uniquely identifying an unbonding - of this validator + list of unbonding ids, each uniquely identifying an + unbonding of this validator description: >- Validator defines a validator, together with the total amount of the @@ -57597,23 +58090,28 @@ definitions: type: string description: >- if unset, the first signer is responsible for paying the fees. If - set, the specified account must pay the fees. + set, the - the payer must be a tx signer (and thus have signed this field in - AuthInfo). + specified account must pay the fees. the payer must be a tx signer + (and - setting this field does *not* change the ordering of required - signers for the transaction. + thus have signed this field in AuthInfo). setting this field does + *not* + + change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the - payer field) requests that a fee grant be used + payer + + field) requests that a fee grant be used to pay fees instead of + the fee - to pay fees instead of the fee payer's own balance. If an - appropriate fee grant does not exist or the chain does + payer's own balance. If an appropriate fee grant does not exist or + the - not support fee grants, this will fail + chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another @@ -58050,23 +58548,27 @@ definitions: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, - the specified account must pay the fees. + the + + specified account must pay the fees. the payer must be a tx signer + (and - the payer must be a tx signer (and thus have signed this field in - AuthInfo). + thus have signed this field in AuthInfo). setting this field does + *not* - setting this field does *not* change the ordering of required signers - for the transaction. + change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the - payer field) requests that a fee grant be used + payer + + field) requests that a fee grant be used to pay fees instead of the + fee - to pay fees instead of the fee payer's own balance. If an appropriate - fee grant does not exist or the chain does + payer's own balance. If an appropriate fee grant does not exist or the - not support fee grants, this will fail + chain does not support fee grants, this will fail description: >- Fee includes the amount of coins paid in fees and the maximum @@ -60297,13 +60799,48 @@ definitions: called memo, but should be called `note` instead (see + https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 - title: |- - timeout is the block height after which this transaction will not - be processed by the chain + description: >- + timeout_height is the block height after which this transaction + will not + + be processed by the chain. + + + Note, if unordered=true this value MUST be set + + and will act as a short-lived TTL in which the transaction is + deemed valid + + and kept in memory to prevent duplicates. + unordered: + type: boolean + description: >- + unordered, when set to true, indicates that the transaction + signer(s) + + intend for the transaction to be evaluated and executed in an + un-ordered + + fashion. Specifically, the account's nonce will NOT be checked or + + incremented, which allows for fire-and-forget as well as + concurrent + + transaction execution. + + + Note, when set to true, the existing 'timeout_height' value must + be set and + + will be used to correspond to a height in which the transaction is + deemed + + valid. extension_options: type: array items: @@ -60892,13 +61429,46 @@ definitions: memo, but should be called `note` instead (see + https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 - title: |- - timeout is the block height after which this transaction will not - be processed by the chain + description: >- + timeout_height is the block height after which this transaction will + not + + be processed by the chain. + + + Note, if unordered=true this value MUST be set + + and will act as a short-lived TTL in which the transaction is deemed + valid + + and kept in memory to prevent duplicates. + unordered: + type: boolean + description: >- + unordered, when set to true, indicates that the transaction signer(s) + + intend for the transaction to be evaluated and executed in an + un-ordered + + fashion. Specifically, the account's nonce will NOT be checked or + + incremented, which allows for fire-and-forget as well as concurrent + + transaction execution. + + + Note, when set to true, the existing 'timeout_height' value must be + set and + + will be used to correspond to a height in which the transaction is + deemed + + valid. extension_options: type: array items: @@ -63669,6 +64239,7 @@ definitions: type: string format: uint64 title: amount is the number of all NFTs of a given class owned by the owner + description: 'Since: nft v0.1.1' title: >- QueryBalanceByQueryStringResponse is the response type for the Query/Balance RPC method @@ -63883,6 +64454,7 @@ definitions: "value": "1.212s" } title: data is the app specific metadata of the NFT class. Optional + description: 'Since: nft v0.1.1' title: >- QueryClassByQueryStringResponse is the response type for the Query/Class RPC method @@ -64516,6 +65088,7 @@ definitions: } title: data is an app specific data of the NFT. Optional description: NFT defines the NFT. + description: 'Since: nft v0.1.1' title: >- QueryNFTByQueryStringResponse is the response type for the Query/NFT RPC method @@ -64940,6 +65513,7 @@ definitions: owner: type: string title: owner is the owner address of the nft + description: 'Since: nft v0.1.1' title: >- QueryOwnerByQueryStringResponse is the response type for the Query/Owner RPC method @@ -64957,6 +65531,7 @@ definitions: type: string format: uint64 title: amount is the number of all NFTs from the given class + description: 'Since: nft v0.1.1' title: >- QuerySupplyByQueryStringResponse is the response type for the Query/Supply RPC method diff --git a/proto/cosmos/bank/v1beta1/query.proto b/proto/cosmos/bank/v1beta1/query.proto index 87513f43f169..437b356c88ef 100644 --- a/proto/cosmos/bank/v1beta1/query.proto +++ b/proto/cosmos/bank/v1beta1/query.proto @@ -77,13 +77,13 @@ service Query { option (google.api.http).get = "/cosmos/bank/v1beta1/params"; } - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadata queries the client metadata of a given coin denomination. rpc DenomMetadata(QueryDenomMetadataRequest) returns (QueryDenomMetadataResponse) { option (cosmos.query.v1.module_query_safe) = true; option (google.api.http).get = "/cosmos/bank/v1beta1/denoms_metadata/{denom}"; } - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadataByQueryString queries the client metadata of a given coin denomination. rpc DenomMetadataByQueryString(QueryDenomMetadataByQueryStringRequest) returns (QueryDenomMetadataByQueryStringResponse) { option (cosmos.query.v1.module_query_safe) = true; @@ -108,6 +108,15 @@ service Query { option (google.api.http).get = "/cosmos/bank/v1beta1/denom_owners/{denom}"; } + // DenomOwnersByQuery queries for all account addresses that own a particular token + // denomination. + // + // Since: cosmos-sdk 0.50.3 + rpc DenomOwnersByQuery(QueryDenomOwnersByQueryRequest) returns (QueryDenomOwnersByQueryResponse) { + option (cosmos.query.v1.module_query_safe) = true; + option (google.api.http).get = "/cosmos/bank/v1beta1/denom_owners_by_query"; + } + // SendEnabled queries for SendEnabled entries. // // This query only returns denominations that have specific SendEnabled settings. @@ -354,6 +363,29 @@ message QueryDenomOwnersResponse { cosmos.base.query.v1beta1.PageResponse pagination = 2; } +// QueryDenomOwnersByQueryRequest defines the request type for the DenomOwnersByQuery RPC query, +// which queries for a paginated set of all account holders of a particular +// denomination. +// +// Since: cosmos-sdk 0.50.3 +message QueryDenomOwnersByQueryRequest { + // denom defines the coin denomination to query all account holders for. + string denom = 1; + + // pagination defines an optional pagination for the request. + cosmos.base.query.v1beta1.PageRequest pagination = 2; +} + +// QueryDenomOwnersByQueryResponse defines the RPC response of a DenomOwnersByQuery RPC query. +// +// Since: cosmos-sdk 0.50.3 +message QueryDenomOwnersByQueryResponse { + repeated DenomOwner denom_owners = 1; + + // pagination defines the pagination in the response. + cosmos.base.query.v1beta1.PageResponse pagination = 2; +} + // QuerySendEnabledRequest defines the RPC request for looking up SendEnabled entries. // // Since: cosmos-sdk 0.47 diff --git a/proto/cosmos/protocolpool/v1/tx.proto b/proto/cosmos/protocolpool/v1/tx.proto index 6461f9bca1af..b58185c2769f 100644 --- a/proto/cosmos/protocolpool/v1/tx.proto +++ b/proto/cosmos/protocolpool/v1/tx.proto @@ -173,4 +173,3 @@ message MsgWithdrawContinuousFundResponse { [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; ; } - diff --git a/x/bank/CHANGELOG.md b/x/bank/CHANGELOG.md index 85ad31d77969..818a5d55e123 100644 --- a/x/bank/CHANGELOG.md +++ b/x/bank/CHANGELOG.md @@ -27,6 +27,10 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Features +* [#18956](https://github.com/cosmos/cosmos-sdk/pull/18956) Introduced a new `DenomOwnersByQuery` query method + for `DenomOwners`, which accepts the denom value as a query string parameter, resolving issues with denoms containing + slashes. + ### Improvements ### API Breaking Changes diff --git a/x/bank/keeper/grpc_query.go b/x/bank/keeper/grpc_query.go index 14f0959ed504..c742c92eb028 100644 --- a/x/bank/keeper/grpc_query.go +++ b/x/bank/keeper/grpc_query.go @@ -219,18 +219,14 @@ func (k BaseKeeper) DenomMetadataByQueryString(ctx context.Context, req *types.Q return nil, status.Errorf(codes.InvalidArgument, "empty request") } - if err := sdk.ValidateDenom(req.Denom); err != nil { - return nil, status.Error(codes.InvalidArgument, err.Error()) - } - - metadata, found := k.GetDenomMetaData(ctx, req.Denom) - if !found { - return nil, status.Errorf(codes.NotFound, "client metadata for denom %s", req.Denom) + res, err := k.DenomMetadata(ctx, &types.QueryDenomMetadataRequest{ + Denom: req.Denom, + }) + if err != nil { + return nil, err } - return &types.QueryDenomMetadataByQueryStringResponse{ - Metadata: metadata, - }, nil + return &types.QueryDenomMetadataByQueryStringResponse{Metadata: res.Metadata}, nil } // DenomMetadataV2 is identical to DenomMetadata but receives protoreflect types instead of gogo types. It exists to @@ -274,8 +270,9 @@ func (k BaseKeeper) DenomMetadataV2(ctx context.Context, req *v1beta1.QueryDenom }, nil } +// DenomOwners returns all the account address that own a requested token denom. func (k BaseKeeper) DenomOwners( - goCtx context.Context, + ctx context.Context, req *types.QueryDenomOwnersRequest, ) (*types.QueryDenomOwnersResponse, error) { if req == nil { @@ -287,11 +284,11 @@ func (k BaseKeeper) DenomOwners( } denomOwners, pageRes, err := query.CollectionPaginate( - goCtx, + ctx, k.Balances.Indexes.Denom, req.Pagination, func(key collections.Pair[string, sdk.AccAddress], value collections.NoValue) (*types.DenomOwner, error) { - amt, err := k.Balances.Get(goCtx, collections.Join(key.K2(), req.Denom)) + amt, err := k.Balances.Get(ctx, collections.Join(key.K2(), req.Denom)) if err != nil { return nil, err } @@ -334,3 +331,19 @@ func (k BaseKeeper) SendEnabled(ctx context.Context, req *types.QuerySendEnabled return resp, nil } + +// DenomOwnersByQuery is identical to DenomOwner query, but receives denom values via query string. +func (k BaseKeeper) DenomOwnersByQuery(ctx context.Context, req *types.QueryDenomOwnersByQueryRequest) (*types.QueryDenomOwnersByQueryResponse, error) { + if req == nil { + return nil, status.Errorf(codes.InvalidArgument, "empty request") + } + resp, err := k.DenomOwners(ctx, &types.QueryDenomOwnersRequest{ + Denom: req.Denom, + Pagination: req.Pagination, + }) + if err != nil { + return nil, err + } + + return &types.QueryDenomOwnersByQueryResponse{DenomOwners: resp.DenomOwners, Pagination: resp.Pagination}, nil +} diff --git a/x/bank/keeper/grpc_query_test.go b/x/bank/keeper/grpc_query_test.go index 9c2de78fd997..a33d91903573 100644 --- a/x/bank/keeper/grpc_query_test.go +++ b/x/bank/keeper/grpc_query_test.go @@ -809,3 +809,111 @@ func (suite *KeeperTestSuite) TestQuerySendEnabled() { }) } } + +func (suite *KeeperTestSuite) TestGRPCDenomOwnersByQuery() { + ctx := suite.ctx + + keeper := suite.bankKeeper + + suite.mockMintCoins(mintAcc) + suite.Require().NoError(keeper.MintCoins(ctx, types.MintModuleName, initCoins)) + denom := "ibc/123123213123" + newCoins := sdk.NewCoins(sdk.NewCoin(denom, initTokens)) + suite.mockMintCoins(mintAcc) + suite.Require().NoError(keeper.MintCoins(ctx, types.MintModuleName, newCoins)) + + for i := 0; i < 10; i++ { + addr := sdk.AccAddress(fmt.Sprintf("account-%d", i)) + + bal := sdk.NewCoins(sdk.NewCoin( + sdk.DefaultBondDenom, + sdk.TokensFromConsensusPower(initialPower/10, sdk.DefaultPowerReduction), + )) + suite.mockSendCoinsFromModuleToAccount(mintAcc, addr) + suite.Require().NoError(keeper.SendCoinsFromModuleToAccount(ctx, types.MintModuleName, addr, bal)) + } + + testCases := map[string]struct { + req *types.QueryDenomOwnersByQueryRequest + expPass bool + numAddrs int + hasNext bool + total uint64 + }{ + "empty request": { + req: &types.QueryDenomOwnersByQueryRequest{}, + expPass: false, + }, + "invalid denom": { + req: &types.QueryDenomOwnersByQueryRequest{ + Denom: "foo", + }, + expPass: true, + numAddrs: 0, + hasNext: false, + total: 0, + }, + "valid request - page 1": { + req: &types.QueryDenomOwnersByQueryRequest{ + Denom: sdk.DefaultBondDenom, + Pagination: &query.PageRequest{ + Limit: 6, + CountTotal: true, + }, + }, + expPass: true, + numAddrs: 6, + hasNext: true, + total: 10, + }, + "valid request - page 2": { + req: &types.QueryDenomOwnersByQueryRequest{ + Denom: sdk.DefaultBondDenom, + Pagination: &query.PageRequest{ + Offset: 6, + Limit: 10, + CountTotal: true, + }, + }, + expPass: true, + numAddrs: 4, + hasNext: false, + total: 10, + }, + "valid request for query": { + req: &types.QueryDenomOwnersByQueryRequest{ + Denom: denom, + Pagination: &query.PageRequest{ + Limit: 6, + CountTotal: true, + }, + }, + expPass: true, + numAddrs: 1, + hasNext: false, + total: 1, + }, + } + + for name, tc := range testCases { + suite.Run(name, func() { + resp, err := suite.queryClient.DenomOwnersByQuery(gocontext.Background(), tc.req) + if tc.expPass { + suite.NoError(err) + suite.NotNil(resp) + suite.Len(resp.DenomOwners, tc.numAddrs) + suite.Equal(tc.total, resp.Pagination.Total) + + if tc.hasNext { + suite.NotNil(resp.Pagination.NextKey) + } else { + suite.Nil(resp.Pagination.NextKey) + } + } else { + suite.Require().Error(err) + } + }) + } + + suite.Require().True(true) +} diff --git a/x/bank/types/query.pb.go b/x/bank/types/query.pb.go index 2407ffb87935..10d323af9a24 100644 --- a/x/bank/types/query.pb.go +++ b/x/bank/types/query.pb.go @@ -1157,6 +1157,121 @@ func (m *QueryDenomOwnersResponse) GetPagination() *query.PageResponse { return nil } +// QueryDenomOwnersByQueryRequest defines the request type for the DenomOwnersByQuery RPC query, +// which queries for a paginated set of all account holders of a particular +// denomination. +// +// Since: cosmos-sdk 0.50.3 +type QueryDenomOwnersByQueryRequest struct { + // denom defines the coin denomination to query all account holders for. + Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"` + // pagination defines an optional pagination for the request. + Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (m *QueryDenomOwnersByQueryRequest) Reset() { *m = QueryDenomOwnersByQueryRequest{} } +func (m *QueryDenomOwnersByQueryRequest) String() string { return proto.CompactTextString(m) } +func (*QueryDenomOwnersByQueryRequest) ProtoMessage() {} +func (*QueryDenomOwnersByQueryRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_9c6fc1939682df13, []int{23} +} +func (m *QueryDenomOwnersByQueryRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryDenomOwnersByQueryRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryDenomOwnersByQueryRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryDenomOwnersByQueryRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryDenomOwnersByQueryRequest.Merge(m, src) +} +func (m *QueryDenomOwnersByQueryRequest) XXX_Size() int { + return m.Size() +} +func (m *QueryDenomOwnersByQueryRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QueryDenomOwnersByQueryRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryDenomOwnersByQueryRequest proto.InternalMessageInfo + +func (m *QueryDenomOwnersByQueryRequest) GetDenom() string { + if m != nil { + return m.Denom + } + return "" +} + +func (m *QueryDenomOwnersByQueryRequest) GetPagination() *query.PageRequest { + if m != nil { + return m.Pagination + } + return nil +} + +// QueryDenomOwnersByQueryResponse defines the RPC response of a DenomOwnersByQuery RPC query. +// +// Since: cosmos-sdk 0.50.3 +type QueryDenomOwnersByQueryResponse struct { + DenomOwners []*DenomOwner `protobuf:"bytes,1,rep,name=denom_owners,json=denomOwners,proto3" json:"denom_owners,omitempty"` + // pagination defines the pagination in the response. + Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (m *QueryDenomOwnersByQueryResponse) Reset() { *m = QueryDenomOwnersByQueryResponse{} } +func (m *QueryDenomOwnersByQueryResponse) String() string { return proto.CompactTextString(m) } +func (*QueryDenomOwnersByQueryResponse) ProtoMessage() {} +func (*QueryDenomOwnersByQueryResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_9c6fc1939682df13, []int{24} +} +func (m *QueryDenomOwnersByQueryResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryDenomOwnersByQueryResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryDenomOwnersByQueryResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryDenomOwnersByQueryResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryDenomOwnersByQueryResponse.Merge(m, src) +} +func (m *QueryDenomOwnersByQueryResponse) XXX_Size() int { + return m.Size() +} +func (m *QueryDenomOwnersByQueryResponse) XXX_DiscardUnknown() { + xxx_messageInfo_QueryDenomOwnersByQueryResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryDenomOwnersByQueryResponse proto.InternalMessageInfo + +func (m *QueryDenomOwnersByQueryResponse) GetDenomOwners() []*DenomOwner { + if m != nil { + return m.DenomOwners + } + return nil +} + +func (m *QueryDenomOwnersByQueryResponse) GetPagination() *query.PageResponse { + if m != nil { + return m.Pagination + } + return nil +} + // QuerySendEnabledRequest defines the RPC request for looking up SendEnabled entries. // // Since: cosmos-sdk 0.47 @@ -1172,7 +1287,7 @@ func (m *QuerySendEnabledRequest) Reset() { *m = QuerySendEnabledRequest func (m *QuerySendEnabledRequest) String() string { return proto.CompactTextString(m) } func (*QuerySendEnabledRequest) ProtoMessage() {} func (*QuerySendEnabledRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_9c6fc1939682df13, []int{23} + return fileDescriptor_9c6fc1939682df13, []int{25} } func (m *QuerySendEnabledRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1229,7 +1344,7 @@ func (m *QuerySendEnabledResponse) Reset() { *m = QuerySendEnabledRespon func (m *QuerySendEnabledResponse) String() string { return proto.CompactTextString(m) } func (*QuerySendEnabledResponse) ProtoMessage() {} func (*QuerySendEnabledResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9c6fc1939682df13, []int{24} + return fileDescriptor_9c6fc1939682df13, []int{26} } func (m *QuerySendEnabledResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1296,6 +1411,8 @@ func init() { proto.RegisterType((*QueryDenomOwnersRequest)(nil), "cosmos.bank.v1beta1.QueryDenomOwnersRequest") proto.RegisterType((*DenomOwner)(nil), "cosmos.bank.v1beta1.DenomOwner") proto.RegisterType((*QueryDenomOwnersResponse)(nil), "cosmos.bank.v1beta1.QueryDenomOwnersResponse") + proto.RegisterType((*QueryDenomOwnersByQueryRequest)(nil), "cosmos.bank.v1beta1.QueryDenomOwnersByQueryRequest") + proto.RegisterType((*QueryDenomOwnersByQueryResponse)(nil), "cosmos.bank.v1beta1.QueryDenomOwnersByQueryResponse") proto.RegisterType((*QuerySendEnabledRequest)(nil), "cosmos.bank.v1beta1.QuerySendEnabledRequest") proto.RegisterType((*QuerySendEnabledResponse)(nil), "cosmos.bank.v1beta1.QuerySendEnabledResponse") } @@ -1303,88 +1420,91 @@ func init() { func init() { proto.RegisterFile("cosmos/bank/v1beta1/query.proto", fileDescriptor_9c6fc1939682df13) } var fileDescriptor_9c6fc1939682df13 = []byte{ - // 1287 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x58, 0x41, 0x6f, 0x1b, 0x45, - 0x14, 0xf6, 0xb4, 0xaa, 0x9b, 0x3c, 0xa7, 0x88, 0x4e, 0x03, 0x4d, 0x36, 0xc4, 0x0e, 0x9b, 0x2a, - 0x71, 0x42, 0xb2, 0xdb, 0x38, 0x55, 0x45, 0x4b, 0x88, 0x14, 0xb7, 0xa4, 0x07, 0x84, 0x5a, 0x1c, - 0x7a, 0x81, 0x83, 0xb5, 0xf6, 0x0e, 0xc6, 0x8a, 0xbd, 0xe3, 0x7a, 0x36, 0x2d, 0x56, 0x15, 0x09, - 0x21, 0x21, 0xf5, 0x06, 0x12, 0x3d, 0x55, 0x42, 0x8a, 0x90, 0x80, 0x0a, 0x24, 0xd4, 0x03, 0x47, - 0x8e, 0x1c, 0x7a, 0xac, 0xe0, 0x00, 0xe2, 0x50, 0x50, 0x82, 0xd4, 0xfe, 0x0c, 0xe4, 0x99, 0x59, - 0xef, 0xae, 0x3d, 0xde, 0x6c, 0x52, 0x83, 0x10, 0x97, 0xc4, 0x9e, 0x79, 0x6f, 0xde, 0xf7, 0xbe, - 0xf7, 0xf6, 0xcd, 0xb7, 0x86, 0x4c, 0x99, 0xb2, 0x3a, 0x65, 0x66, 0xc9, 0x72, 0x36, 0xcd, 0x9b, - 0x4b, 0x25, 0xe2, 0x5a, 0x4b, 0xe6, 0x8d, 0x2d, 0xd2, 0x6c, 0x19, 0x8d, 0x26, 0x75, 0x29, 0x3e, - 0x25, 0x0c, 0x8c, 0xb6, 0x81, 0x21, 0x0d, 0xb4, 0xf9, 0x8e, 0x17, 0x23, 0xc2, 0xba, 0xe3, 0xdb, - 0xb0, 0x2a, 0x55, 0xc7, 0x72, 0xab, 0xd4, 0x11, 0x07, 0x68, 0xa3, 0x15, 0x5a, 0xa1, 0xfc, 0xa3, - 0xd9, 0xfe, 0x24, 0x57, 0x5f, 0xaa, 0x50, 0x5a, 0xa9, 0x11, 0xd3, 0x6a, 0x54, 0x4d, 0xcb, 0x71, - 0xa8, 0xcb, 0x5d, 0x98, 0xdc, 0x4d, 0x07, 0xcf, 0xf7, 0x4e, 0x2e, 0xd3, 0xaa, 0xd3, 0xb3, 0x1f, - 0x40, 0xcd, 0x11, 0x8a, 0xfd, 0x71, 0xb1, 0x5f, 0x14, 0x61, 0x65, 0x06, 0x62, 0x6b, 0x42, 0xba, - 0x7a, 0xa8, 0x83, 0xc9, 0x6a, 0x27, 0xad, 0x7a, 0xd5, 0xa1, 0x26, 0xff, 0x2b, 0x96, 0xf4, 0x2a, - 0x9c, 0x7a, 0xbb, 0x6d, 0x91, 0xb7, 0x6a, 0x96, 0x53, 0x26, 0x05, 0x72, 0x63, 0x8b, 0x30, 0x17, - 0xe7, 0xe0, 0xb8, 0x65, 0xdb, 0x4d, 0xc2, 0xd8, 0x18, 0x9a, 0x42, 0xd9, 0xe1, 0xfc, 0xd8, 0xcf, - 0x3f, 0x2c, 0x8e, 0xca, 0x48, 0x6b, 0x62, 0x67, 0xc3, 0x6d, 0x56, 0x9d, 0x4a, 0xc1, 0x33, 0xc4, - 0xa3, 0x70, 0xcc, 0x26, 0x0e, 0xad, 0x8f, 0x1d, 0x69, 0x7b, 0x14, 0xc4, 0x97, 0x8b, 0x43, 0x77, - 0x76, 0x32, 0x89, 0xa7, 0x3b, 0x99, 0x84, 0xfe, 0x26, 0x8c, 0x86, 0x43, 0xb1, 0x06, 0x75, 0x18, - 0xc1, 0xcb, 0x70, 0xbc, 0x24, 0x96, 0x78, 0xac, 0x54, 0x6e, 0xdc, 0xe8, 0x14, 0x85, 0x11, 0xaf, - 0x28, 0xc6, 0x25, 0x5a, 0x75, 0x0a, 0x9e, 0xa5, 0xfe, 0x13, 0x82, 0xd3, 0xfc, 0xb4, 0xb5, 0x5a, - 0x4d, 0x1e, 0xc8, 0x9e, 0x05, 0xfc, 0x3a, 0x80, 0x5f, 0x5a, 0x9e, 0x41, 0x2a, 0x37, 0x13, 0xc2, - 0x21, 0x88, 0xf4, 0xd0, 0x5c, 0xb3, 0x2a, 0x1e, 0x59, 0x85, 0x80, 0x27, 0x9e, 0x86, 0x13, 0x4d, - 0xc2, 0x68, 0xed, 0x26, 0x29, 0x0a, 0x32, 0x8e, 0x4e, 0xa1, 0xec, 0x50, 0x61, 0x44, 0x2e, 0x5e, - 0xee, 0xe2, 0x64, 0x17, 0xc1, 0x58, 0x6f, 0x1a, 0x92, 0x98, 0x6d, 0x18, 0x92, 0xe9, 0xb6, 0x13, - 0x39, 0x1a, 0xc9, 0x4c, 0x7e, 0xfd, 0xe1, 0xe3, 0x4c, 0xe2, 0xdb, 0x3f, 0x32, 0xd9, 0x4a, 0xd5, - 0xfd, 0x60, 0xab, 0x64, 0x94, 0x69, 0x5d, 0x76, 0x86, 0xfc, 0xb7, 0xc8, 0xec, 0x4d, 0xd3, 0x6d, - 0x35, 0x08, 0xe3, 0x0e, 0xec, 0xde, 0x93, 0x07, 0xf3, 0x23, 0x35, 0x52, 0xb1, 0xca, 0xad, 0x62, - 0xbb, 0xf7, 0xd8, 0xfd, 0x27, 0x0f, 0xe6, 0x51, 0xa1, 0x13, 0x12, 0x5f, 0x51, 0x50, 0x32, 0xbb, - 0x2f, 0x25, 0x02, 0x7b, 0x90, 0x13, 0xfd, 0x2b, 0x04, 0x93, 0x3c, 0xc9, 0x8d, 0x06, 0x71, 0x6c, - 0xab, 0x54, 0x23, 0xff, 0xa1, 0x8a, 0x05, 0x8a, 0xf1, 0x14, 0x41, 0xba, 0x1f, 0xce, 0xff, 0x59, - 0x49, 0x5a, 0x30, 0xad, 0xcc, 0x34, 0xdf, 0xe2, 0x1d, 0xfa, 0x4f, 0x8e, 0x81, 0xf7, 0xe0, 0x4c, - 0x74, 0xe8, 0x67, 0x19, 0x0b, 0x9b, 0x72, 0x2a, 0xbc, 0x43, 0x5d, 0xab, 0xb6, 0xb1, 0xd5, 0x68, - 0xd4, 0x5a, 0x5e, 0x2e, 0xe1, 0x7e, 0x41, 0x03, 0xe8, 0x97, 0xc7, 0xde, 0xc3, 0x1b, 0x8a, 0x26, - 0xe1, 0xb7, 0x20, 0xc9, 0xf8, 0xca, 0xbf, 0xd7, 0x27, 0x32, 0xe0, 0xe0, 0xba, 0x64, 0x41, 0x4e, - 0x6c, 0x91, 0xda, 0xd5, 0xf7, 0x3d, 0x2a, 0x3b, 0x25, 0x46, 0x81, 0x12, 0xeb, 0xd7, 0xe1, 0x85, - 0x2e, 0x6b, 0x49, 0xc5, 0x0a, 0x24, 0xad, 0x3a, 0xdd, 0x72, 0xdc, 0x7d, 0x0b, 0x99, 0x1f, 0x6e, - 0x53, 0x21, 0xb3, 0x11, 0x3e, 0xfa, 0x28, 0x60, 0x7e, 0xec, 0x35, 0xab, 0x69, 0xd5, 0xbd, 0x89, - 0xa1, 0x5f, 0x97, 0xf7, 0x96, 0xb7, 0x2a, 0x43, 0xad, 0x42, 0xb2, 0xc1, 0x57, 0x64, 0xa8, 0x09, - 0x43, 0x71, 0xbf, 0x1b, 0xc2, 0x29, 0x14, 0x4c, 0x78, 0xe9, 0x36, 0x68, 0xfc, 0x58, 0xde, 0x8a, - 0xec, 0x2d, 0xe2, 0x5a, 0xb6, 0xe5, 0x5a, 0x03, 0x6e, 0x21, 0xfd, 0x7b, 0x04, 0x13, 0xca, 0x30, - 0x32, 0x8b, 0x75, 0x18, 0xae, 0xcb, 0x35, 0x6f, 0xcc, 0x4c, 0x2a, 0x13, 0xf1, 0x3c, 0x83, 0xa9, - 0xf8, 0xae, 0x83, 0x6b, 0x84, 0x25, 0x18, 0xf7, 0xf1, 0x76, 0xb3, 0xa2, 0xee, 0x86, 0x52, 0x90, - 0xc9, 0x9e, 0x0c, 0x2f, 0xc3, 0x90, 0x07, 0x53, 0xf2, 0x18, 0x3f, 0xc1, 0x8e, 0xa7, 0xbe, 0x0a, - 0x33, 0xbd, 0x31, 0xf2, 0x2d, 0xd1, 0x85, 0x62, 0x2c, 0x45, 0x62, 0xa4, 0x30, 0xbb, 0xaf, 0xff, - 0x40, 0x01, 0xdf, 0x92, 0xe3, 0x89, 0x07, 0xbc, 0x7a, 0xcb, 0x21, 0x4d, 0x16, 0x89, 0x70, 0x50, - 0x97, 0x9c, 0xfe, 0x11, 0x02, 0xf0, 0x83, 0x1e, 0x6a, 0xae, 0xaf, 0xfa, 0xf3, 0xf8, 0xc8, 0x01, - 0x1e, 0xe3, 0xce, 0x68, 0xfe, 0xc6, 0x9b, 0x96, 0xa1, 0xe4, 0x25, 0xbd, 0x79, 0x18, 0xe1, 0x09, - 0x17, 0x29, 0x5f, 0x97, 0x4d, 0x9f, 0x51, 0x52, 0xec, 0xfb, 0x17, 0x52, 0xb6, 0x7f, 0xd6, 0x20, - 0x2f, 0x47, 0x51, 0xa5, 0x0d, 0xe2, 0xd8, 0x6f, 0x38, 0xed, 0x2b, 0xca, 0xf6, 0xaa, 0xf4, 0x22, - 0x24, 0x79, 0x48, 0x81, 0x70, 0xb8, 0x20, 0xbf, 0x75, 0xd5, 0xa9, 0x7c, 0xe8, 0x3a, 0xdd, 0xf7, - 0x48, 0x0a, 0xc5, 0x96, 0x24, 0x5d, 0x82, 0x11, 0x46, 0x1c, 0xbb, 0x48, 0xc4, 0xba, 0x24, 0x69, - 0x4a, 0x49, 0x52, 0xd0, 0x3f, 0xc5, 0xfc, 0x2f, 0x5d, 0x2c, 0x95, 0x0f, 0xcd, 0x52, 0xee, 0xd3, - 0xe7, 0xe1, 0x18, 0x87, 0x8a, 0xbf, 0x40, 0x70, 0x5c, 0x5e, 0xe2, 0x38, 0xab, 0x44, 0xa3, 0x78, - 0xc5, 0xd0, 0xe6, 0x62, 0x58, 0x8a, 0xb0, 0xfa, 0xeb, 0x77, 0xda, 0xad, 0xf4, 0xf1, 0x2f, 0x7f, - 0x7d, 0x7e, 0x24, 0x87, 0xcf, 0x9a, 0xea, 0xb7, 0x23, 0x21, 0x91, 0xcc, 0xdb, 0xb2, 0x5f, 0xb7, - 0xcd, 0x52, 0x4b, 0x48, 0x70, 0xbc, 0x83, 0x20, 0x15, 0xd0, 0xd7, 0x78, 0xa1, 0x7f, 0xe4, 0xde, - 0xb7, 0x09, 0x6d, 0x31, 0xa6, 0xb5, 0xc4, 0x7a, 0xce, 0xc7, 0x3a, 0x87, 0x67, 0x63, 0x62, 0xc5, - 0x3f, 0x22, 0x38, 0xd9, 0xa3, 0x3a, 0x71, 0xae, 0x7f, 0xe8, 0x7e, 0x52, 0x5a, 0x5b, 0x3e, 0x90, - 0x8f, 0x04, 0xbd, 0xea, 0x83, 0x5e, 0xc6, 0x4b, 0x4a, 0xd0, 0xcc, 0x73, 0x2e, 0x2a, 0xe0, 0xff, - 0x8a, 0xe0, 0x74, 0x1f, 0x3d, 0x87, 0x5f, 0x8d, 0x0f, 0x28, 0xac, 0x3e, 0xb5, 0x0b, 0x87, 0xf0, - 0x94, 0x09, 0x5d, 0xf1, 0x13, 0x5a, 0xc1, 0x17, 0x0f, 0x9c, 0x90, 0xdf, 0x3b, 0x77, 0x11, 0xa4, - 0x02, 0xf2, 0x2e, 0xaa, 0x77, 0x7a, 0x35, 0x67, 0x54, 0xef, 0x28, 0x34, 0xa3, 0x9e, 0xf5, 0x51, - 0x4f, 0xe2, 0x09, 0x35, 0x6a, 0x01, 0xe3, 0x2e, 0x82, 0x21, 0x4f, 0x67, 0xe1, 0x88, 0x27, 0xa9, - 0x4b, 0xb9, 0x69, 0xf3, 0x71, 0x4c, 0x25, 0x9a, 0x25, 0x1f, 0xcd, 0x0c, 0x3e, 0x13, 0x81, 0xc6, - 0x67, 0xeb, 0x13, 0x04, 0x49, 0x21, 0xae, 0xf0, 0x6c, 0xff, 0x48, 0x21, 0x25, 0xa7, 0x65, 0xf7, - 0x37, 0x8c, 0x4f, 0x8f, 0x90, 0x71, 0xf8, 0x3b, 0x04, 0x27, 0x42, 0x97, 0x3a, 0x36, 0xfa, 0x47, - 0x51, 0x89, 0x1a, 0xcd, 0x8c, 0x6d, 0x2f, 0xc1, 0x5d, 0xf0, 0xc1, 0x19, 0x78, 0x41, 0x09, 0x4e, - 0xdc, 0x15, 0x45, 0x4f, 0x0d, 0x98, 0xb7, 0xf9, 0xc2, 0x36, 0xfe, 0x1d, 0x81, 0xd6, 0x5f, 0x82, - 0xe0, 0xd7, 0x62, 0x42, 0x51, 0x09, 0x1f, 0x6d, 0xe5, 0x70, 0xce, 0x32, 0xa9, 0x35, 0x3f, 0xa9, - 0xf3, 0xf8, 0x5c, 0x9c, 0xa4, 0x8a, 0xa5, 0x56, 0x91, 0x5f, 0x20, 0x45, 0x26, 0xd0, 0x7f, 0x8d, - 0xe0, 0xb9, 0xb0, 0xcc, 0xc5, 0xfb, 0x71, 0xdb, 0xad, 0xbb, 0xb5, 0xb3, 0xf1, 0x1d, 0xe2, 0xf7, - 0x6e, 0x17, 0x70, 0xfc, 0x25, 0x82, 0x54, 0x40, 0x9a, 0x44, 0x3d, 0xe9, 0xbd, 0xf2, 0x2d, 0xea, - 0x49, 0x57, 0xe8, 0x1d, 0xfd, 0xbc, 0x8f, 0xef, 0x15, 0x3c, 0xd7, 0x1f, 0x9f, 0xd4, 0x43, 0x9d, - 0x56, 0xb9, 0x87, 0x20, 0x15, 0xb8, 0xda, 0xa3, 0x40, 0xf6, 0xaa, 0x97, 0x28, 0x90, 0x0a, 0xbd, - 0xa1, 0x1b, 0x3e, 0xc8, 0x69, 0xfc, 0xb2, 0x7a, 0x00, 0x04, 0xf4, 0x48, 0x7e, 0xf9, 0xe1, 0x6e, - 0x1a, 0x3d, 0xda, 0x4d, 0xa3, 0x3f, 0x77, 0xd3, 0xe8, 0xb3, 0xbd, 0x74, 0xe2, 0xd1, 0x5e, 0x3a, - 0xf1, 0xdb, 0x5e, 0x3a, 0xf1, 0xae, 0xfc, 0xc1, 0x92, 0xd9, 0x9b, 0x46, 0x95, 0x9a, 0x1f, 0x8a, - 0x33, 0xf8, 0x0b, 0x6d, 0x29, 0xc9, 0x7f, 0x87, 0x5c, 0xfe, 0x3b, 0x00, 0x00, 0xff, 0xff, 0xcd, - 0x75, 0xea, 0xc7, 0xaa, 0x15, 0x00, 0x00, + // 1341 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x58, 0xc1, 0x6f, 0x1b, 0xc5, + 0x17, 0xf6, 0xb4, 0xaa, 0x9b, 0x3c, 0xa7, 0x3f, 0x29, 0xd3, 0xfc, 0x68, 0xb2, 0x21, 0x76, 0xd8, + 0x54, 0x89, 0x13, 0x92, 0xdd, 0xc6, 0x8e, 0x0a, 0x2d, 0x21, 0x52, 0xdc, 0x92, 0x1e, 0x10, 0x6a, + 0x71, 0xe8, 0x05, 0x0e, 0xd6, 0xda, 0xbb, 0x18, 0x2b, 0xf6, 0xae, 0xeb, 0xd9, 0xb4, 0x58, 0x55, + 0x10, 0x42, 0x42, 0xea, 0x11, 0x89, 0x9e, 0x2a, 0x21, 0x45, 0x48, 0x40, 0x05, 0x52, 0xd5, 0x03, + 0x07, 0x0e, 0x1c, 0x39, 0x54, 0x9c, 0x2a, 0x38, 0x80, 0x38, 0x14, 0x94, 0x20, 0xb5, 0x7f, 0x06, + 0xf2, 0xcc, 0x5b, 0xef, 0xae, 0xbd, 0x5e, 0x6f, 0x52, 0x53, 0x55, 0x5c, 0x12, 0x7b, 0xe6, 0xbd, + 0x79, 0xdf, 0xfb, 0xe6, 0xcd, 0x9b, 0x6f, 0x0c, 0xa9, 0x92, 0xc5, 0x6a, 0x16, 0x53, 0x8b, 0x9a, + 0xb9, 0xa5, 0x5e, 0x5f, 0x2e, 0x1a, 0xb6, 0xb6, 0xac, 0x5e, 0xdb, 0x36, 0x1a, 0x4d, 0xa5, 0xde, + 0xb0, 0x6c, 0x8b, 0x9e, 0x14, 0x06, 0x4a, 0xcb, 0x40, 0x41, 0x03, 0x69, 0xa1, 0xed, 0xc5, 0x0c, + 0x61, 0xdd, 0xf6, 0xad, 0x6b, 0xe5, 0x8a, 0xa9, 0xd9, 0x15, 0xcb, 0x14, 0x0b, 0x48, 0x63, 0x65, + 0xab, 0x6c, 0xf1, 0x8f, 0x6a, 0xeb, 0x13, 0x8e, 0xbe, 0x58, 0xb6, 0xac, 0x72, 0xd5, 0x50, 0xb5, + 0x7a, 0x45, 0xd5, 0x4c, 0xd3, 0xb2, 0xb9, 0x0b, 0xc3, 0xd9, 0xa4, 0x77, 0x7d, 0x67, 0xe5, 0x92, + 0x55, 0x31, 0xbb, 0xe6, 0x3d, 0xa8, 0x39, 0x42, 0x31, 0x3f, 0x21, 0xe6, 0x0b, 0x22, 0x2c, 0x66, + 0x20, 0xa6, 0x26, 0xd1, 0xd5, 0x41, 0xed, 0x4d, 0x56, 0x1a, 0xd5, 0x6a, 0x15, 0xd3, 0x52, 0xf9, + 0x5f, 0x31, 0x24, 0x57, 0xe0, 0xe4, 0xdb, 0x2d, 0x8b, 0x9c, 0x56, 0xd5, 0xcc, 0x92, 0x91, 0x37, + 0xae, 0x6d, 0x1b, 0xcc, 0xa6, 0x19, 0x38, 0xae, 0xe9, 0x7a, 0xc3, 0x60, 0x6c, 0x9c, 0x4c, 0x93, + 0xf4, 0x70, 0x6e, 0xfc, 0x97, 0xef, 0x97, 0xc6, 0x30, 0xd2, 0xba, 0x98, 0xd9, 0xb4, 0x1b, 0x15, + 0xb3, 0x9c, 0x77, 0x0c, 0xe9, 0x18, 0x1c, 0xd3, 0x0d, 0xd3, 0xaa, 0x8d, 0x1f, 0x69, 0x79, 0xe4, + 0xc5, 0x97, 0xf3, 0x43, 0xb7, 0x76, 0x53, 0xb1, 0x27, 0xbb, 0xa9, 0x98, 0xfc, 0x26, 0x8c, 0xf9, + 0x43, 0xb1, 0xba, 0x65, 0x32, 0x83, 0x66, 0xe1, 0x78, 0x51, 0x0c, 0xf1, 0x58, 0x89, 0xcc, 0x84, + 0xd2, 0xde, 0x14, 0x66, 0x38, 0x9b, 0xa2, 0x5c, 0xb0, 0x2a, 0x66, 0xde, 0xb1, 0x94, 0x7f, 0x22, + 0x70, 0x8a, 0xaf, 0xb6, 0x5e, 0xad, 0xe2, 0x82, 0xec, 0x69, 0xc0, 0x6f, 0x00, 0xb8, 0x5b, 0xcb, + 0x33, 0x48, 0x64, 0x66, 0x7d, 0x38, 0x04, 0x91, 0x0e, 0x9a, 0x2b, 0x5a, 0xd9, 0x21, 0x2b, 0xef, + 0xf1, 0xa4, 0x33, 0x70, 0xa2, 0x61, 0x30, 0xab, 0x7a, 0xdd, 0x28, 0x08, 0x32, 0x8e, 0x4e, 0x93, + 0xf4, 0x50, 0x7e, 0x04, 0x07, 0x2f, 0x76, 0x70, 0xb2, 0x47, 0x60, 0xbc, 0x3b, 0x0d, 0x24, 0x66, + 0x07, 0x86, 0x30, 0xdd, 0x56, 0x22, 0x47, 0x43, 0x99, 0xc9, 0x6d, 0x3c, 0x78, 0x94, 0x8a, 0x7d, + 0xfb, 0x67, 0x2a, 0x5d, 0xae, 0xd8, 0x1f, 0x6c, 0x17, 0x95, 0x92, 0x55, 0xc3, 0xca, 0xc0, 0x7f, + 0x4b, 0x4c, 0xdf, 0x52, 0xed, 0x66, 0xdd, 0x60, 0xdc, 0x81, 0xdd, 0x79, 0x7c, 0x7f, 0x61, 0xa4, + 0x6a, 0x94, 0xb5, 0x52, 0xb3, 0xd0, 0xaa, 0x3d, 0x76, 0xf7, 0xf1, 0xfd, 0x05, 0x92, 0x6f, 0x87, + 0xa4, 0x97, 0x02, 0x28, 0x99, 0xeb, 0x4b, 0x89, 0xc0, 0xee, 0xe5, 0x44, 0xfe, 0x8a, 0xc0, 0x14, + 0x4f, 0x72, 0xb3, 0x6e, 0x98, 0xba, 0x56, 0xac, 0x1a, 0xcf, 0xd1, 0x8e, 0x79, 0x36, 0xe3, 0x09, + 0x81, 0x64, 0x2f, 0x9c, 0xff, 0xb1, 0x2d, 0x69, 0xc2, 0x4c, 0x60, 0xa6, 0xb9, 0x26, 0xaf, 0xd0, + 0x7f, 0xb3, 0x0d, 0xbc, 0x07, 0xa7, 0xc3, 0x43, 0x3f, 0x4d, 0x5b, 0xd8, 0xc2, 0xae, 0xf0, 0x8e, + 0x65, 0x6b, 0xd5, 0xcd, 0xed, 0x7a, 0xbd, 0xda, 0x74, 0x72, 0xf1, 0xd7, 0x0b, 0x19, 0x40, 0xbd, + 0x3c, 0x72, 0x0e, 0xaf, 0x2f, 0x1a, 0xc2, 0x6f, 0x42, 0x9c, 0xf1, 0x91, 0x67, 0x57, 0x27, 0x18, + 0x70, 0x70, 0x55, 0xb2, 0x88, 0x1d, 0x5b, 0xa4, 0x76, 0xf9, 0x7d, 0x87, 0xca, 0xf6, 0x16, 0x13, + 0xcf, 0x16, 0xcb, 0x57, 0xe1, 0xff, 0x1d, 0xd6, 0x48, 0xc5, 0x2a, 0xc4, 0xb5, 0x9a, 0xb5, 0x6d, + 0xda, 0x7d, 0x37, 0x32, 0x37, 0xdc, 0xa2, 0x02, 0xb3, 0x11, 0x3e, 0xf2, 0x18, 0x50, 0xbe, 0xec, + 0x15, 0xad, 0xa1, 0xd5, 0x9c, 0x8e, 0x21, 0x5f, 0xc5, 0x7b, 0xcb, 0x19, 0xc5, 0x50, 0x6b, 0x10, + 0xaf, 0xf3, 0x11, 0x0c, 0x35, 0xa9, 0x04, 0xdc, 0xef, 0x8a, 0x70, 0xf2, 0x05, 0x13, 0x5e, 0xb2, + 0x0e, 0x12, 0x5f, 0x96, 0x97, 0x22, 0x7b, 0xcb, 0xb0, 0x35, 0x5d, 0xb3, 0xb5, 0x01, 0x97, 0x90, + 0x7c, 0x8f, 0xc0, 0x64, 0x60, 0x18, 0xcc, 0x62, 0x03, 0x86, 0x6b, 0x38, 0xe6, 0xb4, 0x99, 0xa9, + 0xc0, 0x44, 0x1c, 0x4f, 0x6f, 0x2a, 0xae, 0xeb, 0xe0, 0x0a, 0x61, 0x19, 0x26, 0x5c, 0xbc, 0x9d, + 0xac, 0x04, 0x57, 0x43, 0xd1, 0xcb, 0x64, 0x57, 0x86, 0x17, 0x61, 0xc8, 0x81, 0x89, 0x3c, 0x46, + 0x4f, 0xb0, 0xed, 0x29, 0xaf, 0xc1, 0x6c, 0x77, 0x8c, 0x5c, 0x53, 0x54, 0xa1, 0x68, 0x4b, 0xa1, + 0x18, 0x2d, 0x98, 0xeb, 0xeb, 0x3f, 0x50, 0xc0, 0x37, 0xb0, 0x3d, 0xf1, 0x80, 0x97, 0x6f, 0x98, + 0x46, 0x83, 0x85, 0x22, 0x1c, 0xd4, 0x25, 0x27, 0x7f, 0x4c, 0x00, 0xdc, 0xa0, 0x87, 0xea, 0xeb, + 0x6b, 0x6e, 0x3f, 0x3e, 0x72, 0x80, 0x63, 0xdc, 0x6e, 0xcd, 0xdf, 0x38, 0xdd, 0xd2, 0x97, 0x3c, + 0xd2, 0x9b, 0x83, 0x11, 0x9e, 0x70, 0xc1, 0xe2, 0xe3, 0x58, 0xf4, 0xa9, 0x40, 0x8a, 0x5d, 0xff, + 0x7c, 0x42, 0x77, 0xd7, 0x1a, 0x5c, 0xb5, 0x7f, 0x84, 0x32, 0xc0, 0x03, 0x14, 0x8b, 0xe2, 0xd9, + 0x6c, 0xd6, 0x3d, 0x02, 0xa9, 0x9e, 0x00, 0x9e, 0x47, 0xc2, 0x9a, 0x58, 0xd6, 0x9b, 0x86, 0xa9, + 0xbf, 0x61, 0xb6, 0xee, 0x74, 0xdd, 0x61, 0xea, 0x05, 0x88, 0xf3, 0x90, 0x02, 0xe1, 0x70, 0x1e, + 0xbf, 0x75, 0x70, 0x55, 0x3a, 0x34, 0x57, 0x77, 0x9d, 0xaa, 0xf2, 0xc5, 0x46, 0x92, 0x2e, 0xc0, + 0x08, 0x33, 0x4c, 0xbd, 0x60, 0x88, 0x71, 0x24, 0x69, 0x3a, 0x90, 0x24, 0xaf, 0x7f, 0x82, 0xb9, + 0x5f, 0x3a, 0x58, 0x2a, 0x1d, 0x9a, 0xa5, 0xcc, 0xcf, 0xa3, 0x70, 0x8c, 0x43, 0xa5, 0x5f, 0x10, + 0x38, 0x8e, 0xaa, 0x87, 0xa6, 0x03, 0xd1, 0x04, 0xbc, 0xc9, 0xa4, 0xf9, 0x08, 0x96, 0x22, 0xac, + 0xfc, 0xfa, 0xad, 0xd6, 0xd9, 0xfb, 0xe4, 0xd7, 0xbf, 0x3f, 0x3f, 0x92, 0xa1, 0x67, 0xd4, 0xe0, + 0xe7, 0xa4, 0xd0, 0x94, 0xea, 0x4d, 0x3c, 0xe0, 0x3b, 0x6a, 0xb1, 0x29, 0xde, 0x2c, 0x74, 0x97, + 0x40, 0xc2, 0xf3, 0x20, 0xa1, 0x8b, 0xbd, 0x23, 0x77, 0x3f, 0xbf, 0xa4, 0xa5, 0x88, 0xd6, 0x88, + 0x75, 0xc5, 0xc5, 0x3a, 0x4f, 0xe7, 0x22, 0x62, 0xa5, 0x3f, 0x12, 0x18, 0xed, 0x92, 0xe9, 0x34, + 0xd3, 0x3b, 0x74, 0xaf, 0xb7, 0x87, 0x94, 0x3d, 0x90, 0x0f, 0x82, 0x5e, 0x73, 0x41, 0x67, 0xe9, + 0x72, 0x20, 0x68, 0xe6, 0x38, 0x17, 0x02, 0xe0, 0xff, 0x46, 0xe0, 0x54, 0x0f, 0x01, 0x4c, 0x5f, + 0x8d, 0x0e, 0xc8, 0x2f, 0xd7, 0xa5, 0x73, 0x87, 0xf0, 0xc4, 0x84, 0x2e, 0xb9, 0x09, 0xad, 0xd2, + 0xf3, 0x07, 0x4e, 0xc8, 0xad, 0x9d, 0xdb, 0x04, 0x12, 0x1e, 0x3d, 0x1c, 0x56, 0x3b, 0xdd, 0x22, + 0x3d, 0xac, 0x76, 0x02, 0x44, 0xb6, 0x9c, 0x76, 0x51, 0x4f, 0xd1, 0xc9, 0x60, 0xd4, 0x02, 0xc6, + 0x6d, 0x02, 0x43, 0x8e, 0x30, 0xa5, 0x21, 0x27, 0xa9, 0x43, 0xea, 0x4a, 0x0b, 0x51, 0x4c, 0x11, + 0xcd, 0xb2, 0x8b, 0x66, 0x96, 0x9e, 0x0e, 0x41, 0xe3, 0xb2, 0xf5, 0x29, 0x81, 0xb8, 0x50, 0xa3, + 0x74, 0xae, 0x77, 0x24, 0x9f, 0xf4, 0x95, 0xd2, 0xfd, 0x0d, 0xa3, 0xd3, 0x23, 0x74, 0x2f, 0xfd, + 0x8e, 0xc0, 0x09, 0x9f, 0x0a, 0xa2, 0x4a, 0xef, 0x28, 0x41, 0x2a, 0x50, 0x52, 0x23, 0xdb, 0x23, + 0xb8, 0x73, 0x2e, 0x38, 0x85, 0x2e, 0x06, 0x82, 0x13, 0x77, 0x45, 0xc1, 0x91, 0x4f, 0xea, 0x4d, + 0x3e, 0xb0, 0x43, 0xff, 0x20, 0x20, 0xf5, 0xd6, 0x6c, 0xf4, 0xb5, 0x88, 0x50, 0x82, 0x94, 0xa2, + 0xb4, 0x7a, 0x38, 0x67, 0x4c, 0x6a, 0xdd, 0x4d, 0xea, 0x2c, 0x5d, 0x89, 0x92, 0x54, 0xa1, 0xd8, + 0x2c, 0xf0, 0x0b, 0xa4, 0xc0, 0x04, 0xfa, 0xaf, 0x09, 0xfc, 0xcf, 0xff, 0x2e, 0xa0, 0xfd, 0xb8, + 0xed, 0x7c, 0xa8, 0x48, 0x67, 0xa2, 0x3b, 0x44, 0xaf, 0xdd, 0x0e, 0xe0, 0xf4, 0x4b, 0x02, 0x09, + 0x8f, 0x42, 0x09, 0x3b, 0xe9, 0xdd, 0x7a, 0x37, 0xec, 0xa4, 0x07, 0x08, 0x44, 0xf9, 0xac, 0x8b, + 0xef, 0x65, 0x3a, 0xdf, 0x1b, 0x1f, 0xea, 0xa1, 0x76, 0xa9, 0xfc, 0x40, 0x80, 0x76, 0xcb, 0x28, + 0x9a, 0x8d, 0x14, 0xdd, 0xaf, 0xfa, 0xa4, 0x95, 0x83, 0x39, 0x21, 0xf2, 0x57, 0x5c, 0xe4, 0x8b, + 0x74, 0xa1, 0x2f, 0xf2, 0x76, 0x3d, 0xd0, 0x3b, 0x04, 0x12, 0x1e, 0x55, 0x12, 0xc6, 0x6f, 0xb7, + 0xf0, 0x0a, 0xe3, 0x37, 0x40, 0x2a, 0xc9, 0x8a, 0x8b, 0x72, 0x86, 0xbe, 0x14, 0xdc, 0xbb, 0x3c, + 0x52, 0x2a, 0x97, 0x7d, 0xb0, 0x97, 0x24, 0x0f, 0xf7, 0x92, 0xe4, 0xaf, 0xbd, 0x24, 0xf9, 0x6c, + 0x3f, 0x19, 0x7b, 0xb8, 0x9f, 0x8c, 0xfd, 0xbe, 0x9f, 0x8c, 0xbd, 0x8b, 0x3f, 0x4e, 0x33, 0x7d, + 0x4b, 0xa9, 0x58, 0xea, 0x87, 0x62, 0x0d, 0xfe, 0xe3, 0x45, 0x31, 0xce, 0x7f, 0x73, 0xce, 0xfe, + 0x13, 0x00, 0x00, 0xff, 0xff, 0xcd, 0x9a, 0x88, 0xc1, 0x96, 0x17, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1434,9 +1554,9 @@ type QueryClient interface { SupplyOf(ctx context.Context, in *QuerySupplyOfRequest, opts ...grpc.CallOption) (*QuerySupplyOfResponse, error) // Params queries the parameters of x/bank module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadata queries the client metadata of a given coin denomination. DenomMetadata(ctx context.Context, in *QueryDenomMetadataRequest, opts ...grpc.CallOption) (*QueryDenomMetadataResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadataByQueryString queries the client metadata of a given coin denomination. DenomMetadataByQueryString(ctx context.Context, in *QueryDenomMetadataByQueryStringRequest, opts ...grpc.CallOption) (*QueryDenomMetadataByQueryStringResponse, error) // DenomsMetadata queries the client metadata for all registered coin // denominations. @@ -1449,6 +1569,11 @@ type QueryClient interface { // // Since: cosmos-sdk 0.46 DenomOwners(ctx context.Context, in *QueryDenomOwnersRequest, opts ...grpc.CallOption) (*QueryDenomOwnersResponse, error) + // DenomOwnersByQuery queries for all account addresses that own a particular token + // denomination. + // + // Since: cosmos-sdk 0.50.3 + DenomOwnersByQuery(ctx context.Context, in *QueryDenomOwnersByQueryRequest, opts ...grpc.CallOption) (*QueryDenomOwnersByQueryResponse, error) // SendEnabled queries for SendEnabled entries. // // This query only returns denominations that have specific SendEnabled settings. @@ -1566,6 +1691,15 @@ func (c *queryClient) DenomOwners(ctx context.Context, in *QueryDenomOwnersReque return out, nil } +func (c *queryClient) DenomOwnersByQuery(ctx context.Context, in *QueryDenomOwnersByQueryRequest, opts ...grpc.CallOption) (*QueryDenomOwnersByQueryResponse, error) { + out := new(QueryDenomOwnersByQueryResponse) + err := c.cc.Invoke(ctx, "/cosmos.bank.v1beta1.Query/DenomOwnersByQuery", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *queryClient) SendEnabled(ctx context.Context, in *QuerySendEnabledRequest, opts ...grpc.CallOption) (*QuerySendEnabledResponse, error) { out := new(QuerySendEnabledResponse) err := c.cc.Invoke(ctx, "/cosmos.bank.v1beta1.Query/SendEnabled", in, out, opts...) @@ -1612,9 +1746,9 @@ type QueryServer interface { SupplyOf(context.Context, *QuerySupplyOfRequest) (*QuerySupplyOfResponse, error) // Params queries the parameters of x/bank module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadata queries the client metadata of a given coin denomination. DenomMetadata(context.Context, *QueryDenomMetadataRequest) (*QueryDenomMetadataResponse, error) - // DenomsMetadata queries the client metadata of a given coin denomination. + // DenomMetadataByQueryString queries the client metadata of a given coin denomination. DenomMetadataByQueryString(context.Context, *QueryDenomMetadataByQueryStringRequest) (*QueryDenomMetadataByQueryStringResponse, error) // DenomsMetadata queries the client metadata for all registered coin // denominations. @@ -1627,6 +1761,11 @@ type QueryServer interface { // // Since: cosmos-sdk 0.46 DenomOwners(context.Context, *QueryDenomOwnersRequest) (*QueryDenomOwnersResponse, error) + // DenomOwnersByQuery queries for all account addresses that own a particular token + // denomination. + // + // Since: cosmos-sdk 0.50.3 + DenomOwnersByQuery(context.Context, *QueryDenomOwnersByQueryRequest) (*QueryDenomOwnersByQueryResponse, error) // SendEnabled queries for SendEnabled entries. // // This query only returns denominations that have specific SendEnabled settings. @@ -1674,6 +1813,9 @@ func (*UnimplementedQueryServer) DenomsMetadata(ctx context.Context, req *QueryD func (*UnimplementedQueryServer) DenomOwners(ctx context.Context, req *QueryDenomOwnersRequest) (*QueryDenomOwnersResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DenomOwners not implemented") } +func (*UnimplementedQueryServer) DenomOwnersByQuery(ctx context.Context, req *QueryDenomOwnersByQueryRequest) (*QueryDenomOwnersByQueryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DenomOwnersByQuery not implemented") +} func (*UnimplementedQueryServer) SendEnabled(ctx context.Context, req *QuerySendEnabledRequest) (*QuerySendEnabledResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SendEnabled not implemented") } @@ -1880,6 +2022,24 @@ func _Query_DenomOwners_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Query_DenomOwnersByQuery_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryDenomOwnersByQueryRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).DenomOwnersByQuery(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cosmos.bank.v1beta1.Query/DenomOwnersByQuery", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).DenomOwnersByQuery(ctx, req.(*QueryDenomOwnersByQueryRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Query_SendEnabled_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySendEnabledRequest) if err := dec(in); err != nil { @@ -1946,6 +2106,10 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "DenomOwners", Handler: _Query_DenomOwners_Handler, }, + { + MethodName: "DenomOwnersByQuery", + Handler: _Query_DenomOwnersByQuery_Handler, + }, { MethodName: "SendEnabled", Handler: _Query_SendEnabled_Handler, @@ -2835,6 +2999,97 @@ func (m *QueryDenomOwnersResponse) MarshalToSizedBuffer(dAtA []byte) (int, error return len(dAtA) - i, nil } +func (m *QueryDenomOwnersByQueryRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryDenomOwnersByQueryRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryDenomOwnersByQueryRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Pagination != nil { + { + size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.Denom) > 0 { + i -= len(m.Denom) + copy(dAtA[i:], m.Denom) + i = encodeVarintQuery(dAtA, i, uint64(len(m.Denom))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *QueryDenomOwnersByQueryResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryDenomOwnersByQueryResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryDenomOwnersByQueryResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Pagination != nil { + { + size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.DenomOwners) > 0 { + for iNdEx := len(m.DenomOwners) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.DenomOwners[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + } + return len(dAtA) - i, nil +} + func (m *QuerySendEnabledRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -3285,6 +3540,42 @@ func (m *QueryDenomOwnersResponse) Size() (n int) { return n } +func (m *QueryDenomOwnersByQueryRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Denom) + if l > 0 { + n += 1 + l + sovQuery(uint64(l)) + } + if m.Pagination != nil { + l = m.Pagination.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + +func (m *QueryDenomOwnersByQueryResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.DenomOwners) > 0 { + for _, e := range m.DenomOwners { + l = e.Size() + n += 1 + l + sovQuery(uint64(l)) + } + } + if m.Pagination != nil { + l = m.Pagination.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + func (m *QuerySendEnabledRequest) Size() (n int) { if m == nil { return 0 @@ -5618,6 +5909,244 @@ func (m *QueryDenomOwnersResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *QueryDenomOwnersByQueryRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryDenomOwnersByQueryRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryDenomOwnersByQueryRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pagination == nil { + m.Pagination = &query.PageRequest{} + } + if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *QueryDenomOwnersByQueryResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryDenomOwnersByQueryResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryDenomOwnersByQueryResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DenomOwners", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.DenomOwners = append(m.DenomOwners, &DenomOwner{}) + if err := m.DenomOwners[len(m.DenomOwners)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pagination == nil { + m.Pagination = &query.PageResponse{} + } + if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *QuerySendEnabledRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/x/bank/types/query.pb.gw.go b/x/bank/types/query.pb.gw.go index 0ed732cdee70..58bc742a7322 100644 --- a/x/bank/types/query.pb.gw.go +++ b/x/bank/types/query.pb.gw.go @@ -609,6 +609,42 @@ func local_request_Query_DenomOwners_0(ctx context.Context, marshaler runtime.Ma } +var ( + filter_Query_DenomOwnersByQuery_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_Query_DenomOwnersByQuery_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryDenomOwnersByQueryRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DenomOwnersByQuery_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DenomOwnersByQuery(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Query_DenomOwnersByQuery_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryDenomOwnersByQueryRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DenomOwnersByQuery_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DenomOwnersByQuery(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_Query_SendEnabled_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -904,6 +940,29 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv }) + mux.Handle("GET", pattern_Query_DenomOwnersByQuery_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Query_DenomOwnersByQuery_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_DenomOwnersByQuery_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + mux.Handle("GET", pattern_Query_SendEnabled_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() @@ -1188,6 +1247,26 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie }) + mux.Handle("GET", pattern_Query_DenomOwnersByQuery_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Query_DenomOwnersByQuery_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_DenomOwnersByQuery_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + mux.Handle("GET", pattern_Query_SendEnabled_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() @@ -1234,6 +1313,8 @@ var ( pattern_Query_DenomOwners_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cosmos", "bank", "v1beta1", "denom_owners", "denom"}, "", runtime.AssumeColonVerbOpt(false))) + pattern_Query_DenomOwnersByQuery_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cosmos", "bank", "v1beta1", "denom_owners_by_query"}, "", runtime.AssumeColonVerbOpt(false))) + pattern_Query_SendEnabled_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cosmos", "bank", "v1beta1", "send_enabled"}, "", runtime.AssumeColonVerbOpt(false))) ) @@ -1260,5 +1341,7 @@ var ( forward_Query_DenomOwners_0 = runtime.ForwardResponseMessage + forward_Query_DenomOwnersByQuery_0 = runtime.ForwardResponseMessage + forward_Query_SendEnabled_0 = runtime.ForwardResponseMessage ) From 7412e78f62a931a97e9acf10f5521705a717512b Mon Sep 17 00:00:00 2001 From: Marko Date: Wed, 10 Jan 2024 17:48:38 +0100 Subject: [PATCH 17/28] chore(changelog): move changelog items to respective location (#19001) --- CHANGELOG.md | 76 ++----------------------------------- x/auth/CHANGELOG.md | 9 +++++ x/authz/CHANGELOG.md | 1 + x/bank/CHANGELOG.md | 5 +++ x/distribution/CHANGELOG.md | 18 +++++---- x/feegrant/CHANGELOG.md | 1 + x/gov/CHANGELOG.md | 1 + x/nft/CHANGELOG.md | 3 +- x/slashing/CHANGELOG.md | 8 ++++ x/staking/CHANGELOG.md | 53 ++++++++++++++++++++++++++ x/tx/CHANGELOG.md | 13 ++++--- 11 files changed, 101 insertions(+), 87 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d8fda2655afc..a9013c5c64ac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -38,17 +38,14 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] +Every Module contains its own CHANGELOG.md. Please refer to the module you are interested in. + ### Features -* (x/auth) Support the ability to broadcast unordered transactions per ADR-070. See UPGRADING.md for more details on integration. * (client) [#18557](https://github.com/cosmos/cosmos-sdk/pull/18557) Add `--qrcode` flag to `keys show` command to support displaying keys address QR code. -* (x/staking) [#18142](https://github.com/cosmos/cosmos-sdk/pull/18142) Introduce `key_rotation_fee` param to calculate fees while rotating the keys * (client) [#18101](https://github.com/cosmos/cosmos-sdk/pull/18101) Add a `keyring-default-keyname` in `client.toml` for specifying a default key name, and skip the need to use the `--from` flag when signing transactions. * (tests) [#17868](https://github.com/cosmos/cosmos-sdk/pull/17868) Added helper method `SubmitTestTx` in testutil to broadcast test txns to test e2e tests. -* (x/protocolpool) [#17657](https://github.com/cosmos/cosmos-sdk/pull/17657) Create a new `x/protocolpool` module that is responsible for handling community pool funds. This module is split out into a new module from x/distribution. * (client) [#17513](https://github.com/cosmos/cosmos-sdk/pull/17513) Allow overwriting `client.toml`. Use `client.CreateClientConfig` in place of `client.ReadFromClientConfig` and provide a custom template and a custom config. -* (x/bank) [#17569](https://github.com/cosmos/cosmos-sdk/pull/17569) Introduce a new message type, `MsgBurn`, to burn coins. -* (x/auth/vesting) [#17810](https://github.com/cosmos/cosmos-sdk/pull/17810) Add the ability to specify a start time for continuous vesting accounts. * (runtime) [#18475](https://github.com/cosmos/cosmos-sdk/pull/18475) Adds an implementation for core.branch.Service. * (baseapp) [#18499](https://github.com/cosmos/cosmos-sdk/pull/18499) Add `MsgRouter` response type from message name function. * (types) [#18768](https://github.com/cosmos/cosmos-sdk/pull/18768) Add MustValAddressFromBech32 function. @@ -62,11 +59,6 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (client/keys) [#18745](https://github.com/cosmos/cosmos-sdk/pull/18745) Improve ` keys export` and ` keys mnemonic` by adding --yes option to skip interactive confirmation. * (client/keys) [#18743](https://github.com/cosmos/cosmos-sdk/pull/18743) Improve ` keys add -i` by hiding inputting of bip39 passphrase. * (client/keys) [#18703](https://github.com/cosmos/cosmos-sdk/pull/18703) Improve ` keys add` and ` keys show` by checking whether there are duplicate keys in the multisig case. -* (x/gov) [#18707](https://github.com/cosmos/cosmos-sdk/pull/18707) Improve genesis validation. -* (x/bank) [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `SendCoinsFromModuleToAccount`, `SendCoinsFromModuleToModule`, `SendCoinsFromAccountToModule`, `DelegateCoinsFromAccountToModule`, `UndelegateCoinsFromModuleToAccount`, `MintCoins` and `BurnCoins` methods now returns an error instead of panicking if any module accounts does not exist or unauthorized. -* (x/distribution) [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `CalculateDelegationRewards` and `DelegationTotalRewards` methods no longer panics on any sanity checks and instead returns appropriate errors. -* (x/slashing) [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `JailUntil` and `Tombstone` methods no longer panics if the signing info does not exist for the validator but instead returns error. -* (x/staking) [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `IterateBondedValidatorsByPower`, `GetDelegatorBonded`, `Delegate`, `Unbond`, `Slash`, `Jail`, `SlashRedelegation`, `ApplyAndReturnValidatorSetUpdates` methods no longer panics on any kind of errors but instead returns appropriate errors. * Usage of `Must...` kind of functions are avoided in keeper methods. * (client/keys) [#18687](https://github.com/cosmos/cosmos-sdk/pull/18687) Improve ` keys mnemonic` by displaying mnemonic discreetly on an alternate screen and adding `--indiscreet` option to disable it. * (client/keys) [#18684](https://github.com/cosmos/cosmos-sdk/pull/18684) Improve ` keys export` by displaying unarmored hex private key discreetly on an alternate screen and adding `--indiscreet` option to disable it. @@ -80,9 +72,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [#17733](https://github.com/cosmos/cosmos-sdk/pull/17733) Ensure `buf export` exports all proto dependencies * (crypto/keys) [#18026](https://github.com/cosmos/cosmos-sdk/pull/18026) Made public key generation constant time on `secp256k1` * (crypto | x/auth) [#14372](https://github.com/cosmos/cosmos-sdk/pull/18194) Key checks on signatures antehandle. -* (staking) [#18506](https://github.com/cosmos/cosmos-sdk/pull/18506) Detect the length of the ed25519 pubkey in CreateValidator to prevent panic. -* (tx) [#18772](https://github.com/cosmos/cosmos-sdk/pull/18772) Remove misleading gas wanted from tx simulation failure log. -* (tx) [#18852](https://github.com/cosmos/cosmos-sdk/pull/18852) Add `WithFromName` to tx factory. +* (client/tx) [#18852](https://github.com/cosmos/cosmos-sdk/pull/18852) Add `WithFromName` to tx factory. * (testutil) [#18930](https://github.com/cosmos/cosmos-sdk/pull/18930) Add NodeURI for clientCtx. * (types) [#18963](https://github.com/cosmos/cosmos-sdk/pull/18963) Swap out amino json encoding of `ABCIMessageLogs` for std lib json encoding @@ -107,78 +97,22 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (x/bank/testutil) [#17868](https://github.com/cosmos/cosmos-sdk/pull/17868) `MsgSendExec` has been removed because of AutoCLI migration. * (app) [#17838](https://github.com/cosmos/cosmos-sdk/pull/17838) Params module was removed from simapp and all imports of the params module removed throughout the repo. * The Cosmos SDK has migrated away from using params, if your app still uses it, then you can leave it plugged into your app -* (x/staking) [#17778](https://github.com/cosmos/cosmos-sdk/pull/17778) Use collections for `Params` - * remove from `Keeper`: `GetParams`, `SetParams` * (types/simulation) [#17737](https://github.com/cosmos/cosmos-sdk/pull/17737) Remove unused parameter from `RandomFees` -* (x/staking) [#17486](https://github.com/cosmos/cosmos-sdk/pull/17486) Use collections for `RedelegationQueueKey`: - * remove from `types`: `GetRedelegationTimeKey` - * remove from `Keeper`: `RedelegationQueueIterator` -* (x/staking) [#17562](https://github.com/cosmos/cosmos-sdk/pull/17562) Use collections for `ValidatorQueue` - * remove from `types`: `GetValidatorQueueKey`, `ParseValidatorQueueKey` - * remove from `Keeper`: `ValidatorQueueIterator` -* (x/staking) [#17498](https://github.com/cosmos/cosmos-sdk/pull/17498) Use collections for `LastValidatorPower`: - * remove from `types`: `GetLastValidatorPowerKey` - * remove from `Keeper`: `LastValidatorsIterator`, `IterateLastValidators` -* (x/staking) [#17291](https://github.com/cosmos/cosmos-sdk/pull/17291) Use collections for `UnbondingDelegationByValIndex`: - * remove from `types`: `GetUBDKeyFromValIndexKey`, `GetUBDsByValIndexKey`, `GetUBDByValIndexKey` -* (x/slashing) [#17568](https://github.com/cosmos/cosmos-sdk/pull/17568) Use collections for `ValidatorMissedBlockBitmap`: - * remove from `types`: `ValidatorMissedBlockBitmapPrefixKey`, `ValidatorMissedBlockBitmapKey` -* (x/staking) [#17481](https://github.com/cosmos/cosmos-sdk/pull/17481) Use collections for `UnbondingQueue`: - * remove from `Keeper`: `UBDQueueIterator` - * remove from `types`: `GetUnbondingDelegationTimeKey` -* (x/staking) [#17123](https://github.com/cosmos/cosmos-sdk/pull/17123) Use collections for `Validators` -* (x/staking) [#17270](https://github.com/cosmos/cosmos-sdk/pull/17270) Use collections for `UnbondingDelegation`: - * remove from `types`: `GetUBDsKey` - * remove from `Keeper`: `IterateUnbondingDelegations`, `IterateDelegatorUnbondingDelegations` * (client/keys) [#17503](https://github.com/cosmos/cosmos-sdk/pull/17503) `clientkeys.NewKeyOutput`, `MkConsKeyOutput`, `MkValKeyOutput`, `MkAccKeyOutput`, `MkAccKeysOutput` now take their corresponding address codec instead of using the global SDK config. -* (x/staking) [#17336](https://github.com/cosmos/cosmos-sdk/pull/17336) Use collections for `RedelegationByValDstIndexKey`: - * remove from `types`: `GetREDByValDstIndexKey`, `GetREDsToValDstIndexKey` -* (x/staking) [#17332](https://github.com/cosmos/cosmos-sdk/pull/17332) Use collections for `RedelegationByValSrcIndexKey`: - * remove from `types`: `GetREDKeyFromValSrcIndexKey`, `GetREDsFromValSrcIndexKey` -* (x/staking) [#17315](https://github.com/cosmos/cosmos-sdk/pull/17315) Use collections for `RedelegationKey`: - * remove from `keeper`: `GetRedelegation` * (types) `module.BeginBlockAppModule` has been replaced by Core API `appmodule.HasBeginBlocker`. * (types) `module.EndBlockAppModule` has been replaced by Core API `appmodule.HasEndBlocker` or `module.HasABCIEndBlock` when needing validator updates. -* (x/slashing) [#17044](https://github.com/cosmos/cosmos-sdk/pull/17044) Use collections for `AddrPubkeyRelation`: - * remove from `types`: `AddrPubkeyRelationKey` - * remove from `Keeper`: `AddPubkey` -* (x/staking) [#17260](https://github.com/cosmos/cosmos-sdk/pull/17260) Use collections for `DelegationKey`: - * remove from `types`: `GetDelegationKey`, `GetDelegationsKey` -* (x/staking) [#17288](https://github.com/cosmos/cosmos-sdk/pull/17288) Use collections for `UnbondingIndex`: - * remove from `types`: `GetUnbondingIndexKey`. -* (x/staking) [#17256](https://github.com/cosmos/cosmos-sdk/pull/17256) Use collections for `UnbondingID`. -* (x/staking) [#17260](https://github.com/cosmos/cosmos-sdk/pull/17260) Use collections for `ValidatorByConsAddr`: - * remove from `types`: `GetValidatorByConsAddrKey` -* (x/staking) [#17248](https://github.com/cosmos/cosmos-sdk/pull/17248) Use collections for `UnbondingType`. - * remove from `types`: `GetUnbondingTypeKey`. * (client) [#17259](https://github.com/cosmos/cosmos-sdk/pull/17259) Remove deprecated `clientCtx.PrintObjectLegacy`. Use `clientCtx.PrintProto` or `clientCtx.PrintRaw` instead. -* (x/feegrant) [#16535](https://github.com/cosmos/cosmos-sdk/pull/16535) Use collections for `FeeAllowance`, `FeeAllowanceQueue`. -* (x/staking) [#17063](https://github.com/cosmos/cosmos-sdk/pull/17063) Use collections for `HistoricalInfo`: - * remove `Keeper`: `GetHistoricalInfo`, `SetHistoricalInfo` -* (x/staking) [#17062](https://github.com/cosmos/cosmos-sdk/pull/17062) Use collections for `ValidatorUpdates`: - * remove `Keeper`: `SetValidatorUpdates`, `GetValidatorUpdates` -* (x/slashing) [#17023](https://github.com/cosmos/cosmos-sdk/pull/17023) Use collections for `ValidatorSigningInfo`: - * remove `Keeper`: `SetValidatorSigningInfo`, `GetValidatorSigningInfo`, `IterateValidatorSigningInfos` -* (x/staking) [#17026](https://github.com/cosmos/cosmos-sdk/pull/17026) Use collections for `LastTotalPower`: - * remove `Keeper`: `SetLastTotalPower`, `GetLastTotalPower` -* (x/authz) [#16509](https://github.com/cosmos/cosmos-sdk/pull/16509) `AcceptResponse` has been moved to sdk/types/authz and the `Updated` field is now of the type `sdk.Msg` instead of `authz.Authorization`. -* (x/slashing) [#16441](https://github.com/cosmos/cosmos-sdk/pull/16441) Params state is migrated to collections. `GetParams` has been removed. * (types) [#16918](https://github.com/cosmos/cosmos-sdk/pull/16918) Remove `IntProto` and `DecProto`. Instead, `math.Int` and `math.LegacyDec` should be used respectively. Both types support `Marshal` and `Unmarshal` which should be used for binary marshaling. * (client) [#17215](https://github.com/cosmos/cosmos-sdk/pull/17215) `server.StartCmd`,`server.ExportCmd`,`server.NewRollbackCmd`,`pruning.Cmd`,`genutilcli.InitCmd`,`genutilcli.GenTxCmd`,`genutilcli.CollectGenTxsCmd`,`genutilcli.AddGenesisAccountCmd`, do not take a home directory anymore. It is inferred from the root command. * (baseapp) [#16244](https://github.com/cosmos/cosmos-sdk/pull/16244) `SetProtocolVersion` has been renamed to `SetAppVersion`. It now updates the consensus params in baseapp's `ParamStore`. * (types) [#17348](https://github.com/cosmos/cosmos-sdk/pull/17348) Remove the `WrapServiceResult` function. * The `*sdk.Result` returned by the msg server router will not contain the `.Data` field. -* (x/staking) [#17335](https://github.com/cosmos/cosmos-sdk/pull/17335) Remove usage of `"cosmossdk.io/x/staking/types".Infraction_*` in favour of `"cosmossdk.io/api/cosmos/staking/v1beta1".Infraction_` in order to remove dependency between modules on staking * (types) [#17426](https://github.com/cosmos/cosmos-sdk/pull/17426) `NewContext` does not take a `cmtproto.Header{}` any longer. * `WithChainID` / `WithBlockHeight` / `WithBlockHeader` must be used to set values on the context -* (x/bank) [#17569](https://github.com/cosmos/cosmos-sdk/pull/17569) `BurnCoins` takes an address instead of a module name * (types) [#17738](https://github.com/cosmos/cosmos-sdk/pull/17738) `WithBlockTime()` was removed & `BlockTime()` were deprecated in favor of `WithHeaderInfo()` & `HeaderInfo()`. `BlockTime` now gets data from `HeaderInfo()` instead of `BlockHeader()`. * (client) [#17746](https://github.com/cosmos/cosmos-sdk/pull/17746) `txEncodeAmino` & `txDecodeAmino` txs via grpc and rest were removed * `RegisterLegacyAmino` was removed from `AppModuleBasic` -* (x/staking) [#17655](https://github.com/cosmos/cosmos-sdk/pull/17655) `QueryHistoricalInfo` was adjusted to return `HistoricalRecord` and marked `Hist` as deprecated. * (types) [#17885](https://github.com/cosmos/cosmos-sdk/pull/17885) `InitGenesis` & `ExportGenesis` now take `context.Context` instead of `sdk.Context` -* (x/auth) [#17985](https://github.com/cosmos/cosmos-sdk/pull/17985) Remove `StdTxConfig` - * Remove deprecated `MakeTestingEncodingParams` from `simapp/params` * (x/group) [#17937](https://github.com/cosmos/cosmos-sdk/pull/17937) Groups module was moved to its own go.mod `cosmossdk.io/x/group` * (x/gov) [#18197](https://github.com/cosmos/cosmos-sdk/pull/18197) Gov module was moved to its own go.mod `cosmossdk.io/x/gov` * (x/distribution) [#18199](https://github.com/cosmos/cosmos-sdk/pull/18199) Distribution module was moved to its own go.mod `cosmossdk.io/x/distribution` @@ -197,13 +131,9 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### CLI Breaking Changes * (server) [#18303](https://github.com/cosmos/cosmos-sdk/pull/18303) `appd export` has moved with other genesis commands, use `appd genesis export` instead. -* (x/auth/vesting) [#18100](https://github.com/cosmos/cosmos-sdk/pull/18100) `appd tx vesting create-vesting-account` takes an amount of coin as last argument instead of second. Coins are space separated. ### State Machine Breaking -* (x/upgrade) [#16244](https://github.com/cosmos/cosmos-sdk/pull/16244) Upgrade module no longer stores the app version but gets and sets the app version stored in the `ParamStore` of baseapp. -* (x/staking) [#17655](https://github.com/cosmos/cosmos-sdk/pull/17655) `HistoricalInfo` was replaced with `HistoricalRecord`, it removes the validator set and comet header and only keep what is needed for IBC. - ## [v0.50.2](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.50.2) - 2023-12-11 ### Features diff --git a/x/auth/CHANGELOG.md b/x/auth/CHANGELOG.md index 7990c1535698..226d7e357e70 100644 --- a/x/auth/CHANGELOG.md +++ b/x/auth/CHANGELOG.md @@ -27,14 +27,23 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Features +* [#18641](https://github.com/cosmos/cosmos-sdk/pull/18641) Support the ability to broadcast unordered transactions per ADR-070. See UPGRADING.md for more details on integration. * [#18281](https://github.com/cosmos/cosmos-sdk/pull/18281) Support broadcasting multiple transactions. +* (vesting) [#17810](https://github.com/cosmos/cosmos-sdk/pull/17810) Add the ability to specify a start time for continuous vesting accounts. +* (tx) [#18772](https://github.com/cosmos/cosmos-sdk/pull/18772) Remove misleading gas wanted from tx simulation failure log. ### Improvements * [#18780](https://github.com/cosmos/cosmos-sdk/pull/18780) Move sig verification out of the for loop, into the authenticate method. +### CLI Breaking Changes + +* (vesting) [#18100](https://github.com/cosmos/cosmos-sdk/pull/18100) `appd tx vesting create-vesting-account` takes an amount of coin as last argument instead of second. Coins are space separated. + ### API Breaking Changes +* [#17985](https://github.com/cosmos/cosmos-sdk/pull/17985) Remove `StdTxConfig` + ### Consensus Breaking Changes * [#18817](https://github.com/cosmos/cosmos-sdk/pull/18817) SigVerification, GasConsumption, IncreaseSequence ante decorators have all been joined into one SigVerification decorator. Gas consumption during TX validation flow has reduced. diff --git a/x/authz/CHANGELOG.md b/x/authz/CHANGELOG.md index 650f291a46e0..97a4fdfcc01f 100644 --- a/x/authz/CHANGELOG.md +++ b/x/authz/CHANGELOG.md @@ -34,5 +34,6 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### API Breaking Changes * [#18737](https://github.com/cosmos/cosmos-sdk/pull/18737) Update the keeper method `DequeueAndDeleteExpiredGrants` to take a limit argument for the number of grants to prune. +* [#16509](https://github.com/cosmos/cosmos-sdk/pull/16509) `AcceptResponse` has been moved to sdk/types/authz and the `Updated` field is now of the type `sdk.Msg` instead of `authz.Authorization`. ### Bug Fixes diff --git a/x/bank/CHANGELOG.md b/x/bank/CHANGELOG.md index 818a5d55e123..21093235999c 100644 --- a/x/bank/CHANGELOG.md +++ b/x/bank/CHANGELOG.md @@ -27,12 +27,17 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Features +* [#17569](https://github.com/cosmos/cosmos-sdk/pull/17569) Introduce a new message type, `MsgBurn`, to burn coins. * [#18956](https://github.com/cosmos/cosmos-sdk/pull/18956) Introduced a new `DenomOwnersByQuery` query method for `DenomOwners`, which accepts the denom value as a query string parameter, resolving issues with denoms containing slashes. ### Improvements +* [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `SendCoinsFromModuleToAccount`, `SendCoinsFromModuleToModule`, `SendCoinsFromAccountToModule`, `DelegateCoinsFromAccountToModule`, `UndelegateCoinsFromModuleToAccount`, `MintCoins` and `BurnCoins` methods now returns an error instead of panicking if any module accounts does not exist or unauthorized. + ### API Breaking Changes +* [#17569](https://github.com/cosmos/cosmos-sdk/pull/17569) `BurnCoins` takes an address instead of a module name + ### Bug Fixes diff --git a/x/distribution/CHANGELOG.md b/x/distribution/CHANGELOG.md index 6eaa62a96b4e..86e4d0044555 100644 --- a/x/distribution/CHANGELOG.md +++ b/x/distribution/CHANGELOG.md @@ -32,23 +32,27 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### API Breaking Changes * [#17115](https://github.com/cosmos/cosmos-sdk/pull/17115) Use collections for `PreviousProposer` and `ValidatorSlashEvents`: - * remove from `Keeper`: `GetPreviousProposerConsAddr`, `SetPreviousProposerConsAddr`, `GetValidatorHistoricalReferenceCount`, `GetValidatorSlashEvent`, `SetValidatorSlashEvent`. + * remove from `Keeper`: `GetPreviousProposerConsAddr`, `SetPreviousProposerConsAddr`, `GetValidatorHistoricalReferenceCount`, `GetValidatorSlashEvent`, `SetValidatorSlashEvent`. * [#16483](https://github.com/cosmos/cosmos-sdk/pull/16483) use collections for `DelegatorStartingInfo` state management: - * remove `Keeper`: `IterateDelegatorStartingInfo`, `GetDelegatorStartingInfo`, `SetDelegatorStartingInfo`, `DeleteDelegatorStartingInfo`, `HasDelegatorStartingInfo` + * remove `Keeper`: `IterateDelegatorStartingInfo`, `GetDelegatorStartingInfo`, `SetDelegatorStartingInfo`, `DeleteDelegatorStartingInfo`, `HasDelegatorStartingInfo` * [#16571](https://github.com/cosmos/cosmos-sdk/pull/16571) use collections for `ValidatorAccumulatedCommission` state management: - * remove `Keeper`: `IterateValidatorAccumulatedCommission`, `GetValidatorAccumulatedCommission`, `SetValidatorAccumulatedCommission`, `DeleteValidatorAccumulatedCommission` + * remove `Keeper`: `IterateValidatorAccumulatedCommission`, `GetValidatorAccumulatedCommission`, `SetValidatorAccumulatedCommission`, `DeleteValidatorAccumulatedCommission` * [#16590](https://github.com/cosmos/cosmos-sdk/pull/16590) use collections for `ValidatorOutstandingRewards` state management: - * remove `Keeper`: `IterateValidatorOutstandingRewards`, `GetValidatorOutstandingRewards`, `SetValidatorOutstandingRewards`, `DeleteValidatorOutstandingRewards` + * remove `Keeper`: `IterateValidatorOutstandingRewards`, `GetValidatorOutstandingRewards`, `SetValidatorOutstandingRewards`, `DeleteValidatorOutstandingRewards` * [#16607](https://github.com/cosmos/cosmos-sdk/pull/16607) use collections for `ValidatorHistoricalRewards` state management: - * remove `Keeper`: `IterateValidatorHistoricalRewards`, `GetValidatorHistoricalRewards`, `SetValidatorHistoricalRewards`, `DeleteValidatorHistoricalRewards`, `DeleteValidatorHistoricalReward`, `DeleteAllValidatorHistoricalRewards` + * remove `Keeper`: `IterateValidatorHistoricalRewards`, `GetValidatorHistoricalRewards`, `SetValidatorHistoricalRewards`, `DeleteValidatorHistoricalRewards`, `DeleteValidatorHistoricalReward`, `DeleteAllValidatorHistoricalRewards` * [#17657](https://github.com/cosmos/cosmos-sdk/pull/17657) The `FundCommunityPool` and `DistributeFromFeePool` keeper methods are now removed from x/distribution. * [#16440](https://github.com/cosmos/cosmos-sdk/pull/16440) use collections for `DelegatorWithdrawAddresState`: - * remove `Keeper`: `SetDelegatorWithdrawAddr`, `DeleteDelegatorWithdrawAddr`, `IterateDelegatorWithdrawAddrs`. + * remove `Keeper`: `SetDelegatorWithdrawAddr`, `DeleteDelegatorWithdrawAddr`, `IterateDelegatorWithdrawAddrs`. * [#16459](https://github.com/cosmos/cosmos-sdk/pull/16459) use collections for `ValidatorCurrentRewards` state management: - * remove `Keeper`: `IterateValidatorCurrentRewards`, `GetValidatorCurrentRewards`, `SetValidatorCurrentRewards`, `DeleteValidatorCurrentRewards` + * remove `Keeper`: `IterateValidatorCurrentRewards`, `GetValidatorCurrentRewards`, `SetValidatorCurrentRewards`, `DeleteValidatorCurrentRewards` * [#17657](https://github.com/cosmos/cosmos-sdk/pull/17657) The distribution module keeper now takes a new argument `PoolKeeper` in addition. * [#17670](https://github.com/cosmos/cosmos-sdk/pull/17670) `AllocateTokens` takes `comet.VoteInfos` instead of `[]abci.VoteInfo` +### Improvements + +* [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `CalculateDelegationRewards` and `DelegationTotalRewards` methods no longer panics on any sanity checks and instead returns appropriate errors. + ### CLI Breaking Changes * [#17963](https://github.com/cosmos/cosmos-sdk/pull/17963) `appd tx distribution withdraw-rewards` now only withdraws rewards for the delegator's own delegations. For withdrawing validators commission, use `appd tx distribution withdraw-validator-commission`. diff --git a/x/feegrant/CHANGELOG.md b/x/feegrant/CHANGELOG.md index e48e88ab2811..995dde2bf2bd 100644 --- a/x/feegrant/CHANGELOG.md +++ b/x/feegrant/CHANGELOG.md @@ -45,3 +45,4 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [#15347](https://github.com/cosmos/cosmos-sdk/pull/15347) Remove global bech32 usage in keeper. * [#15347](https://github.com/cosmos/cosmos-sdk/pull/15347) `ValidateBasic` is treated as a no op now with with acceptance of RFC001 * [#17869](https://github.com/cosmos/cosmos-sdk/pull/17869) `NewGrant`, `NewMsgGrantAllowance` & `NewMsgRevokeAllowance` takes strings instead of `sdk.AccAddress` +* [#16535](https://github.com/cosmos/cosmos-sdk/pull/16535) Use collections for `FeeAllowance`, `FeeAllowanceQueue`. diff --git a/x/gov/CHANGELOG.md b/x/gov/CHANGELOG.md index c7f80a822a55..65b8625cf8dd 100644 --- a/x/gov/CHANGELOG.md +++ b/x/gov/CHANGELOG.md @@ -38,6 +38,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [#18856](https://github.com/cosmos/cosmos-sdk/pull/18856) Add `ProposalCancelMaxPeriod` for modifying how long a proposal can be cancelled after it has been submitted. * [#18445](https://github.com/cosmos/cosmos-sdk/pull/18445) Extend gov config. * [#18532](https://github.com/cosmos/cosmos-sdk/pull/18532) Repurpose `govcliutils.NormalizeProposalType` to work for gov v1 proposal types. +* [#18707](https://github.com/cosmos/cosmos-sdk/pull/18707) Improve genesis validation. ### API Breaking Changes diff --git a/x/nft/CHANGELOG.md b/x/nft/CHANGELOG.md index bb88fc70f95d..d64a7528d644 100644 --- a/x/nft/CHANGELOG.md +++ b/x/nft/CHANGELOG.md @@ -32,6 +32,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] ### Features -* [#18355](https://github.com/cosmos/cosmos-sdk/pull/18355) Addes new versions for `Balance`, `Owner`, `Supply`, `NFT`, `Class` queries that receives request via query string. + +* [#18355](https://github.com/cosmos/cosmos-sdk/pull/18355) Added new versions for `Balance`, `Owner`, `Supply`, `NFT`, `Class` queries that receives request via query string. ## [v0.1.0](https://github.com/cosmos/cosmos-sdk/releases/tag/x/nft/v0.1.0) - 2023-11-07 diff --git a/x/slashing/CHANGELOG.md b/x/slashing/CHANGELOG.md index ad84f2599709..87174afe24e1 100644 --- a/x/slashing/CHANGELOG.md +++ b/x/slashing/CHANGELOG.md @@ -30,7 +30,15 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements * [#18959](https://github.com/cosmos/cosmos-sdk/pull/18959) Avoid deserialization of parameters with every validator lookup +* [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `JailUntil` and `Tombstone` methods no longer panics if the signing info does not exist for the validator but instead returns error. ### API Breaking Changes +* [#16441](https://github.com/cosmos/cosmos-sdk/pull/16441) Params state is migrated to collections. `GetParams` has been removed. +* [#17023](https://github.com/cosmos/cosmos-sdk/pull/17023) Use collections for `ValidatorSigningInfo`: + * remove `Keeper`: `SetValidatorSigningInfo`, `GetValidatorSigningInfo`, `IterateValidatorSigningInfos` +* [#17044](https://github.com/cosmos/cosmos-sdk/pull/17044) Use collections for `AddrPubkeyRelation`: + * remove from `types`: `AddrPubkeyRelationKey` + * remove from `Keeper`: `AddPubkey` + ### Bug Fixes diff --git a/x/staking/CHANGELOG.md b/x/staking/CHANGELOG.md index bf177866994a..fcd621d9b544 100644 --- a/x/staking/CHANGELOG.md +++ b/x/staking/CHANGELOG.md @@ -29,8 +29,61 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* [#18636](https://github.com/cosmos/cosmos-sdk/pull/18636) `IterateBondedValidatorsByPower`, `GetDelegatorBonded`, `Delegate`, `Unbond`, `Slash`, `Jail`, `SlashRedelegation`, `ApplyAndReturnValidatorSetUpdates` methods no longer panics on any kind of errors but instead returns appropriate errors. +* [#18506](https://github.com/cosmos/cosmos-sdk/pull/18506) Detect the length of the ed25519 pubkey in CreateValidator to prevent panic. + ### API Breaking Changes * [#18198](https://github.com/cosmos/cosmos-sdk/pull/18198): `Validator` and `Delegator` interfaces were moved to `github.com/cosmos/cosmos-sdk/types` to avoid interface dependency on staking in other modules. +* [#17778](https://github.com/cosmos/cosmos-sdk/pull/17778) Use collections for `Params` + * remove from `Keeper`: `GetParams`, `SetParams` +* [#17486](https://github.com/cosmos/cosmos-sdk/pull/17486) Use collections for `RedelegationQueueKey`: + * remove from `types`: `GetRedelegationTimeKey` + * remove from `Keeper`: `RedelegationQueueIterator` +* [#17562](https://github.com/cosmos/cosmos-sdk/pull/17562) Use collections for `ValidatorQueue` + * remove from `types`: `GetValidatorQueueKey`, `ParseValidatorQueueKey` + * remove from `Keeper`: `ValidatorQueueIterator` +* [#17498](https://github.com/cosmos/cosmos-sdk/pull/17498) Use collections for `LastValidatorPower`: + * remove from `types`: `GetLastValidatorPowerKey` + * remove from `Keeper`: `LastValidatorsIterator`, `IterateLastValidators` +* [#17291](https://github.com/cosmos/cosmos-sdk/pull/17291) Use collections for `UnbondingDelegationByValIndex`: + * remove from `types`: `GetUBDKeyFromValIndexKey`, `GetUBDsByValIndexKey`, `GetUBDByValIndexKey` +* (x/slashing) [#17568](https://github.com/cosmos/cosmos-sdk/pull/17568) Use collections for `ValidatorMissedBlockBitmap`: + * remove from `types`: `ValidatorMissedBlockBitmapPrefixKey`, `ValidatorMissedBlockBitmapKey` +* [#17481](https://github.com/cosmos/cosmos-sdk/pull/17481) Use collections for `UnbondingQueue`: + * remove from `Keeper`: `UBDQueueIterator` + * remove from `types`: `GetUnbondingDelegationTimeKey` +* [#17123](https://github.com/cosmos/cosmos-sdk/pull/17123) Use collections for `Validators` +* [#17270](https://github.com/cosmos/cosmos-sdk/pull/17270) Use collections for `UnbondingDelegation`: + * remove from `types`: `GetUBDsKey` + * remove from `Keeper`: `IterateUnbondingDelegations`, `IterateDelegatorUnbondingDelegations` +* [#17336](https://github.com/cosmos/cosmos-sdk/pull/17336) Use collections for `RedelegationByValDstIndexKey`: + * remove from `types`: `GetREDByValDstIndexKey`, `GetREDsToValDstIndexKey` +* [#17332](https://github.com/cosmos/cosmos-sdk/pull/17332) Use collections for `RedelegationByValSrcIndexKey`: + * remove from `types`: `GetREDKeyFromValSrcIndexKey`, `GetREDsFromValSrcIndexKey` +* [#17315](https://github.com/cosmos/cosmos-sdk/pull/17315) Use collections for `RedelegationKey`: + * remove from `keeper`: `GetRedelegation` +* [#17260](https://github.com/cosmos/cosmos-sdk/pull/17260) Use collections for `DelegationKey`: + * remove from `types`: `GetDelegationKey`, `GetDelegationsKey` +* [#17288](https://github.com/cosmos/cosmos-sdk/pull/17288) Use collections for `UnbondingIndex`: + * remove from `types`: `GetUnbondingIndexKey`. +* [#17256](https://github.com/cosmos/cosmos-sdk/pull/17256) Use collections for `UnbondingID`. +* [#17260](https://github.com/cosmos/cosmos-sdk/pull/17260) Use collections for `ValidatorByConsAddr`: + * remove from `types`: `GetValidatorByConsAddrKey` +* [#17248](https://github.com/cosmos/cosmos-sdk/pull/17248) Use collections for `UnbondingType`. + * remove from `types`: `GetUnbondingTypeKey`. +* [#17063](https://github.com/cosmos/cosmos-sdk/pull/17063) Use collections for `HistoricalInfo`: + * remove `Keeper`: `GetHistoricalInfo`, `SetHistoricalInfo` +* [#17062](https://github.com/cosmos/cosmos-sdk/pull/17062) Use collections for `ValidatorUpdates`: + * remove `Keeper`: `SetValidatorUpdates`, `GetValidatorUpdates` +* [#17026](https://github.com/cosmos/cosmos-sdk/pull/17026) Use collections for `LastTotalPower`: + * remove `Keeper`: `SetLastTotalPower`, `GetLastTotalPower` +* [#17335](https://github.com/cosmos/cosmos-sdk/pull/17335) Remove usage of `"cosmossdk.io/x/staking/types".Infraction_*` in favour of `"cosmossdk.io/api/cosmos/staking/v1beta1".Infraction_` in order to remove dependency between modules on staking +* [#17655](https://github.com/cosmos/cosmos-sdk/pull/17655) `QueryHistoricalInfo` was adjusted to return `HistoricalRecord` and marked `Hist` as deprecated. + +### State Breaking changes + +* [#18142](https://github.com/cosmos/cosmos-sdk/pull/18142) Introduce `key_rotation_fee` param to calculate fees while rotating the keys +* [#17655](https://github.com/cosmos/cosmos-sdk/pull/17655) `HistoricalInfo` was replaced with `HistoricalRecord`, it removes the validator set and comet header and only keep what is needed for IBC. ### Bug Fixes diff --git a/x/tx/CHANGELOG.md b/x/tx/CHANGELOG.md index a001f957cc22..cbdfe5f44b92 100644 --- a/x/tx/CHANGELOG.md +++ b/x/tx/CHANGELOG.md @@ -38,6 +38,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## v0.13.0 ### Improvements + * [#18740](https://github.com/cosmos/cosmos-sdk/pull/18740) Support nested messages when fetching signers up to a default depth of 32. ## v0.12.0 @@ -102,18 +103,18 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements * [#15871](https://github.com/cosmos/cosmos-sdk/pull/15871) - * `HandlerMap` now has a `DefaultMode()` getter method - * Textual types use `signing.ProtoFileResolver` instead of `protoregistry.Files` + * `HandlerMap` now has a `DefaultMode()` getter method + * Textual types use `signing.ProtoFileResolver` instead of `protoregistry.Files` ## v0.6.0 ### API Breaking * [#15709](https://github.com/cosmos/cosmos-sdk/pull/15709): - * `GetSignersContext` has been renamed to `signing.Context` - * `GetSigners` now returns `[][]byte` instead of `[]string` - * `GetSignersOptions` has been renamed to `signing.Options` and requires `address.Codec`s for account and validator addresses - * `GetSignersOptions.ProtoFiles` has been renamed to `signing.Options.FileResolver` + * `GetSignersContext` has been renamed to `signing.Context` + * `GetSigners` now returns `[][]byte` instead of `[]string` + * `GetSignersOptions` has been renamed to `signing.Options` and requires `address.Codec`s for account and validator addresses + * `GetSignersOptions.ProtoFiles` has been renamed to `signing.Options.FileResolver` ### Bug Fixes From 1aaad3e817d94735187a534754acccce66f6d38f Mon Sep 17 00:00:00 2001 From: Marko Date: Wed, 10 Jan 2024 17:50:28 +0100 Subject: [PATCH 18/28] fix: copy correct go.mod into container (#19008) Co-authored-by: Aleksandr Bezobchuk --- contrib/images/simd-env/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/images/simd-env/Dockerfile b/contrib/images/simd-env/Dockerfile index 0ed920028f58..32f112935acc 100644 --- a/contrib/images/simd-env/Dockerfile +++ b/contrib/images/simd-env/Dockerfile @@ -9,7 +9,7 @@ COPY api/go.mod api/go.sum /work/api/ COPY core/go.mod core/go.sum /work/core/ COPY collections/go.mod collections/go.sum /work/collections/ COPY store/go.mod store/go.sum /work/store/ -COPY store/go.mod store/go.sum /work/depinject/ +COPY depinject/go.mod depinject/go.sum /work/depinject/ COPY x/tx/go.mod x/tx/go.sum /work/x/tx/ COPY x/protocolpool/go.mod x/protocolpool/go.sum /work/x/protocolpool/ COPY x/gov/go.mod x/gov/go.sum /work/x/gov/ From 1e7611faab88f0c24a5b3fdbc27cd1a79c8bce2a Mon Sep 17 00:00:00 2001 From: testinginprod <98415576+testinginprod@users.noreply.github.com> Date: Wed, 10 Jan 2024 17:55:57 +0100 Subject: [PATCH 19/28] feat(accounts): Add header.Service support (#19004) Co-authored-by: unknown unknown Co-authored-by: Aleksandr Bezobchuk --- runtime/header.go | 17 +++++++++++++++++ simapp/app.go | 1 + x/accounts/internal/implementation/context.go | 14 +++++++++++--- .../internal/implementation/context_test.go | 2 +- .../internal/implementation/implementation.go | 11 +++++++++-- .../implementation/implementation_test.go | 2 +- x/accounts/keeper.go | 16 +++++++--------- x/accounts/utils_test.go | 2 +- 8 files changed, 48 insertions(+), 17 deletions(-) create mode 100644 runtime/header.go diff --git a/runtime/header.go b/runtime/header.go new file mode 100644 index 000000000000..5016912d9a71 --- /dev/null +++ b/runtime/header.go @@ -0,0 +1,17 @@ +package runtime + +import ( + "context" + + "cosmossdk.io/core/header" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +var _ header.Service = (*HeaderService)(nil) + +type HeaderService struct{} + +func (h HeaderService) GetHeaderInfo(ctx context.Context) header.Info { + return sdk.UnwrapSDKContext(ctx).HeaderInfo() +} diff --git a/simapp/app.go b/simapp/app.go index bb31d24f8445..12daf0637215 100644 --- a/simapp/app.go +++ b/simapp/app.go @@ -288,6 +288,7 @@ func NewSimApp( accountsKeeper, err := accounts.NewKeeper( runtime.NewKVStoreService(keys[accounts.StoreKey]), runtime.EventService{}, + runtime.HeaderService{}, runtime.BranchService{}, app.AuthKeeper.AddressCodec(), appCodec, diff --git a/x/accounts/internal/implementation/context.go b/x/accounts/internal/implementation/context.go index 38cc07521013..f6e340ada306 100644 --- a/x/accounts/internal/implementation/context.go +++ b/x/accounts/internal/implementation/context.go @@ -5,6 +5,7 @@ import ( "encoding/binary" "cosmossdk.io/collections" + "cosmossdk.io/core/header" "cosmossdk.io/core/store" "cosmossdk.io/x/accounts/internal/prefixstore" ) @@ -51,8 +52,8 @@ func MakeAccountContext( sender: sender, whoami: accountAddr, originalContext: ctx, - moduleExecUntyped: moduleExecUntyped, moduleExec: moduleExec, + moduleExecUntyped: moduleExecUntyped, moduleQuery: moduleQuery, }) } @@ -107,8 +108,8 @@ func QueryModule[Resp any, RespProto ProtoMsgG[Resp], Req any, ReqProto ProtoMsg return resp, nil } -// OpenKVStore returns the prefixed store for the account given the context. -func OpenKVStore(ctx context.Context) store.KVStore { +// openKVStore returns the prefixed store for the account given the context. +func openKVStore(ctx context.Context) store.KVStore { return ctx.Value(contextKey{}).(contextValue).store } @@ -121,3 +122,10 @@ func Sender(ctx context.Context) []byte { func Whoami(ctx context.Context) []byte { return ctx.Value(contextKey{}).(contextValue).whoami } + +type headerService struct{ header.Service } + +func (h headerService) GetHeaderInfo(ctx context.Context) header.Info { + originalContext := ctx.Value(contextKey{}).(contextValue).originalContext + return h.Service.GetHeaderInfo(originalContext) +} diff --git a/x/accounts/internal/implementation/context_test.go b/x/accounts/internal/implementation/context_test.go index 2c8db80ca2cf..7aa33575eaa6 100644 --- a/x/accounts/internal/implementation/context_test.go +++ b/x/accounts/internal/implementation/context_test.go @@ -16,7 +16,7 @@ func TestMakeAccountContext(t *testing.T) { storeService, originalContext := colltest.MockStore() accountAddr := []byte("accountAddr") sender := []byte("sender") - sb := collections.NewSchemaBuilderFromAccessor(OpenKVStore) + sb := collections.NewSchemaBuilderFromAccessor(openKVStore) accountCtx := MakeAccountContext(originalContext, storeService, 1, accountAddr, sender, nil, nil, nil) diff --git a/x/accounts/internal/implementation/implementation.go b/x/accounts/internal/implementation/implementation.go index 4023ef608af4..024381613ddf 100644 --- a/x/accounts/internal/implementation/implementation.go +++ b/x/accounts/internal/implementation/implementation.go @@ -6,12 +6,14 @@ import ( "cosmossdk.io/collections" "cosmossdk.io/core/address" + "cosmossdk.io/core/header" ) // Dependencies are passed to the constructor of a smart account. type Dependencies struct { SchemaBuilder *collections.SchemaBuilder AddressCodec address.Codec + HeaderService header.Service } // AccountCreatorFunc is a function that creates an account. @@ -19,13 +21,18 @@ type AccountCreatorFunc = func(deps Dependencies) (string, Account, error) // MakeAccountsMap creates a map of account names to account implementations // from a list of account creator functions. -func MakeAccountsMap(addressCodec address.Codec, accounts []AccountCreatorFunc) (map[string]Implementation, error) { +func MakeAccountsMap( + addressCodec address.Codec, + hs header.Service, + accounts []AccountCreatorFunc, +) (map[string]Implementation, error) { accountsMap := make(map[string]Implementation, len(accounts)) for _, makeAccount := range accounts { - stateSchemaBuilder := collections.NewSchemaBuilderFromAccessor(OpenKVStore) + stateSchemaBuilder := collections.NewSchemaBuilderFromAccessor(openKVStore) deps := Dependencies{ SchemaBuilder: stateSchemaBuilder, AddressCodec: addressCodec, + HeaderService: headerService{hs}, } name, accountInterface, err := makeAccount(deps) if err != nil { diff --git a/x/accounts/internal/implementation/implementation_test.go b/x/accounts/internal/implementation/implementation_test.go index 1aeb5ddd2025..696420f00924 100644 --- a/x/accounts/internal/implementation/implementation_test.go +++ b/x/accounts/internal/implementation/implementation_test.go @@ -11,7 +11,7 @@ import ( ) func TestImplementation(t *testing.T) { - impl, err := newImplementation(collections.NewSchemaBuilderFromAccessor(OpenKVStore), TestAccount{}) + impl, err := newImplementation(collections.NewSchemaBuilderFromAccessor(openKVStore), TestAccount{}) require.NoError(t, err) ctx := context.Background() diff --git a/x/accounts/keeper.go b/x/accounts/keeper.go index f2561e5e60c2..d29b291f0a1f 100644 --- a/x/accounts/keeper.go +++ b/x/accounts/keeper.go @@ -15,6 +15,7 @@ import ( "cosmossdk.io/core/address" "cosmossdk.io/core/branch" "cosmossdk.io/core/event" + "cosmossdk.io/core/header" "cosmossdk.io/core/store" "cosmossdk.io/x/accounts/accountstd" "cosmossdk.io/x/accounts/internal/implementation" @@ -54,9 +55,6 @@ type SignerProvider interface { GetMsgV1Signers(msg gogoproto.Message) ([][]byte, proto.Message, error) } -// BranchExecutor defines an interface used to execute ops in a branch. -type BranchExecutor = branch.Service - type InterfaceRegistry interface { RegisterInterface(name string, iface any, impls ...gogoproto.Message) RegisterImplementations(iface any, impls ...gogoproto.Message) @@ -65,7 +63,8 @@ type InterfaceRegistry interface { func NewKeeper( ss store.KVStoreService, es event.Service, - bs BranchExecutor, + hs header.Service, + bs branch.Service, addressCodec address.Codec, signerProvider SignerProvider, execRouter MsgRouter, @@ -77,12 +76,11 @@ func NewKeeper( keeper := Keeper{ storeService: ss, eventService: es, - branchExecutor: bs, addressCodec: addressCodec, - signerProvider: signerProvider, + branchExecutor: bs, msgRouter: execRouter, + signerProvider: signerProvider, queryRouter: queryRouter, - Schema: collections.Schema{}, AccountNumber: collections.NewSequence(sb, AccountNumberKey, "account_number"), AccountsByType: collections.NewMap(sb, AccountTypeKeyPrefix, "accounts_by_type", collections.BytesKey, collections.StringValue), AccountByNumber: collections.NewMap(sb, AccountByNumber, "account_by_number", collections.BytesKey, collections.Uint64Value), @@ -94,7 +92,7 @@ func NewKeeper( return Keeper{}, err } keeper.Schema = schema - keeper.accounts, err = implementation.MakeAccountsMap(keeper.addressCodec, accounts) + keeper.accounts, err = implementation.MakeAccountsMap(keeper.addressCodec, hs, accounts) if err != nil { return Keeper{}, err } @@ -107,7 +105,7 @@ type Keeper struct { storeService store.KVStoreService eventService event.Service addressCodec address.Codec - branchExecutor BranchExecutor + branchExecutor branch.Service msgRouter MsgRouter signerProvider SignerProvider queryRouter QueryRouter diff --git a/x/accounts/utils_test.go b/x/accounts/utils_test.go index 68adc2d94c6e..bcef6b963f26 100644 --- a/x/accounts/utils_test.go +++ b/x/accounts/utils_test.go @@ -47,7 +47,7 @@ func (i interfaceRegistry) RegisterImplementations(any, ...gogoproto.Message) {} func newKeeper(t *testing.T, accounts ...implementation.AccountCreatorFunc) (Keeper, context.Context) { t.Helper() ss, ctx := colltest.MockStore() - m, err := NewKeeper(ss, eventService{}, nil, addressCodec{}, nil, nil, nil, interfaceRegistry{}, accounts...) + m, err := NewKeeper(ss, eventService{}, nil, nil, addressCodec{}, nil, nil, nil, interfaceRegistry{}, accounts...) require.NoError(t, err) return m, ctx } From 5e6b9885efb638f169637fb674fa50c0f0ec7898 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Wed, 10 Jan 2024 18:19:51 +0100 Subject: [PATCH 20/28] chore: prepare log, errors and depinject minors (#19010) --- collections/CHANGELOG.md | 3 ++- depinject/CHANGELOG.md | 28 ++++++++++++++++++++++++++++ errors/CHANGELOG.md | 2 ++ log/CHANGELOG.md | 2 ++ x/upgrade/CHANGELOG.md | 8 ++++---- 5 files changed, 38 insertions(+), 5 deletions(-) create mode 100644 depinject/CHANGELOG.md diff --git a/collections/CHANGELOG.md b/collections/CHANGELOG.md index f0778efdfc92..f37430444665 100644 --- a/collections/CHANGELOG.md +++ b/collections/CHANGELOG.md @@ -32,7 +32,8 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] ### Features - * [#17656](https://github.com/cosmos/cosmos-sdk/pull/17656) – Introduces `Vec`, a collection type that allows to represent a growable array on top of a KVStore. + +* [#17656](https://github.com/cosmos/cosmos-sdk/pull/17656) – Introduces `Vec`, a collection type that allows to represent a growable array on top of a KVStore. ## [v0.4.0](https://github.com/cosmos/cosmos-sdk/releases/tag/collections%2Fv0.4.0) diff --git a/depinject/CHANGELOG.md b/depinject/CHANGELOG.md new file mode 100644 index 000000000000..19b60a6c1a3f --- /dev/null +++ b/depinject/CHANGELOG.md @@ -0,0 +1,28 @@ + + +# Changelog + +## [Unreleased] + +## 1.0.0-alpha.x + +Depinject is still in alpha stage even though its API is already quite stable. +There is no changelog during this stage. diff --git a/errors/CHANGELOG.md b/errors/CHANGELOG.md index 9330f2fe19b0..1787329cbe79 100644 --- a/errors/CHANGELOG.md +++ b/errors/CHANGELOG.md @@ -31,6 +31,8 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] +## [v1.0.1](https://github.com/cosmos/cosmos-sdk/releases/tag/errors%2Fv1.0.1) + ### Improvements * [#18918](https://github.com/cosmos/cosmos-sdk/pull/18918) Improve `IsOf` by returning earlier when the checked error is nil. diff --git a/log/CHANGELOG.md b/log/CHANGELOG.md index ffea96df0fc4..5b2147c45133 100644 --- a/log/CHANGELOG.md +++ b/log/CHANGELOG.md @@ -22,6 +22,8 @@ Each entry must include the Github issue reference in the following format: ## [Unreleased] +## [v1.3.0](https://github.com/cosmos/cosmos-sdk/releases/tag/log/v1.3.0) - 2023-01-10 + * [#18916](https://github.com/cosmos/cosmos-sdk/pull/18916) Introduce an option for setting hooks. * [#18429](https://github.com/cosmos/cosmos-sdk/pull/18429) Support customization of log json marshal. * [#18898](https://github.com/cosmos/cosmos-sdk/pull/18898) Add `WARN` level. diff --git a/x/upgrade/CHANGELOG.md b/x/upgrade/CHANGELOG.md index 5cd6aa136cc4..2df68319f5af 100644 --- a/x/upgrade/CHANGELOG.md +++ b/x/upgrade/CHANGELOG.md @@ -25,16 +25,16 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] +### State Machine Breaking + +* (x/upgrade) [#16244](https://github.com/cosmos/cosmos-sdk/pull/16244) Upgrade module no longer stores the app version but gets and sets the app version stored in the `ParamStore` of baseapp. + ## [v0.1.1](https://github.com/cosmos/cosmos-sdk/releases/tag/x/upgrade/v0.1.1) - 2023-12-11 ### Improvements * [#18470](https://github.com/cosmos/cosmos-sdk/pull/18470) Improve go-getter settings. -### State Machine Breaking - -* (x/upgrade) [#16244](https://github.com/cosmos/cosmos-sdk/pull/16244) Upgrade module no longer stores the app version but gets and sets the app version stored in the `ParamStore` of baseapp. - ## [v0.1.0](https://github.com/cosmos/cosmos-sdk/releases/tag/x/upgrade/v0.1.0) - 2023-11-07 ### Features From 8c6df364b7b5b2eeda3686d2e05e9032dd919174 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Wed, 10 Jan 2024 18:32:13 +0100 Subject: [PATCH 21/28] fix: change prehash value back to sha256 from noop (#19002) Co-authored-by: Damian Nolan Co-authored-by: Aleksandr Bezobchuk --- store/commit_info.go | 3 +++ store/proof.go | 52 +++++++++++++++++++++++++++++++++++++++----- store/proof_test.go | 12 +++++----- 3 files changed, 55 insertions(+), 12 deletions(-) diff --git a/store/commit_info.go b/store/commit_info.go index 4900c2f501de..e1b9d6c9152c 100644 --- a/store/commit_info.go +++ b/store/commit_info.go @@ -50,6 +50,9 @@ func (ci *CommitInfo) Hash() []byte { return rootHash } +// GetStoreProof takes in a storeKey and returns a proof of the store key in addition +// to the root hash it should be proved against. If an empty string is provided, the first +// store based on lexographical ordering will be proved. func (ci *CommitInfo) GetStoreProof(storeKey string) ([]byte, *CommitmentOp, error) { sort.Slice(ci.StoreInfos, func(i, j int) bool { return ci.StoreInfos[i].Name < ci.StoreInfos[j].Name diff --git a/store/proof.go b/store/proof.go index de46f5f317e7..71b32d9729b7 100644 --- a/store/proof.go +++ b/store/proof.go @@ -24,7 +24,7 @@ var ( LeafSpec: &ics23.LeafOp{ Prefix: leafPrefix, PrehashKey: ics23.HashOp_NO_HASH, - PrehashValue: ics23.HashOp_NO_HASH, + PrehashValue: ics23.HashOp_SHA256, Hash: ics23.HashOp_SHA256, Length: ics23.LengthOp_VAR_PROTO, }, @@ -122,7 +122,34 @@ func (op CommitmentOp) Run(args [][]byte) ([][]byte, error) { return [][]byte{root}, nil } -// ProofFromByteSlices computes the proof from the given leaves. +// ProofFromByteSlices computes the proof from the given leaves. An iteration will be +// perfomed for each level of the tree, where each iteration hashes together the bottom most +// nodes. If the length of the bottom most nodes is odd, then the last node will be saved +// for the next iteration. +// +// Example: +// Iteration 1: +// n = 5 +// leaves = a, b, c, d, e. +// index = 2 (prove c) +// +// Iteration 2: +// n = 3 +// leaves = ab, cd, e +// index = 1 (prove c, so index of cd) +// +// Iteration 3: +// n = 2 +// leaves = abcd, e +// index = 0 (prove c, so index of abcd) +// +// Final iteration: +// n = 1 +// leaves = abcde +// index = 0 +// +// The bitwise & operator allows us to determine if the index or length is odd or even. +// The bitwise ^ operator allows us to increment when the value is even and decrement when it is odd. func ProofFromByteSlices(leaves [][]byte, index int) (rootHash []byte, inners []*ics23.InnerOp) { if len(leaves) == 0 { return emptyHash(), nil @@ -130,23 +157,35 @@ func ProofFromByteSlices(leaves [][]byte, index int) (rootHash []byte, inners [] n := len(leaves) for n > 1 { + // Begin by constructing the proof for the inner node of the requested index. + // A proof of the inner node is skipped only in the case where the requested index + // is the last element and it does not have a leaf pair (resulting in it being + // saved until the next iteration). if index < n-1 || index&1 == 1 { inner := &ics23.InnerOp{Hash: ics23.HashOp_SHA256} + //Iif proof index is even then child is from left, suffix is populated + // otherwise, child is from right and the prefix is populated. if index&1 == 0 { + // inner op(prefix=0x01 | child | suffix=leaves[index+1]) inner.Prefix = innerPrefix - inner.Suffix = leaves[index^1] + inner.Suffix = leaves[index^1] // XOR op is index+1 because index is even } else { - inner.Prefix = append(innerPrefix, leaves[index^1]...) + // inner op(prefix=0x01 | leaves[index-1] | child | suffix=nil) + inner.Prefix = append(innerPrefix, leaves[index^1]...) // XOR op is index-1 because index is odd } inners = append(inners, inner) } + + // hash together all leaf pairs for i := 0; i < n/2; i++ { leaves[i] = InnerHash(leaves[2*i], leaves[2*i+1]) } + + // save any leftover leaf for the next iteration if n&1 == 1 { leaves[n/2] = leaves[n-1] } - n = (n + 1) / 2 + n = (n + 1) / 2 // n + 1 accounts for any leaves which are added to the next iteration index /= 2 } @@ -178,7 +217,8 @@ func LeafHash(key, value []byte) ([]byte, error) { return SimpleMerkleSpec.LeafSpec.Apply(key, value) } -// InnerHash computes the hash of an inner node. +// InnerHash computes the hash of an inner node as defined by ics23: +// https://github.com/cosmos/ics23/blob/go/v0.10.0/proto/cosmos/ics23/v1/proofs.proto#L130 func InnerHash(left, right []byte) []byte { data := make([]byte, len(innerPrefix)+len(left)+len(right)) n := copy(data, innerPrefix) diff --git a/store/proof_test.go b/store/proof_test.go index b7a7d4019310..31cf0fbdf512 100644 --- a/store/proof_test.go +++ b/store/proof_test.go @@ -14,29 +14,29 @@ func TestProofFromBytesSlices(t *testing.T) { want string }{ {[]string{}, []string{}, "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"}, - {[]string{"key1"}, []string{"value1"}, "09c468a07fe9bc1f14e754cff0acbad4faf9449449288be8e1d5d1199a247034"}, - {[]string{"key1"}, []string{"value2"}, "2131d85de3a8ded5d3a72bfc657f7324138540c520de7401ac8594785a3082fb"}, + {[]string{"key1"}, []string{"value1"}, "a44d3cc7daba1a4600b00a2434b30f8b970652169810d6dfa9fb1793a2189324"}, + {[]string{"key1"}, []string{"value2"}, "0638e99b3445caec9d95c05e1a3fc1487b4ddec6a952ff337080360b0dcc078c"}, // swap order with 2 keys { []string{"key1", "key2"}, []string{"value1", "value2"}, - "017788f37362dd0687beb59c0b3bfcc17a955120a4cb63dbdd4a0fdf9e07730e", + "8fd19b19e7bb3f2b3ee0574027d8a5a4cec370464ea2db2fbfa5c7d35bb0cff3", }, { []string{"key2", "key1"}, []string{"value2", "value1"}, - "ad2b0c23dbd3376440a5347fba02ff35cfad7930daa5e733930315b6fbb03b26", + "55d4bce1c53b7d394bd41bbfc2b239cc2e1c7e36423612a97181c47e79bb713c", }, // swap order with 3 keys { []string{"key1", "key2", "key3"}, []string{"value1", "value2", "value3"}, - "68f41a8a3508cb5f8eb3f1c7534a86fea9f59aa4898a5aac2f1bb92834ae2a36", + "1dd674ec6782a0d586a903c9c63326a41cbe56b3bba33ed6ff5b527af6efb3dc", }, { []string{"key1", "key3", "key2"}, []string{"value1", "value3", "value2"}, - "92cd50420c22d0c79f64dd1b04bfd5f5d73265f7ac37e65cf622f3cf8b963805", + "443382fbb629e0d50e86d6ea49e22aa4e27ba50262730b0122cec36860c903a2", }, } for i, tc := range tests { From 6db53cafcb54df89354c8640a96f87b6d468cc7a Mon Sep 17 00:00:00 2001 From: Marko Date: Thu, 11 Jan 2024 08:55:50 +0100 Subject: [PATCH 22/28] chore(sdk): remove modules as a dependency (1/n) (#19003) --- baseapp/block_gas_test.go | 12 +++++------- baseapp/expected_keepers.go | 17 +++++++++++++++++ client/rpc/rpc_test.go | 5 +---- testutil/network/util.go | 9 +++++---- testutil/sims/address_helpers.go | 19 +++++-------------- testutil/sims/expected_keepers.go | 19 +++++++++++++++++++ testutil/sims/simulation_helpers_test.go | 12 ++++++++---- testutil/sims/state_helpers.go | 9 +++++---- types/query/fuzz_test.go | 13 ++++++++----- 9 files changed, 73 insertions(+), 42 deletions(-) create mode 100644 baseapp/expected_keepers.go create mode 100644 testutil/sims/expected_keepers.go diff --git a/baseapp/block_gas_test.go b/baseapp/block_gas_test.go index bef8ef4d7571..d18b4807ddeb 100644 --- a/baseapp/block_gas_test.go +++ b/baseapp/block_gas_test.go @@ -14,11 +14,9 @@ import ( "cosmossdk.io/log" sdkmath "cosmossdk.io/math" store "cosmossdk.io/store/types" - authkeeper "cosmossdk.io/x/auth/keeper" xauthsigning "cosmossdk.io/x/auth/signing" - bankkeeper "cosmossdk.io/x/bank/keeper" - banktypes "cosmossdk.io/x/bank/types" + "github.com/cosmos/cosmos-sdk/baseapp" baseapptestutil "github.com/cosmos/cosmos-sdk/baseapp/testutil" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/tx" @@ -71,8 +69,8 @@ func TestBaseApp_BlockGas(t *testing.T) { for _, tc := range testcases { var ( - bankKeeper bankkeeper.Keeper - accountKeeper authkeeper.AccountKeeper + bankKeeper baseapp.BankKeeper + accountKeeper baseapp.AuthKeeper appBuilder *runtime.AppBuilder txConfig client.TxConfig cdc codec.Codec @@ -108,7 +106,7 @@ func TestBaseApp_BlockGas(t *testing.T) { baseapptestutil.RegisterKeyValueServer(bapp.MsgServiceRouter(), BlockGasImpl{ panicTx: tc.panicTx, gasToConsume: tc.gasToConsume, - key: bapp.UnsafeFindStoreKey(banktypes.ModuleName), + key: bapp.UnsafeFindStoreKey(testutil.BankModuleName), }) genState := GenesisStateWithSingleValidator(t, cdc, appBuilder) @@ -160,7 +158,7 @@ func TestBaseApp_BlockGas(t *testing.T) { // check result ctx = bapp.GetContextForFinalizeBlock(txBytes) - okValue := ctx.KVStore(bapp.UnsafeFindStoreKey(banktypes.ModuleName)).Get([]byte("ok")) + okValue := ctx.KVStore(bapp.UnsafeFindStoreKey(testutil.BankModuleName)).Get([]byte("ok")) if tc.expErr { if tc.panicTx { diff --git a/baseapp/expected_keepers.go b/baseapp/expected_keepers.go new file mode 100644 index 000000000000..26147f935ec9 --- /dev/null +++ b/baseapp/expected_keepers.go @@ -0,0 +1,17 @@ +package baseapp + +import ( + "context" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +type BankKeeper interface { + MintCoins(ctx context.Context, moduleName string, amt sdk.Coins) error + SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error + GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin +} + +type AuthKeeper interface { + GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI +} diff --git a/client/rpc/rpc_test.go b/client/rpc/rpc_test.go index e8b4635eee79..7606602127f4 100644 --- a/client/rpc/rpc_test.go +++ b/client/rpc/rpc_test.go @@ -2,7 +2,6 @@ package rpc_test import ( "context" - "fmt" "strconv" "testing" @@ -11,8 +10,6 @@ import ( "google.golang.org/grpc" "google.golang.org/grpc/metadata" - banktypes "cosmossdk.io/x/bank/types" - "github.com/cosmos/cosmos-sdk/testutil/network" "github.com/cosmos/cosmos-sdk/testutil/testdata" "github.com/cosmos/cosmos-sdk/types/address" @@ -97,7 +94,7 @@ func (s *IntegrationTestSuite) TestQueryABCIHeight() { clientCtx = clientCtx.WithHeight(tc.ctxHeight) req := abci.RequestQuery{ - Path: fmt.Sprintf("store/%s/key", banktypes.StoreKey), + Path: "store/bank/key", Height: tc.reqHeight, Data: address.MustLengthPrefix(val.GetAddress()), Prove: true, diff --git a/testutil/network/util.go b/testutil/network/util.go index 3b75cc3d6e06..702c195aa404 100644 --- a/testutil/network/util.go +++ b/testutil/network/util.go @@ -26,6 +26,7 @@ import ( "github.com/cosmos/cosmos-sdk/server/api" servergrpc "github.com/cosmos/cosmos-sdk/server/grpc" servercmtlog "github.com/cosmos/cosmos-sdk/server/log" + "github.com/cosmos/cosmos-sdk/testutil" "github.com/cosmos/cosmos-sdk/x/genutil" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" ) @@ -166,7 +167,7 @@ func collectGenFiles(cfg Config, vals []*Validator, outputDir string) error { func initGenFiles(cfg Config, genAccounts []authtypes.GenesisAccount, genBalances []banktypes.Balance, genFiles []string) error { // set the accounts in the genesis state var authGenState authtypes.GenesisState - cfg.Codec.MustUnmarshalJSON(cfg.GenesisState[authtypes.ModuleName], &authGenState) + cfg.Codec.MustUnmarshalJSON(cfg.GenesisState[testutil.AuthModuleName], &authGenState) accounts, err := authtypes.PackAccounts(genAccounts) if err != nil { @@ -174,14 +175,14 @@ func initGenFiles(cfg Config, genAccounts []authtypes.GenesisAccount, genBalance } authGenState.Accounts = append(authGenState.Accounts, accounts...) - cfg.GenesisState[authtypes.ModuleName] = cfg.Codec.MustMarshalJSON(&authGenState) + cfg.GenesisState[testutil.AuthModuleName] = cfg.Codec.MustMarshalJSON(&authGenState) // set the balances in the genesis state var bankGenState banktypes.GenesisState - cfg.Codec.MustUnmarshalJSON(cfg.GenesisState[banktypes.ModuleName], &bankGenState) + cfg.Codec.MustUnmarshalJSON(cfg.GenesisState[testutil.BankModuleName], &bankGenState) bankGenState.Balances = append(bankGenState.Balances, genBalances...) - cfg.GenesisState[banktypes.ModuleName] = cfg.Codec.MustMarshalJSON(&bankGenState) + cfg.GenesisState[testutil.BankModuleName] = cfg.Codec.MustMarshalJSON(&bankGenState) appGenStateJSON, err := json.MarshalIndent(cfg.GenesisState, "", " ") if err != nil { diff --git a/testutil/sims/address_helpers.go b/testutil/sims/address_helpers.go index 7425f1e8a89f..0f6d85e275cc 100644 --- a/testutil/sims/address_helpers.go +++ b/testutil/sims/address_helpers.go @@ -2,14 +2,12 @@ package sims import ( "bytes" - "context" "encoding/hex" "fmt" "strconv" errorsmod "cosmossdk.io/errors" "cosmossdk.io/math" - bankkeeper "cosmossdk.io/x/bank/keeper" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" @@ -21,15 +19,8 @@ const mintModuleName = "mint" type GenerateAccountStrategy func(int) []sdk.AccAddress -// BondDenomProvider is a subset of the staking keeper's public interface that -// provides the staking bond denom. It is used in arguments in this package's -// functions so that a mock staking keeper can be passed instead of the real one. -type BondDenomProvider interface { - BondDenom(ctx context.Context) (string, error) -} - // AddTestAddrsFromPubKeys adds the addresses into the SimApp providing only the public keys. -func AddTestAddrsFromPubKeys(bankKeeper bankkeeper.Keeper, stakingKeeper BondDenomProvider, ctx sdk.Context, pubKeys []cryptotypes.PubKey, accAmt math.Int) { +func AddTestAddrsFromPubKeys(bankKeeper BankKeeper, stakingKeeper StakingKeeper, ctx sdk.Context, pubKeys []cryptotypes.PubKey, accAmt math.Int) { bondDenom, err := stakingKeeper.BondDenom(ctx) if err != nil { panic(err) @@ -43,16 +34,16 @@ func AddTestAddrsFromPubKeys(bankKeeper bankkeeper.Keeper, stakingKeeper BondDen // AddTestAddrs constructs and returns accNum amount of accounts with an // initial balance of accAmt in random order -func AddTestAddrs(bankKeeper bankkeeper.Keeper, stakingKeeper BondDenomProvider, ctx sdk.Context, accNum int, accAmt math.Int) []sdk.AccAddress { +func AddTestAddrs(bankKeeper BankKeeper, stakingKeeper StakingKeeper, ctx sdk.Context, accNum int, accAmt math.Int) []sdk.AccAddress { return addTestAddrs(bankKeeper, stakingKeeper, ctx, accNum, accAmt, CreateRandomAccounts) } // AddTestAddrsIncremental constructs and returns accNum amount of accounts with an initial balance of accAmt in random order -func AddTestAddrsIncremental(bankKeeper bankkeeper.Keeper, stakingKeeper BondDenomProvider, ctx sdk.Context, accNum int, accAmt math.Int) []sdk.AccAddress { +func AddTestAddrsIncremental(bankKeeper BankKeeper, stakingKeeper StakingKeeper, ctx sdk.Context, accNum int, accAmt math.Int) []sdk.AccAddress { return addTestAddrs(bankKeeper, stakingKeeper, ctx, accNum, accAmt, CreateIncrementalAccounts) } -func addTestAddrs(bankKeeper bankkeeper.Keeper, stakingKeeper BondDenomProvider, ctx sdk.Context, accNum int, accAmt math.Int, strategy GenerateAccountStrategy) []sdk.AccAddress { +func addTestAddrs(bankKeeper BankKeeper, stakingKeeper StakingKeeper, ctx sdk.Context, accNum int, accAmt math.Int, strategy GenerateAccountStrategy) []sdk.AccAddress { testAddrs := strategy(accNum) bondDenom, err := stakingKeeper.BondDenom(ctx) if err != nil { @@ -67,7 +58,7 @@ func addTestAddrs(bankKeeper bankkeeper.Keeper, stakingKeeper BondDenomProvider, return testAddrs } -func initAccountWithCoins(bankKeeper bankkeeper.Keeper, ctx sdk.Context, addr sdk.AccAddress, coins sdk.Coins) { +func initAccountWithCoins(bankKeeper BankKeeper, ctx sdk.Context, addr sdk.AccAddress, coins sdk.Coins) { if err := bankKeeper.MintCoins(ctx, mintModuleName, coins); err != nil { panic(err) } diff --git a/testutil/sims/expected_keepers.go b/testutil/sims/expected_keepers.go new file mode 100644 index 000000000000..5a6d9c9f0f5d --- /dev/null +++ b/testutil/sims/expected_keepers.go @@ -0,0 +1,19 @@ +package sims + +import ( + "context" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +type BankKeeper interface { + SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error + MintCoins(ctx context.Context, moduleName string, amt sdk.Coins) error +} + +// StakingKeeper is a subset of the staking keeper's public interface that +// provides the staking bond denom. It is used in arguments in this package's +// functions so that a mock staking keeper can be passed instead of the real one. +type StakingKeeper interface { + BondDenom(ctx context.Context) (string, error) +} diff --git a/testutil/sims/simulation_helpers_test.go b/testutil/sims/simulation_helpers_test.go index dd30429745c3..b22c86e40c92 100644 --- a/testutil/sims/simulation_helpers_test.go +++ b/testutil/sims/simulation_helpers_test.go @@ -12,17 +12,21 @@ import ( "cosmossdk.io/store/metrics" "cosmossdk.io/store/rootmulti" storetypes "cosmossdk.io/store/types" - authtypes "cosmossdk.io/x/auth/types" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" "github.com/cosmos/cosmos-sdk/types/simulation" ) +const ( + authStoreKey = "acc" + GlobalAccountNumberKey = 0x1 +) + func TestGetSimulationLog(t *testing.T) { legacyAmino := codec.NewLegacyAmino() decoders := make(simulation.StoreDecoderRegistry) - decoders[authtypes.StoreKey] = func(kvAs, kvBs kv.Pair) string { return "10" } + decoders[authStoreKey] = func(kvAs, kvBs kv.Pair) string { return "10" } tests := []struct { store string @@ -35,8 +39,8 @@ func TestGetSimulationLog(t *testing.T) { "", }, { - authtypes.StoreKey, - []kv.Pair{{Key: authtypes.GlobalAccountNumberKey, Value: legacyAmino.MustMarshal(uint64(10))}}, + authStoreKey, + []kv.Pair{{Key: []byte{GlobalAccountNumberKey}, Value: legacyAmino.MustMarshal(uint64(10))}}, "10", }, { diff --git a/testutil/sims/state_helpers.go b/testutil/sims/state_helpers.go index 3c1575a2e4d2..031a6125ca1b 100644 --- a/testutil/sims/state_helpers.go +++ b/testutil/sims/state_helpers.go @@ -20,6 +20,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" @@ -134,7 +135,7 @@ func AppStateFnWithExtendedCbs( } notBondedCoins := sdk.NewCoin(stakingState.Params.BondDenom, notBondedTokens) // edit bank state to make it have the not bonded pool tokens - bankStateBz, ok := rawState[banktypes.ModuleName] + bankStateBz, ok := rawState[testutil.BankModuleName] // TODO(fdymylja/jonathan): should we panic in this case if !ok { panic("bank genesis state is missing") @@ -162,7 +163,7 @@ func AppStateFnWithExtendedCbs( // change appState back for name, state := range map[string]proto.Message{ stakingtypes.ModuleName: stakingState, - banktypes.ModuleName: bankState, + testutil.BankModuleName: bankState, } { if moduleStateCb != nil { moduleStateCb(name, state) @@ -269,8 +270,8 @@ func AppStateFromGenesisFileFn(r io.Reader, cdc codec.JSONCodec, genesisFile str } var authGenesis authtypes.GenesisState - if appState[authtypes.ModuleName] != nil { - cdc.MustUnmarshalJSON(appState[authtypes.ModuleName], &authGenesis) + if appState[testutil.AuthModuleName] != nil { + cdc.MustUnmarshalJSON(appState[testutil.AuthModuleName], &authGenesis) } newAccs := make([]simtypes.Account, len(authGenesis.Accounts)) diff --git a/types/query/fuzz_test.go b/types/query/fuzz_test.go index 8ce7f4715da3..e3f47d38f83a 100644 --- a/types/query/fuzz_test.go +++ b/types/query/fuzz_test.go @@ -9,13 +9,17 @@ import ( "cosmossdk.io/math" "cosmossdk.io/store/prefix" "cosmossdk.io/x/bank/testutil" - "cosmossdk.io/x/bank/types" + sdktestutil "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/address" "github.com/cosmos/cosmos-sdk/types/query" ) +const ( + balancesPrefix = 0x2 +) + type fuzzTestSuite struct { paginationTestSuite } @@ -80,12 +84,11 @@ func FuzzPagination(f *testing.F) { } // Now try to paginate it. - req := types.NewQueryAllBalancesRequest(addr1, qr, false) balResult := sdk.NewCoins() - authStore := suite.ctx.KVStore(suite.app.UnsafeFindStoreKey(types.StoreKey)) - balancesStore := prefix.NewStore(authStore, types.BalancesPrefix) + authStore := suite.ctx.KVStore(suite.app.UnsafeFindStoreKey(sdktestutil.BankModuleName)) + balancesStore := prefix.NewStore(authStore, []byte{balancesPrefix}) accountStore := prefix.NewStore(balancesStore, address.MustLengthPrefix(addr1)) - _, _ = query.Paginate(accountStore, req.Pagination, func(key, value []byte) error { + _, _ = query.Paginate(accountStore, qr, func(key, value []byte) error { var amount math.Int err := amount.Unmarshal(value) if err != nil { From f80f231dcce97cab6f25dbeeaeb111f3d58b99bb Mon Sep 17 00:00:00 2001 From: Marko Date: Thu, 11 Jan 2024 11:02:43 +0100 Subject: [PATCH 23/28] chore(mocks): regenerate mocks (#19027) --- store/go.sum | 4 ++-- testutil/mock/logger.go | 17 ----------------- x/accounts/go.mod | 2 +- x/gov/testutil/expected_keepers_mocks.go | 15 +++++++++++++++ 4 files changed, 18 insertions(+), 20 deletions(-) diff --git a/store/go.sum b/store/go.sum index 8d4086be9ef3..d02c052f8c67 100644 --- a/store/go.sum +++ b/store/go.sum @@ -334,5 +334,5 @@ gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= -gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= +gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= +gotest.tools/v3 v3.5.0/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= diff --git a/testutil/mock/logger.go b/testutil/mock/logger.go index 800210aa241e..b17f076d0255 100644 --- a/testutil/mock/logger.go +++ b/testutil/mock/logger.go @@ -99,23 +99,6 @@ func (mr *MockLoggerMockRecorder) Info(arg0 interface{}, arg1 ...interface{}) *g return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Info", reflect.TypeOf((*MockLogger)(nil).Info), varargs...) } -// Warn mocks base method. -func (m *MockLogger) Warn(arg0 string, arg1 ...interface{}) { - m.ctrl.T.Helper() - varargs := []interface{}{arg0} - for _, a := range arg1 { - varargs = append(varargs, a) - } - m.ctrl.Call(m, "Warn", varargs...) -} - -// Warn indicates an expected call of Warn. -func (mr *MockLoggerMockRecorder) Warn(arg0 interface{}, arg1 ...interface{}) *gomock.Call { - mr.mock.ctrl.T.Helper() - varargs := append([]interface{}{arg0}, arg1...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Warn", reflect.TypeOf((*MockLogger)(nil).Warn), varargs...) -} - // With mocks base method. func (m *MockLogger) With(arg0 ...interface{}) log.Logger { m.ctrl.T.Helper() diff --git a/x/accounts/go.mod b/x/accounts/go.mod index 0c461991a9a9..da29c0247c0f 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -6,7 +6,6 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 - github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/cosmos/cosmos-sdk v0.51.0 github.com/cosmos/gogoproto v1.4.11 github.com/grpc-ecosystem/grpc-gateway v1.16.0 @@ -45,6 +44,7 @@ require ( github.com/cometbft/cometbft-db v0.8.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-db v1.0.0 // indirect + github.com/cosmos/cosmos-proto v1.0.0-beta.3 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect github.com/cosmos/iavl v1.0.0 // indirect diff --git a/x/gov/testutil/expected_keepers_mocks.go b/x/gov/testutil/expected_keepers_mocks.go index 7ffec09d3e00..78c9e669385f 100644 --- a/x/gov/testutil/expected_keepers_mocks.go +++ b/x/gov/testutil/expected_keepers_mocks.go @@ -315,6 +315,21 @@ func (mr *MockBankKeeperMockRecorder) DenomOwners(arg0, arg1 interface{}) *gomoc return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DenomOwners", reflect.TypeOf((*MockBankKeeper)(nil).DenomOwners), arg0, arg1) } +// DenomOwnersByQuery mocks base method. +func (m *MockBankKeeper) DenomOwnersByQuery(arg0 context.Context, arg1 *types.QueryDenomOwnersByQueryRequest) (*types.QueryDenomOwnersByQueryResponse, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "DenomOwnersByQuery", arg0, arg1) + ret0, _ := ret[0].(*types.QueryDenomOwnersByQueryResponse) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// DenomOwnersByQuery indicates an expected call of DenomOwnersByQuery. +func (mr *MockBankKeeperMockRecorder) DenomOwnersByQuery(arg0, arg1 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DenomOwnersByQuery", reflect.TypeOf((*MockBankKeeper)(nil).DenomOwnersByQuery), arg0, arg1) +} + // DenomsMetadata mocks base method. func (m *MockBankKeeper) DenomsMetadata(arg0 context.Context, arg1 *types.QueryDenomsMetadataRequest) (*types.QueryDenomsMetadataResponse, error) { m.ctrl.T.Helper() From 390750f7d40a08ac99bbcc8689c79849d3b049b2 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Thu, 11 Jan 2024 12:16:40 +0100 Subject: [PATCH 24/28] refactor(client/v2): use address codec instead of global (#19026) --- client/v2/autocli/builder.go | 31 +----------------------------- client/v2/autocli/flag/address.go | 7 +++++-- client/v2/autocli/flag/builder.go | 32 +++++++++++++++++++++++++++++++ client/v2/autocli/query_test.go | 1 - 4 files changed, 38 insertions(+), 33 deletions(-) diff --git a/client/v2/autocli/builder.go b/client/v2/autocli/builder.go index 98c50ddf6551..bc32867ad30c 100644 --- a/client/v2/autocli/builder.go +++ b/client/v2/autocli/builder.go @@ -1,13 +1,10 @@ package autocli import ( - "errors" - "github.com/spf13/cobra" "google.golang.org/grpc" "cosmossdk.io/client/v2/autocli/flag" - "cosmossdk.io/client/v2/autocli/keyring" authtx "cosmossdk.io/x/auth/tx" "github.com/cosmos/cosmos-sdk/client" @@ -35,32 +32,6 @@ type Builder struct { // ValidateAndComplete the builder fields. // It returns an error if any of the required fields are missing. -// If the Logger is nil, it will be set to a nop logger. -// If the keyring is nil, it will be set to a no keyring. func (b *Builder) ValidateAndComplete() error { - if b.Builder.AddressCodec == nil { - return errors.New("address codec is required in flag builder") - } - - if b.Builder.ValidatorAddressCodec == nil { - return errors.New("validator address codec is required in flag builder") - } - - if b.Builder.ConsensusAddressCodec == nil { - return errors.New("consensus address codec is required in flag builder") - } - - if b.Builder.Keyring == nil { - b.Keyring = keyring.NoKeyring{} - } - - if b.Builder.TypeResolver == nil { - return errors.New("type resolver is required in flag builder") - } - - if b.Builder.FileResolver == nil { - return errors.New("file resolver is required in flag builder") - } - - return nil + return b.Builder.ValidateAndComplete() } diff --git a/client/v2/autocli/flag/address.go b/client/v2/autocli/flag/address.go index ddc7e6bf2c08..507a7267a9fc 100644 --- a/client/v2/autocli/flag/address.go +++ b/client/v2/autocli/flag/address.go @@ -13,7 +13,6 @@ import ( "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" - sdk "github.com/cosmos/cosmos-sdk/types" ) type addressStringType struct{} @@ -133,6 +132,10 @@ func (a *consensusAddressValue) Set(s string) error { return fmt.Errorf("input isn't a pubkey %w or is an invalid account address: %w", err, err2) } - a.value = sdk.ConsAddress(pk.Address()).String() + a.value, err = a.addressCodec.BytesToString(pk.Address()) + if err != nil { + return fmt.Errorf("invalid pubkey address: %w", err) + } + return nil } diff --git a/client/v2/autocli/flag/builder.go b/client/v2/autocli/flag/builder.go index da3f434bc0d8..a30f809dc720 100644 --- a/client/v2/autocli/flag/builder.go +++ b/client/v2/autocli/flag/builder.go @@ -2,6 +2,7 @@ package flag import ( "context" + "errors" "fmt" "strconv" @@ -73,6 +74,37 @@ func (b *Builder) init() { } } +// ValidateAndComplete the flag builder fields. +// It returns an error if any of the required fields are missing. +// If the keyring is nil, it will be set to a no keyring. +func (b *Builder) ValidateAndComplete() error { + if b.AddressCodec == nil { + return errors.New("address codec is required in flag builder") + } + + if b.ValidatorAddressCodec == nil { + return errors.New("validator address codec is required in flag builder") + } + + if b.ConsensusAddressCodec == nil { + return errors.New("consensus address codec is required in flag builder") + } + + if b.Keyring == nil { + b.Keyring = keyring.NoKeyring{} + } + + if b.TypeResolver == nil { + return errors.New("type resolver is required in flag builder") + } + + if b.FileResolver == nil { + return errors.New("file resolver is required in flag builder") + } + + return nil +} + // DefineMessageFlagType allows to extend custom protobuf message type handling for flags (and positional arguments). func (b *Builder) DefineMessageFlagType(messageName protoreflect.FullName, flagType Type) { b.init() diff --git a/client/v2/autocli/query_test.go b/client/v2/autocli/query_test.go index b1945f83995a..6ed940bb6faf 100644 --- a/client/v2/autocli/query_test.go +++ b/client/v2/autocli/query_test.go @@ -729,6 +729,5 @@ func TestDurationMarshal(t *testing.T) { out, err := runCmd(fixture.conn, fixture.b, buildModuleQueryCommand, "echo", "1", "abc", "--duration", "1s") assert.NilError(t, err) - fmt.Println(out.String()) assert.Assert(t, strings.Contains(out.String(), "duration: 1s")) } From 625401daf05819b546f6426ec0687bf8a10c2396 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 14:00:14 +0100 Subject: [PATCH 25/28] build(deps): Bump cosmossdk.io/errors from 1.0.0 to 1.0.1 (#19016) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Julien Robert --- client/v2/go.mod | 8 ++++---- client/v2/go.sum | 16 ++++++++-------- go.mod | 8 ++++---- go.sum | 16 ++++++++-------- orm/go.mod | 10 +++++----- orm/go.sum | 20 +++++++++---------- simapp/go.mod | 16 ++++++++++------ simapp/go.sum | 33 ++++++++++++++++++++++---------- simapp/gomod2nix.toml | 38 ++++++++++++++++++++++++------------- store/go.mod | 4 ++-- store/go.sum | 8 ++++---- tests/go.mod | 16 ++++++++++------ tests/go.sum | 33 ++++++++++++++++++++++---------- tests/starship/tests/go.mod | 16 ++++++++++------ tests/starship/tests/go.sum | 33 ++++++++++++++++++++++---------- testutil/mock/logger.go | 17 +++++++++++++++++ tools/confix/go.mod | 8 ++++---- tools/confix/go.sum | 16 ++++++++-------- tools/cosmovisor/go.mod | 15 ++++++++++----- tools/cosmovisor/go.sum | 33 ++++++++++++++++++++++---------- tools/hubl/go.mod | 8 ++++---- tools/hubl/go.sum | 16 ++++++++-------- x/accounts/go.mod | 8 ++++---- x/accounts/go.sum | 16 ++++++++-------- x/auth/go.mod | 8 ++++---- x/auth/go.sum | 16 ++++++++-------- x/authz/go.mod | 8 ++++---- x/authz/go.sum | 16 ++++++++-------- x/bank/go.mod | 8 ++++---- x/bank/go.sum | 16 ++++++++-------- x/circuit/go.mod | 8 ++++---- x/circuit/go.sum | 16 ++++++++-------- x/distribution/go.mod | 8 ++++---- x/distribution/go.sum | 16 ++++++++-------- x/evidence/go.mod | 8 ++++---- x/evidence/go.sum | 16 ++++++++-------- x/feegrant/go.mod | 8 ++++---- x/feegrant/go.sum | 16 ++++++++-------- x/gov/go.mod | 8 ++++---- x/gov/go.sum | 16 ++++++++-------- x/group/go.mod | 8 ++++---- x/group/go.sum | 16 ++++++++-------- x/mint/go.mod | 8 ++++---- x/mint/go.sum | 16 ++++++++-------- x/nft/go.mod | 8 ++++---- x/nft/go.sum | 16 ++++++++-------- x/params/go.mod | 8 ++++---- x/params/go.sum | 16 ++++++++-------- x/protocolpool/go.mod | 8 ++++---- x/protocolpool/go.sum | 16 ++++++++-------- x/slashing/go.mod | 8 ++++---- x/slashing/go.sum | 16 ++++++++-------- x/staking/go.mod | 8 ++++---- x/staking/go.sum | 16 ++++++++-------- x/tx/go.mod | 10 +++++----- x/tx/go.sum | 20 +++++++++---------- x/upgrade/go.mod | 15 ++++++++++----- x/upgrade/go.sum | 33 ++++++++++++++++++++++---------- 58 files changed, 483 insertions(+), 367 deletions(-) diff --git a/client/v2/go.mod b/client/v2/go.mod index 6d281f99275a..61cd1e07ea73 100644 --- a/client/v2/go.mod +++ b/client/v2/go.mod @@ -24,7 +24,7 @@ require ( require ( cosmossdk.io/collections v0.4.0 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/log v1.2.1 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect @@ -156,9 +156,9 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/client/v2/go.sum b/client/v2/go.sum index 3cfefc2a7f0f..2eaf457eebdb 100644 --- a/client/v2/go.sum +++ b/client/v2/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -937,12 +937,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/go.mod b/go.mod index f6aea49a663f..bd079a7f73c8 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -57,7 +57,7 @@ require ( golang.org/x/crypto v0.18.0 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b golang.org/x/sync v0.6.0 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -163,8 +163,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/go.sum b/go.sum index acd42833b797..a7db906df47a 100644 --- a/go.sum +++ b/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -963,12 +963,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/orm/go.mod b/orm/go.mod index 5149edc3383e..14433523c2e4 100644 --- a/orm/go.mod +++ b/orm/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.2 cosmossdk.io/core v0.11.0 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 github.com/cosmos/cosmos-db v1.0.0 github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/golang/mock v1.6.0 @@ -60,11 +60,11 @@ require ( github.com/spf13/cast v1.5.1 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect golang.org/x/net v0.19.0 // indirect - golang.org/x/sys v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) diff --git a/orm/go.sum b/orm/go.sum index a7f10310c7e2..f5554f9cd72f 100644 --- a/orm/go.sum +++ b/orm/go.sum @@ -2,8 +2,8 @@ cosmossdk.io/api v0.7.2 h1:BO3i5fvKMKvfaUiMkCznxViuBEfyWA/k6w2eAF6q1C4= cosmossdk.io/api v0.7.2/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -201,8 +201,8 @@ golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.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/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -222,12 +222,12 @@ golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.60.1 h1:26+wFr+cNqSGFcOXcabYC0lUVJVRa2Sb2ortSK7VrEU= google.golang.org/grpc v1.60.1/go.mod h1:OlCHIeLYqSSsLi6i49B5QGdzaMZK9+M7LXN2FKz4eGM= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= diff --git a/simapp/go.mod b/simapp/go.mod index 6963edadf888..e2bbb8d8107c 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -48,12 +48,12 @@ require ( ) require ( - cloud.google.com/go v0.110.10 // indirect + cloud.google.com/go v0.111.0 // indirect cloud.google.com/go/compute v1.23.3 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/iam v1.1.5 // indirect cloud.google.com/go/storage v1.35.1 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect filippo.io/edwards25519 v1.0.0 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.2 // indirect @@ -103,6 +103,8 @@ require ( github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect @@ -192,6 +194,9 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect @@ -204,12 +209,11 @@ require ( golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect - golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect google.golang.org/api v0.153.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/grpc v1.60.1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/simapp/go.sum b/simapp/go.sum index 6a3ef953523c..b363b7319ae4 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= +cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -188,8 +188,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -455,6 +455,11 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= @@ -1043,6 +1048,14 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= +go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= @@ -1599,12 +1612,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/simapp/gomod2nix.toml b/simapp/gomod2nix.toml index c179d412a208..ff57326c2957 100644 --- a/simapp/gomod2nix.toml +++ b/simapp/gomod2nix.toml @@ -2,8 +2,8 @@ schema = 3 [mod] [mod."cloud.google.com/go"] - version = "v0.110.10" - hash = "sha256-D+V6LaCiCdthJ6W0s220Dyqa7/iReEIv5vqxtOGvy/A=" + version = "v0.111.0" + hash = "sha256-i8tQyny5W/PcPY5W5h2Zo6wKDKgYHpQlK77QU9TUdI4=" [mod."cloud.google.com/go/compute"] version = "v1.23.3" hash = "sha256-WwlTw/x9GSM6B4nHm9FDvHZ1Pd4KN0wxk650CosJnpQ=" @@ -23,8 +23,8 @@ schema = 3 version = "v0.12.1-0.20231114100755-569e3ff6a0d7" hash = "sha256-I74lq2kZ9hOcvOU4uJZ8LhSoQ0RbgCvAvSXj1xI0iII=" [mod."cosmossdk.io/errors"] - version = "v1.0.0" - hash = "sha256-ZD1fhIefk3qkt9I4+ed9NBmBqTDvym9cXWmgFBh5qu0=" + version = "v1.0.1" + hash = "sha256-MgTocXkBzri9FKkNtkARJXPmxRrRO/diQJS5ZzvYrJY=" [mod."cosmossdk.io/log"] version = "v1.2.1" hash = "sha256-2Mb0jQ5Yvi+2fvhCVEiiacwODXM8+6vhsKOnHz+wsiY=" @@ -194,6 +194,12 @@ schema = 3 [mod."github.com/go-logfmt/logfmt"] version = "v0.6.0" hash = "sha256-RtIG2qARd5sT10WQ7F3LR8YJhS8exs+KiuUiVf75bWg=" + [mod."github.com/go-logr/logr"] + version = "v1.2.4" + hash = "sha256-+FhzmqKsAnsra5p8LuxENXJBHSeuWjQG8Tzhpyd/ps4=" + [mod."github.com/go-logr/stdr"] + version = "v1.2.2" + hash = "sha256-rRweAP7XIb4egtT1f2gkz4sYOu7LDHmcJ5iNsJUd0sE=" [mod."github.com/godbus/dbus"] version = "v0.0.0-20190726142602-4481cbc300e2" hash = "sha256-R7Gb9+Zjy80FbQSDGketoVEqfdOQKuOVTfWRjQ5kxZY=" @@ -480,6 +486,15 @@ schema = 3 [mod."go.opencensus.io"] version = "v0.24.0" hash = "sha256-4H+mGZgG2c9I1y0m8avF4qmt8LUKxxVsTqR8mKgP4yo=" + [mod."go.opentelemetry.io/otel"] + version = "v1.19.0" + hash = "sha256-y51fwO/y73QBdwwRnCp+wrvVuWLeqfSnU/I8i4mBK84=" + [mod."go.opentelemetry.io/otel/metric"] + version = "v1.19.0" + hash = "sha256-eYeeR8XUPjoF6lY3Yg1VUL0dPum/18KAcpo5k6zY67E=" + [mod."go.opentelemetry.io/otel/trace"] + version = "v1.19.0" + hash = "sha256-EVsShx1IO0zpMztSfqYQ32Gm+hV4wrVM8wWkEfHOaoM=" [mod."go.uber.org/multierr"] version = "v1.11.0" hash = "sha256-Lb6rHHfR62Ozg2j2JZy3MKOMKdsfzd1IYTR57r3Mhp0=" @@ -516,9 +531,6 @@ schema = 3 [mod."golang.org/x/tools"] version = "v0.16.0" hash = "sha256-uVAW8zkeyMvPaWjXjyvq+DCfuA348YtwCrXzNROs7EQ=" - [mod."golang.org/x/xerrors"] - version = "v0.0.0-20231012003039-104605ab7028" - hash = "sha256-IsFTm5WZQ6W1ZDF8WOP+6xiOAc7pIq8r9Afvkjp3PRQ=" [mod."google.golang.org/api"] version = "v0.153.0" hash = "sha256-NoWd/eDds+9dc6iSW55rIyNy/7NloKrY+zjUsEN2sgo=" @@ -526,14 +538,14 @@ schema = 3 version = "v1.6.8" hash = "sha256-decMa0MiWfW/Bzr8QPPzzpeya0YWGHhZAt4Cr/bD1wQ=" [mod."google.golang.org/genproto"] - version = "v0.0.0-20231211222908-989df2bf70f3" - hash = "sha256-7DvusxTmchjQbVzN4ph4p5EYvfQQwDg+lo9nk8qDwXY=" + version = "v0.0.0-20240102182953-50ed04b92917" + hash = "sha256-iTzbVZIeGfcI/ZnDJqJZDxBCJ2J6vlYVdpE7wJX0sXI=" [mod."google.golang.org/genproto/googleapis/api"] - version = "v0.0.0-20231120223509-83a465c0220f" - hash = "sha256-hWz9HrHPPPmWxOZ+VdpayDHCN79UMxrnQ66wTDE1lvY=" - [mod."google.golang.org/genproto/googleapis/rpc"] version = "v0.0.0-20231212172506-995d672761c0" - hash = "sha256-48aeFcLvuthyG7x9JmpeySrBkOqRhu+FgECjt1167IY=" + hash = "sha256-K85oYmTXZlQ+dOtyL4k1Oy6Qql2uqRUBOk+9TvRlPpE=" + [mod."google.golang.org/genproto/googleapis/rpc"] + version = "v0.0.0-20240108191215-35c7eff3a6b1" + hash = "sha256-bwWoFG+H827aJ3VunK7emdQz3BQlTTjWlM513kTZqSo=" [mod."google.golang.org/grpc"] version = "v1.60.1" hash = "sha256-JJ3X6DTUZWYtM8i8izWTH9nDvCydzea31iZt6ULDvsw=" diff --git a/store/go.mod b/store/go.mod index ce1e8ecea20e..7a83d636c967 100644 --- a/store/go.mod +++ b/store/go.mod @@ -4,7 +4,7 @@ go 1.21 require ( cosmossdk.io/core v0.12.0 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 github.com/cockroachdb/errors v1.11.1 github.com/cockroachdb/pebble v1.0.0 @@ -62,7 +62,7 @@ require ( golang.org/x/net v0.19.0 // indirect golang.org/x/sys v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/grpc v1.60.1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/store/go.sum b/store/go.sum index d02c052f8c67..bbd8476cd1b4 100644 --- a/store/go.sum +++ b/store/go.sum @@ -1,5 +1,5 @@ -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= @@ -303,8 +303,8 @@ golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.60.1 h1:26+wFr+cNqSGFcOXcabYC0lUVJVRa2Sb2ortSK7VrEU= google.golang.org/grpc v1.60.1/go.mod h1:OlCHIeLYqSSsLi6i49B5QGdzaMZK9+M7LXN2FKz4eGM= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= diff --git a/tests/go.mod b/tests/go.mod index f74fd5df0c3c..839c8e79dccf 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/simapp v0.0.0-20230309163709-87da587416ba @@ -49,7 +49,7 @@ require ( ) require ( - cloud.google.com/go v0.110.10 // indirect + cloud.google.com/go v0.111.0 // indirect cloud.google.com/go/compute v1.23.3 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/iam v1.1.5 // indirect @@ -102,6 +102,8 @@ require ( github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect @@ -188,6 +190,9 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect @@ -200,12 +205,11 @@ require ( golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect - golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect google.golang.org/api v0.153.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/tests/go.sum b/tests/go.sum index 0d8a193a5e3d..fecf5c588006 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= +cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -188,8 +188,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -450,6 +450,11 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= @@ -1034,6 +1039,14 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= +go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= @@ -1590,12 +1603,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/tests/starship/tests/go.mod b/tests/starship/tests/go.mod index 37ceefcdeda3..a8a752252b81 100644 --- a/tests/starship/tests/go.mod +++ b/tests/starship/tests/go.mod @@ -48,7 +48,7 @@ require ( ) require ( - cloud.google.com/go v0.110.10 // indirect + cloud.google.com/go v0.111.0 // indirect cloud.google.com/go/compute v1.23.3 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/iam v1.1.5 // indirect @@ -58,7 +58,7 @@ require ( cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/accounts v0.0.0-20240104091155-b729e981f130 // indirect cosmossdk.io/x/authz v0.0.0-00010101000000-000000000000 // indirect @@ -123,6 +123,8 @@ require ( github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect @@ -215,6 +217,9 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect @@ -227,12 +232,11 @@ require ( golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.16.0 // indirect - golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect google.golang.org/api v0.153.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/tests/starship/tests/go.sum b/tests/starship/tests/go.sum index ab255034075c..862bdd56fa7d 100644 --- a/tests/starship/tests/go.sum +++ b/tests/starship/tests/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= +cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -188,8 +188,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -450,6 +450,11 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= github.com/go-playground/locales v0.14.0 h1:u50s323jtVGugKlcYeyzC0etD1HifMjqmJqb8WugfUU= @@ -1044,6 +1049,14 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= +go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= @@ -1586,12 +1599,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/testutil/mock/logger.go b/testutil/mock/logger.go index b17f076d0255..800210aa241e 100644 --- a/testutil/mock/logger.go +++ b/testutil/mock/logger.go @@ -99,6 +99,23 @@ func (mr *MockLoggerMockRecorder) Info(arg0 interface{}, arg1 ...interface{}) *g return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Info", reflect.TypeOf((*MockLogger)(nil).Info), varargs...) } +// Warn mocks base method. +func (m *MockLogger) Warn(arg0 string, arg1 ...interface{}) { + m.ctrl.T.Helper() + varargs := []interface{}{arg0} + for _, a := range arg1 { + varargs = append(varargs, a) + } + m.ctrl.Call(m, "Warn", varargs...) +} + +// Warn indicates an expected call of Warn. +func (mr *MockLoggerMockRecorder) Warn(arg0 interface{}, arg1 ...interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + varargs := append([]interface{}{arg0}, arg1...) + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Warn", reflect.TypeOf((*MockLogger)(nil).Warn), varargs...) +} + // With mocks base method. func (m *MockLogger) With(arg0 ...interface{}) log.Logger { m.ctrl.T.Helper() diff --git a/tools/confix/go.mod b/tools/confix/go.mod index cbd1311baec0..8bfb591768ad 100644 --- a/tools/confix/go.mod +++ b/tools/confix/go.mod @@ -18,7 +18,7 @@ require ( cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/core v0.11.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/log v1.2.1 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect @@ -144,9 +144,9 @@ require ( golang.org/x/sys v0.16.0 // indirect golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/grpc v1.60.1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect diff --git a/tools/confix/go.sum b/tools/confix/go.sum index 1f1ce37aeae2..dab12ef24632 100644 --- a/tools/confix/go.sum +++ b/tools/confix/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -938,12 +938,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/tools/cosmovisor/go.mod b/tools/cosmovisor/go.mod index a02ab83ab01a..ed2b3137a836 100644 --- a/tools/cosmovisor/go.mod +++ b/tools/cosmovisor/go.mod @@ -11,7 +11,7 @@ require ( ) require ( - cloud.google.com/go v0.110.10 // indirect + cloud.google.com/go v0.111.0 // indirect cloud.google.com/go/compute v1.23.3 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/iam v1.1.5 // indirect @@ -20,7 +20,7 @@ require ( cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/core v0.11.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/tx v0.13.0 // indirect @@ -70,6 +70,8 @@ require ( github.com/go-kit/kit v0.12.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect @@ -151,6 +153,9 @@ require ( github.com/zondax/ledger-go v0.14.3 // indirect go.etcd.io/bbolt v1.3.8 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231214170342-aacd6d4b4611 // indirect @@ -164,9 +169,9 @@ require ( golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect google.golang.org/api v0.153.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/grpc v1.60.1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect diff --git a/tools/cosmovisor/go.sum b/tools/cosmovisor/go.sum index 7dbf07acefce..caa7d7765149 100644 --- a/tools/cosmovisor/go.sum +++ b/tools/cosmovisor/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= +cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -192,8 +192,8 @@ cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -432,6 +432,11 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= github.com/go-playground/locales v0.14.0 h1:u50s323jtVGugKlcYeyzC0etD1HifMjqmJqb8WugfUU= @@ -1005,6 +1010,14 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= +go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= @@ -1536,12 +1549,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/tools/hubl/go.mod b/tools/hubl/go.mod index d161c24b66f4..6c594e6e4afd 100644 --- a/tools/hubl/go.mod +++ b/tools/hubl/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.2 cosmossdk.io/client/v2 v2.0.0-20231020102946-7421783eda5d cosmossdk.io/core v0.12.0 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 github.com/cockroachdb/errors v1.11.1 github.com/cosmos/cosmos-sdk v0.46.0-beta2.0.20231020102946-7421783eda5d github.com/manifoldco/promptui v0.9.0 @@ -144,9 +144,9 @@ require ( golang.org/x/sys v0.16.0 // indirect golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/tools/hubl/go.sum b/tools/hubl/go.sum index 8bfd7863d23d..5d114f1f1d63 100644 --- a/tools/hubl/go.sum +++ b/tools/hubl/go.sum @@ -10,8 +10,8 @@ cosmossdk.io/core v0.12.0 h1:aFuvkG6eDv0IQC+UDjx86wxNWVAxdCFk7OABJ1Vh4RU= cosmossdk.io/core v0.12.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -934,12 +934,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/accounts/go.mod b/x/accounts/go.mod index da29c0247c0f..a26392a95458 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -18,7 +18,7 @@ require ( require ( cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/errors v1.0.0 // indirect + cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/log v1.2.1 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect @@ -145,9 +145,9 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/x/accounts/go.sum b/x/accounts/go.sum index eb2bd1e4cbf3..6c2c5ad16dda 100644 --- a/x/accounts/go.sum +++ b/x/accounts/go.sum @@ -4,8 +4,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -896,12 +896,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/auth/go.mod b/x/auth/go.mod index 64fe7439bf95..bd682e64f86e 100644 --- a/x/auth/go.mod +++ b/x/auth/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -28,7 +28,7 @@ require ( github.com/spf13/viper v1.18.2 github.com/stretchr/testify v1.8.4 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -155,8 +155,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/auth/go.sum b/x/auth/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/auth/go.sum +++ b/x/auth/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/authz/go.mod b/x/authz/go.mod index d8cfca3d490e..662c6d25f7eb 100644 --- a/x/authz/go.mod +++ b/x/authz/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -24,7 +24,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 ) @@ -157,8 +157,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/x/authz/go.sum b/x/authz/go.sum index 4d5002c86be7..b45f33734048 100644 --- a/x/authz/go.sum +++ b/x/authz/go.sum @@ -4,8 +4,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -935,12 +935,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/bank/go.mod b/x/bank/go.mod index ccda0c7807ad..9eb489dba301 100644 --- a/x/bank/go.mod +++ b/x/bank/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -22,7 +22,7 @@ require ( github.com/hashicorp/go-metrics v0.5.3 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 gotest.tools/v3 v3.5.1 ) @@ -151,8 +151,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/bank/go.sum b/x/bank/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/bank/go.sum +++ b/x/bank/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/circuit/go.mod b/x/circuit/go.mod index 284bb521d596..33a337c89780 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 github.com/cockroachdb/errors v1.11.1 @@ -16,7 +16,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 ) @@ -151,8 +151,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/circuit/go.sum b/x/circuit/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/distribution/go.mod b/x/distribution/go.mod index cfdfdbcbd552..f50fc97917e0 100644 --- a/x/distribution/go.mod +++ b/x/distribution/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -27,7 +27,7 @@ require ( github.com/pkg/errors v0.9.1 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 gotest.tools/v3 v3.5.1 ) @@ -154,8 +154,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/distribution/go.sum b/x/distribution/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/distribution/go.sum +++ b/x/distribution/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/evidence/go.mod b/x/evidence/go.mod index 1f9fe02fea15..0593a4ee1929 100644 --- a/x/evidence/go.mod +++ b/x/evidence/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -24,7 +24,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 ) @@ -154,8 +154,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/x/evidence/go.sum b/x/evidence/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/evidence/go.sum +++ b/x/evidence/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/feegrant/go.mod b/x/feegrant/go.mod index 4062ab71cb0b..94c3ea85eac5 100644 --- a/x/feegrant/go.mod +++ b/x/feegrant/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -24,7 +24,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -157,8 +157,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/feegrant/go.sum b/x/feegrant/go.sum index 3cfefc2a7f0f..2eaf457eebdb 100644 --- a/x/feegrant/go.sum +++ b/x/feegrant/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -937,12 +937,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/gov/go.mod b/x/gov/go.mod index 1493b02322f5..e3590ac865bc 100644 --- a/x/gov/go.mod +++ b/x/gov/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -27,7 +27,7 @@ require ( github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -156,8 +156,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/gov/go.sum b/x/gov/go.sum index 4d5002c86be7..b45f33734048 100644 --- a/x/gov/go.sum +++ b/x/gov/go.sum @@ -4,8 +4,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -935,12 +935,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/group/go.mod b/x/group/go.mod index 256129927946..389821c1f6b9 100644 --- a/x/group/go.mod +++ b/x/group/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -29,7 +29,7 @@ require ( github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 pgregory.net/rapid v1.1.0 @@ -159,8 +159,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/x/group/go.sum b/x/group/go.sum index 5f7b1ee5486d..5edcc06241ab 100644 --- a/x/group/go.sum +++ b/x/group/go.sum @@ -4,8 +4,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -936,12 +936,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/mint/go.mod b/x/mint/go.mod index dfbe0cfffc6e..905f30d4b87d 100644 --- a/x/mint/go.mod +++ b/x/mint/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -20,7 +20,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 gotest.tools/v3 v3.5.1 ) @@ -152,8 +152,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/mint/go.sum b/x/mint/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/mint/go.sum +++ b/x/mint/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/nft/go.mod b/x/nft/go.mod index 4077646eacd6..928bac115e3b 100644 --- a/x/nft/go.mod +++ b/x/nft/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -20,7 +20,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 ) @@ -152,8 +152,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/nft/go.sum b/x/nft/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/nft/go.sum +++ b/x/nft/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/params/go.mod b/x/params/go.mod index 5ae0f3f3ad68..414a41b67e76 100644 --- a/x/params/go.mod +++ b/x/params/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -21,7 +21,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 ) @@ -152,8 +152,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/protobuf v1.32.0 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/x/params/go.sum b/x/params/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/params/go.sum +++ b/x/params/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/protocolpool/go.mod b/x/protocolpool/go.mod index 11e333aa7841..de0e2df39e8e 100644 --- a/x/protocolpool/go.mod +++ b/x/protocolpool/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -23,7 +23,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -155,8 +155,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/protocolpool/go.sum b/x/protocolpool/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/protocolpool/go.sum +++ b/x/protocolpool/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/slashing/go.mod b/x/slashing/go.mod index 27acc250661b..c4d92f5aecc3 100644 --- a/x/slashing/go.mod +++ b/x/slashing/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -26,7 +26,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -157,8 +157,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/slashing/go.sum b/x/slashing/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/slashing/go.sum +++ b/x/slashing/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/staking/go.mod b/x/staking/go.mod index f6e8fecc8545..6b339e6d4506 100644 --- a/x/staking/go.mod +++ b/x/staking/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 @@ -28,7 +28,7 @@ require ( github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 golang.org/x/exp v0.0.0-20231226003508-02704c960a9b - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 @@ -157,8 +157,8 @@ require ( golang.org/x/term v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.16.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/x/staking/go.sum b/x/staking/go.sum index 5701bb7ea52e..ed288ef725e1 100644 --- a/x/staking/go.sum +++ b/x/staking/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -928,12 +928,12 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/x/tx/go.mod b/x/tx/go.mod index 7bcb92d103dc..72950b345fd4 100644 --- a/x/tx/go.mod +++ b/x/tx/go.mod @@ -5,7 +5,7 @@ go 1.21 require ( cosmossdk.io/api v0.7.2 cosmossdk.io/core v0.11.0 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/math v1.2.0 github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/cosmos/gogoproto v1.4.11 @@ -26,11 +26,11 @@ require ( github.com/pmezard/go-difflib v1.0.0 // indirect golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect golang.org/x/net v0.19.0 // indirect - golang.org/x/sys v0.15.0 // indirect + golang.org/x/sys v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect google.golang.org/grpc v1.60.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/x/tx/go.sum b/x/tx/go.sum index 4d558c971de7..89b3d43596b7 100644 --- a/x/tx/go.sum +++ b/x/tx/go.sum @@ -2,8 +2,8 @@ cosmossdk.io/api v0.7.2 h1:BO3i5fvKMKvfaUiMkCznxViuBEfyWA/k6w2eAF6q1C4= cosmossdk.io/api v0.7.2/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= github.com/cosmos/cosmos-proto v1.0.0-beta.3 h1:VitvZ1lPORTVxkmF2fAp3IiA61xVwArQYKXTdEcpW6o= @@ -48,18 +48,18 @@ golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.60.1 h1:26+wFr+cNqSGFcOXcabYC0lUVJVRa2Sb2ortSK7VrEU= google.golang.org/grpc v1.60.1/go.mod h1:OlCHIeLYqSSsLi6i49B5QGdzaMZK9+M7LXN2FKz4eGM= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= diff --git a/x/upgrade/go.mod b/x/upgrade/go.mod index e953879c6efb..05eae4bebd07 100644 --- a/x/upgrade/go.mod +++ b/x/upgrade/go.mod @@ -6,7 +6,7 @@ require ( cosmossdk.io/api v0.7.3-0.20231113122742-912390d5fc4a cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/errors v1.0.0 + cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.2.1 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 @@ -25,13 +25,13 @@ require ( github.com/spf13/cobra v1.8.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f + google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 google.golang.org/grpc v1.60.1 google.golang.org/protobuf v1.32.0 ) require ( - cloud.google.com/go v0.110.10 // indirect + cloud.google.com/go v0.111.0 // indirect cloud.google.com/go/compute v1.23.3 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/iam v1.1.5 // indirect @@ -84,6 +84,8 @@ require ( github.com/go-kit/kit v0.12.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect @@ -165,6 +167,9 @@ require ( gitlab.com/yawning/tuplehash v0.0.0-20230713102510-df83abbf9a02 // indirect go.etcd.io/bbolt v1.3.7 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.18.0 // indirect golang.org/x/exp v0.0.0-20231226003508-02704c960a9b // indirect @@ -180,8 +185,8 @@ require ( golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect google.golang.org/api v0.153.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect + google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect gotest.tools/v3 v3.5.1 // indirect diff --git a/x/upgrade/go.sum b/x/upgrade/go.sum index ed4034e9e006..d0c73c953f71 100644 --- a/x/upgrade/go.sum +++ b/x/upgrade/go.sum @@ -30,8 +30,8 @@ cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w9 cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= -cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go v0.111.0 h1:YHLKNupSD1KqjDbQ3+LVdQ81h/UJbJyZG203cEfnQgM= +cloud.google.com/go v0.111.0/go.mod h1:0mibmpKP1TyOOFYQY5izo0LnT+ecvOQ0Sg3OdmMiNRU= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= @@ -190,8 +190,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m4QA4+Uq+PkFRjY/yalZ0B8= cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= -cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= -cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= +cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= @@ -450,6 +450,11 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= @@ -1034,6 +1039,14 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= +go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= @@ -1591,12 +1604,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= -google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917 h1:nz5NESFLZbJGPFxDT/HCn+V1mZ8JGNoY4nUpmW/Y2eg= +google.golang.org/genproto v0.0.0-20240102182953-50ed04b92917/go.mod h1:pZqR+glSb11aJ+JQcczCvgf47+duRuzNSKqE8YAQnV0= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0 h1:s1w3X6gQxwrLEpxnLd/qXTVLgQE2yXwaOaoa6IlY/+o= +google.golang.org/genproto/googleapis/api v0.0.0-20231212172506-995d672761c0/go.mod h1:CAny0tYF+0/9rmDB9fahA9YLzX3+AEVl1qXbv5hhj6c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1 h1:gphdwh0npgs8elJ4T6J+DQJHPVF7RsuJHCfwztUb4J4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240108191215-35c7eff3a6b1/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= From 7fdb1344ffdabc0efbe4aa8844ac4e6562d78c3d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Jan 2024 10:17:27 +0100 Subject: [PATCH 26/28] build(deps): Bump cosmossdk.io/log from 1.2.1 to 1.3.0 (#19035) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> --- client/v2/go.mod | 2 +- client/v2/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- simapp/go.mod | 2 +- simapp/go.sum | 4 ++-- simapp/gomod2nix.toml | 4 ++-- store/go.mod | 2 +- store/go.sum | 8 ++++---- tests/go.mod | 2 +- tests/go.sum | 4 ++-- tests/starship/tests/go.mod | 2 +- tests/starship/tests/go.sum | 4 ++-- tools/confix/go.mod | 2 +- tools/confix/go.sum | 4 ++-- tools/cosmovisor/go.mod | 2 +- tools/cosmovisor/go.sum | 4 ++-- tools/hubl/go.mod | 2 +- tools/hubl/go.sum | 4 ++-- x/accounts/go.mod | 2 +- x/accounts/go.sum | 4 ++-- x/auth/go.mod | 2 +- x/auth/go.sum | 4 ++-- x/authz/go.mod | 2 +- x/authz/go.sum | 4 ++-- x/bank/go.mod | 2 +- x/bank/go.sum | 4 ++-- x/circuit/go.mod | 2 +- x/circuit/go.sum | 4 ++-- x/distribution/go.mod | 2 +- x/distribution/go.sum | 4 ++-- x/evidence/go.mod | 2 +- x/evidence/go.sum | 4 ++-- x/feegrant/go.mod | 2 +- x/feegrant/go.sum | 4 ++-- x/gov/go.mod | 2 +- x/gov/go.sum | 4 ++-- x/group/go.mod | 2 +- x/group/go.sum | 4 ++-- x/mint/go.mod | 2 +- x/mint/go.sum | 4 ++-- x/nft/go.mod | 2 +- x/nft/go.sum | 4 ++-- x/params/go.mod | 2 +- x/params/go.sum | 4 ++-- x/protocolpool/go.mod | 2 +- x/protocolpool/go.sum | 4 ++-- x/slashing/go.mod | 2 +- x/slashing/go.sum | 4 ++-- x/staking/go.mod | 2 +- x/staking/go.sum | 4 ++-- x/upgrade/go.mod | 2 +- x/upgrade/go.sum | 4 ++-- 53 files changed, 82 insertions(+), 82 deletions(-) diff --git a/client/v2/go.mod b/client/v2/go.mod index 61cd1e07ea73..a5775e3ec6f8 100644 --- a/client/v2/go.mod +++ b/client/v2/go.mod @@ -25,7 +25,7 @@ require ( require ( cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/errors v1.0.1 // indirect - cosmossdk.io/log v1.2.1 // indirect + cosmossdk.io/log v1.3.0 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/client/v2/go.sum b/client/v2/go.sum index 2eaf457eebdb..dd0728774218 100644 --- a/client/v2/go.sum +++ b/client/v2/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/go.mod b/go.mod index bd079a7f73c8..76010ef9a948 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/go.sum b/go.sum index a7db906df47a..1d78a39ebbd9 100644 --- a/go.sum +++ b/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/simapp/go.mod b/simapp/go.mod index e2bbb8d8107c..277bad2c1131 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/tools/confix v0.0.0-20230613133644-0a778132a60f diff --git a/simapp/go.sum b/simapp/go.sum index b363b7319ae4..afb69a7230b4 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -190,8 +190,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/simapp/gomod2nix.toml b/simapp/gomod2nix.toml index ff57326c2957..3c07d2298fac 100644 --- a/simapp/gomod2nix.toml +++ b/simapp/gomod2nix.toml @@ -26,8 +26,8 @@ schema = 3 version = "v1.0.1" hash = "sha256-MgTocXkBzri9FKkNtkARJXPmxRrRO/diQJS5ZzvYrJY=" [mod."cosmossdk.io/log"] - version = "v1.2.1" - hash = "sha256-2Mb0jQ5Yvi+2fvhCVEiiacwODXM8+6vhsKOnHz+wsiY=" + version = "v1.3.0" + hash = "sha256-ti835PlPIWxP8c2Drfo5asi2Kd6kBkmXaadQZ/BiMqw=" [mod."cosmossdk.io/math"] version = "v1.2.0" hash = "sha256-yLPUAsJPQxuI0C22cPbP/BzclWb9eBzGFntGDQmdVUc=" diff --git a/store/go.mod b/store/go.mod index 7a83d636c967..648f1f32b628 100644 --- a/store/go.mod +++ b/store/go.mod @@ -5,7 +5,7 @@ go 1.21 require ( cosmossdk.io/core v0.12.0 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 github.com/cockroachdb/errors v1.11.1 github.com/cockroachdb/pebble v1.0.0 github.com/cometbft/cometbft v0.38.2 diff --git a/store/go.sum b/store/go.sum index bbd8476cd1b4..4307ae525dec 100644 --- a/store/go.sum +++ b/store/go.sum @@ -1,7 +1,7 @@ cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= @@ -334,5 +334,5 @@ gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= -gotest.tools/v3 v3.5.0/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= +gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= +gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= diff --git a/tests/go.mod b/tests/go.mod index 839c8e79dccf..60791875747c 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/simapp v0.0.0-20230309163709-87da587416ba cosmossdk.io/store v1.0.1 diff --git a/tests/go.sum b/tests/go.sum index fecf5c588006..c18f042f4af0 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -190,8 +190,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/tests/starship/tests/go.mod b/tests/starship/tests/go.mod index a8a752252b81..aaccfe1fdafc 100644 --- a/tests/starship/tests/go.mod +++ b/tests/starship/tests/go.mod @@ -35,7 +35,7 @@ replace ( ) require ( - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/simapp v0.0.0-00010101000000-000000000000 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/tests/starship/tests/go.sum b/tests/starship/tests/go.sum index 862bdd56fa7d..c85469a9e2c7 100644 --- a/tests/starship/tests/go.sum +++ b/tests/starship/tests/go.sum @@ -190,8 +190,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/tools/confix/go.mod b/tools/confix/go.mod index 8bfb591768ad..679b1da4dc55 100644 --- a/tools/confix/go.mod +++ b/tools/confix/go.mod @@ -19,7 +19,7 @@ require ( cosmossdk.io/core v0.11.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect cosmossdk.io/errors v1.0.1 // indirect - cosmossdk.io/log v1.2.1 // indirect + cosmossdk.io/log v1.3.0 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/tx v0.13.0 // indirect diff --git a/tools/confix/go.sum b/tools/confix/go.sum index dab12ef24632..743f94ba3060 100644 --- a/tools/confix/go.sum +++ b/tools/confix/go.sum @@ -10,8 +10,8 @@ cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98ok cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/tools/cosmovisor/go.mod b/tools/cosmovisor/go.mod index ed2b3137a836..dc2f6b2a39bf 100644 --- a/tools/cosmovisor/go.mod +++ b/tools/cosmovisor/go.mod @@ -3,7 +3,7 @@ module cosmossdk.io/tools/cosmovisor go 1.21 require ( - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/x/upgrade v0.1.1 github.com/otiai10/copy v1.14.0 github.com/spf13/cobra v1.8.0 diff --git a/tools/cosmovisor/go.sum b/tools/cosmovisor/go.sum index caa7d7765149..861cd71cac65 100644 --- a/tools/cosmovisor/go.sum +++ b/tools/cosmovisor/go.sum @@ -194,8 +194,8 @@ cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98ok cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/tools/hubl/go.mod b/tools/hubl/go.mod index 6c594e6e4afd..221dda327bd0 100644 --- a/tools/hubl/go.mod +++ b/tools/hubl/go.mod @@ -19,7 +19,7 @@ require ( require ( cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/log v1.2.1 // indirect + cosmossdk.io/log v1.3.0 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/tx v0.13.0 // indirect diff --git a/tools/hubl/go.sum b/tools/hubl/go.sum index 5d114f1f1d63..f94ddbdeabfb 100644 --- a/tools/hubl/go.sum +++ b/tools/hubl/go.sum @@ -12,8 +12,8 @@ cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98ok cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/accounts/go.mod b/x/accounts/go.mod index a26392a95458..44bd0f975256 100644 --- a/x/accounts/go.mod +++ b/x/accounts/go.mod @@ -19,7 +19,7 @@ require ( require ( cosmossdk.io/depinject v1.0.0-alpha.4 // indirect cosmossdk.io/errors v1.0.1 // indirect - cosmossdk.io/log v1.2.1 // indirect + cosmossdk.io/log v1.3.0 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/store v1.0.1 // indirect cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 // indirect diff --git a/x/accounts/go.sum b/x/accounts/go.sum index 6c2c5ad16dda..038cdf61ad4d 100644 --- a/x/accounts/go.sum +++ b/x/accounts/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/auth/go.mod b/x/auth/go.mod index bd682e64f86e..2e53ff357d2a 100644 --- a/x/auth/go.mod +++ b/x/auth/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/auth/go.sum b/x/auth/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/auth/go.sum +++ b/x/auth/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/authz/go.mod b/x/authz/go.mod index 662c6d25f7eb..1bac2db0c87f 100644 --- a/x/authz/go.mod +++ b/x/authz/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/authz/go.sum b/x/authz/go.sum index b45f33734048..16e66195c8bc 100644 --- a/x/authz/go.sum +++ b/x/authz/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/bank/go.mod b/x/bank/go.mod index 9eb489dba301..9147ba6160bd 100644 --- a/x/bank/go.mod +++ b/x/bank/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/staking v0.0.0-00010101000000-000000000000 diff --git a/x/bank/go.sum b/x/bank/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/bank/go.sum +++ b/x/bank/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/circuit/go.mod b/x/circuit/go.mod index 33a337c89780..0848563c4bba 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -21,7 +21,7 @@ require ( ) require ( - cosmossdk.io/log v1.2.1 // indirect + cosmossdk.io/log v1.3.0 // indirect cosmossdk.io/math v1.2.0 // indirect cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 // indirect cosmossdk.io/x/staking v0.0.0-00010101000000-000000000000 // indirect diff --git a/x/circuit/go.sum b/x/circuit/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/distribution/go.mod b/x/distribution/go.mod index f50fc97917e0..da18440ed98d 100644 --- a/x/distribution/go.mod +++ b/x/distribution/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/distribution/go.sum b/x/distribution/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/distribution/go.sum +++ b/x/distribution/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/evidence/go.mod b/x/evidence/go.mod index 0593a4ee1929..5b2b42baa4db 100644 --- a/x/evidence/go.mod +++ b/x/evidence/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/x/evidence/go.sum b/x/evidence/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/evidence/go.sum +++ b/x/evidence/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/feegrant/go.mod b/x/feegrant/go.mod index 94c3ea85eac5..05c2b0008242 100644 --- a/x/feegrant/go.mod +++ b/x/feegrant/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/feegrant/go.sum b/x/feegrant/go.sum index 2eaf457eebdb..dd0728774218 100644 --- a/x/feegrant/go.sum +++ b/x/feegrant/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/gov/go.mod b/x/gov/go.mod index e3590ac865bc..ebae0e4a5728 100644 --- a/x/gov/go.mod +++ b/x/gov/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/gov/go.sum b/x/gov/go.sum index b45f33734048..16e66195c8bc 100644 --- a/x/gov/go.sum +++ b/x/gov/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/group/go.mod b/x/group/go.mod index 389821c1f6b9..0e2267fa197b 100644 --- a/x/group/go.mod +++ b/x/group/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/x/group/go.sum b/x/group/go.sum index 5edcc06241ab..b8f2a838153e 100644 --- a/x/group/go.sum +++ b/x/group/go.sum @@ -6,8 +6,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/mint/go.mod b/x/mint/go.mod index 905f30d4b87d..d6bc311aed46 100644 --- a/x/mint/go.mod +++ b/x/mint/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/mint/go.sum b/x/mint/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/mint/go.sum +++ b/x/mint/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/nft/go.mod b/x/nft/go.mod index 928bac115e3b..5df0594e7ac6 100644 --- a/x/nft/go.mod +++ b/x/nft/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/nft/go.sum b/x/nft/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/nft/go.sum +++ b/x/nft/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/params/go.mod b/x/params/go.mod index 414a41b67e76..774d717bf463 100644 --- a/x/params/go.mod +++ b/x/params/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/gov v0.0.0-20230925135524-a1bc045b3190 diff --git a/x/params/go.sum b/x/params/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/params/go.sum +++ b/x/params/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/protocolpool/go.mod b/x/protocolpool/go.mod index de0e2df39e8e..fa8870118070 100644 --- a/x/protocolpool/go.mod +++ b/x/protocolpool/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 diff --git a/x/protocolpool/go.sum b/x/protocolpool/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/protocolpool/go.sum +++ b/x/protocolpool/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/slashing/go.mod b/x/slashing/go.mod index c4d92f5aecc3..2ebd6c3f3f7f 100644 --- a/x/slashing/go.mod +++ b/x/slashing/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/slashing/go.sum b/x/slashing/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/slashing/go.sum +++ b/x/slashing/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/staking/go.mod b/x/staking/go.mod index 6b339e6d4506..824e7ce10520 100644 --- a/x/staking/go.mod +++ b/x/staking/go.mod @@ -8,7 +8,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/math v1.2.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/bank v0.0.0-00010101000000-000000000000 diff --git a/x/staking/go.sum b/x/staking/go.sum index ed288ef725e1..3e1c10e7bd57 100644 --- a/x/staking/go.sum +++ b/x/staking/go.sum @@ -8,8 +8,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= diff --git a/x/upgrade/go.mod b/x/upgrade/go.mod index 05eae4bebd07..ab53510f3bbe 100644 --- a/x/upgrade/go.mod +++ b/x/upgrade/go.mod @@ -7,7 +7,7 @@ require ( cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 cosmossdk.io/depinject v1.0.0-alpha.4 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.2.1 + cosmossdk.io/log v1.3.0 cosmossdk.io/store v1.0.1 cosmossdk.io/x/auth v0.0.0-00010101000000-000000000000 cosmossdk.io/x/gov v0.0.0-20230925135524-a1bc045b3190 diff --git a/x/upgrade/go.sum b/x/upgrade/go.sum index d0c73c953f71..6936200541e9 100644 --- a/x/upgrade/go.sum +++ b/x/upgrade/go.sum @@ -192,8 +192,8 @@ cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7 h1:hOzi4yo2Fc7h3mod+xX4m cosmossdk.io/core v0.12.1-0.20231114100755-569e3ff6a0d7/go.mod h1:3v0JJNNd8ye0cOvJ+wUUvE7Ke0d2qxnNIDcXd5mziHk= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= -cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/log v1.3.0 h1:L0Z0XstClo2kOU4h3V1iDoE5Ji64sg5HLOogzGg67Oo= +cosmossdk.io/log v1.3.0/go.mod h1:HIDyvWLqZe2ovlWabsDN4aPMpY/nUEquAhgfTf2ZzB8= cosmossdk.io/math v1.2.0 h1:8gudhTkkD3NxOP2YyyJIYYmt6dQ55ZfJkDOaxXpy7Ig= cosmossdk.io/math v1.2.0/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= cosmossdk.io/store v1.0.1 h1:XBDhCqlL+2MUgE8CHWwndKVJ4beX+TyaPIjB5SV62dM= From 40c5e452e31c9ed0a77e64e237543c6160ff15f5 Mon Sep 17 00:00:00 2001 From: Cosmos SDK <113218068+github-prbot@users.noreply.github.com> Date: Fri, 12 Jan 2024 10:19:39 +0100 Subject: [PATCH 27/28] chore: fix spelling errors (#19030) Co-authored-by: github-merge-queue Co-authored-by: marbar3778 --- docs/architecture/PROCESS.md | 2 +- docs/architecture/adr-069-gov-improvements.md | 2 +- docs/rfc/PROCESS.md | 6 +++--- docs/rfc/rfc-001-tx-validation.md | 2 +- store/proof.go | 4 ++-- x/staking/README.md | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/architecture/PROCESS.md b/docs/architecture/PROCESS.md index 5129c88dbe6e..ff6ba408b3e6 100644 --- a/docs/architecture/PROCESS.md +++ b/docs/architecture/PROCESS.md @@ -8,7 +8,7 @@ ## What is an ADR? -An ADR is a document to document an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchoronus communication in a distributed environment, an ADR is meant to document an already made decision. An ADR won't come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchoronus discussion then a short excerpt should be added to the ADR to explain the goals. +An ADR is a document to document an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchronous communication in a distributed environment, an ADR is meant to document an already made decision. An ADR won't come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchoronus discussion then a short excerpt should be added to the ADR to explain the goals. ## ADR life cycle diff --git a/docs/architecture/adr-069-gov-improvements.md b/docs/architecture/adr-069-gov-improvements.md index 6e6560df7176..6d5c80fad288 100644 --- a/docs/architecture/adr-069-gov-improvements.md +++ b/docs/architecture/adr-069-gov-improvements.md @@ -82,7 +82,7 @@ A new vote option `SPAM` will be added and distinguished from those voting optio Multiple choice proposals, contrary to any other proposal type, cannot have messages to execute. They are only text proposals. -Submitting a new multiple choice proposal will use a different message than the [`v1.MsgSubmitProposal`][5]. This is done in order to simplify the proposal submittion and allow defining the voting options directly. +Submitting a new multiple choice proposal will use a different message than the [`v1.MsgSubmitProposal`][5]. This is done in order to simplify the proposal submission and allow defining the voting options directly. ```protobuf diff --git a/docs/rfc/PROCESS.md b/docs/rfc/PROCESS.md index a34af22694d4..f6e96f16787b 100644 --- a/docs/rfc/PROCESS.md +++ b/docs/rfc/PROCESS.md @@ -14,7 +14,7 @@ The main difference the Cosmos SDK is defining as a differentiation between RFC ## RFC life cycle -RFC creation is an **iterative** process. An RFC is meant as a distributed colloboration session, it may have many comments and is usually the bi-product of no working group or synchornous communication +RFC creation is an **iterative** process. An RFC is meant as a distributed colloboration session, it may have many comments and is usually the bi-product of no working group or synchronous communication 1. Proposals could start with a new GitHub Issue, be a result of existing Issues or a discussion. @@ -28,7 +28,7 @@ RFC creation is an **iterative** process. An RFC is meant as a distributed collo 6. If there is consensus and enough feedback then the RFC can be accepted. -> Note: An RFC is written when there is no working group or team session on the problem. RFC's are meant as a distributed white boarding session. If there is a working group on the proposal there is no need to have an RFC as there is synchornous whiteboarding going on. +> Note: An RFC is written when there is no working group or team session on the problem. RFC's are meant as a distributed white boarding session. If there is a working group on the proposal there is no need to have an RFC as there is synchronous whiteboarding going on. ### RFC status @@ -53,7 +53,7 @@ DRAFT -> PROPOSED -> LAST CALL yyyy-mm-dd -> ACCEPTED | REJECTED -> SUPERSEDED b * `LAST CALL `: [optional] clear notify that we are close to accept updates. Changing a status to `LAST CALL` means that social consensus (of Cosmos SDK maintainers) has been reached and we still want to give it a time to let the community react or analyze. * `ACCEPTED`: ADR which will represent a currently implemented or to be implemented architecture design. * `REJECTED`: ADR can go from PROPOSED or ACCEPTED to rejected if the consensus among project stakeholders will decide so. -* `SUPERSEEDED by ADR-xxx`: ADR which has been superseded by a new ADR. +* `SUPERSEDED by ADR-xxx`: ADR which has been superseded by a new ADR. * `ABANDONED`: the ADR is no longer pursued by the original authors. ## Language used in RFC diff --git a/docs/rfc/rfc-001-tx-validation.md b/docs/rfc/rfc-001-tx-validation.md index e616c6feabe7..c8abb8cb61a6 100644 --- a/docs/rfc/rfc-001-tx-validation.md +++ b/docs/rfc/rfc-001-tx-validation.md @@ -6,7 +6,7 @@ ## Background -Transation Validation is crucial to a functioning state machine. Within the Cosmos SDK there are two validation flows, one is outside the message server and the other within. The flow outside of the message server is the `ValidateBasic` function. It is called in the antehandler on both `CheckTx` and `DeliverTx`. There is an overhead and sometimes duplication of validation within these two flows. This extra validation provides an additional check before entering the mempool. +Transaction Validation is crucial to a functioning state machine. Within the Cosmos SDK there are two validation flows, one is outside the message server and the other within. The flow outside of the message server is the `ValidateBasic` function. It is called in the antehandler on both `CheckTx` and `DeliverTx`. There is an overhead and sometimes duplication of validation within these two flows. This extra validation provides an additional check before entering the mempool. With the deprecation of [`GetSigners`](https://github.com/cosmos/cosmos-sdk/issues/11275) we have the optionality to remove [sdk.Msg](https://github.com/cosmos/cosmos-sdk/blob/16a5404f8e00ddcf8857c8a55dca2f7c109c29bc/types/tx_msg.go#L16) and the `ValidateBasic` function. diff --git a/store/proof.go b/store/proof.go index 71b32d9729b7..cabeb5c680ac 100644 --- a/store/proof.go +++ b/store/proof.go @@ -123,7 +123,7 @@ func (op CommitmentOp) Run(args [][]byte) ([][]byte, error) { } // ProofFromByteSlices computes the proof from the given leaves. An iteration will be -// perfomed for each level of the tree, where each iteration hashes together the bottom most +// performed for each level of the tree, where each iteration hashes together the bottom most // nodes. If the length of the bottom most nodes is odd, then the last node will be saved // for the next iteration. // @@ -163,7 +163,7 @@ func ProofFromByteSlices(leaves [][]byte, index int) (rootHash []byte, inners [] // saved until the next iteration). if index < n-1 || index&1 == 1 { inner := &ics23.InnerOp{Hash: ics23.HashOp_SHA256} - //Iif proof index is even then child is from left, suffix is populated + //If proof index is even then child is from left, suffix is populated // otherwise, child is from right and the prefix is populated. if index&1 == 0 { // inner op(prefix=0x01 | child | suffix=leaves[index+1]) diff --git a/x/staking/README.md b/x/staking/README.md index dd3c6d56b75e..5da8e117e8cc 100644 --- a/x/staking/README.md +++ b/x/staking/README.md @@ -1631,7 +1631,7 @@ simd tx staking edit-validator [flags] Example: ```bash -simd tx staking edit-validator --moniker "new_moniker_name" --website "new_webiste_url" --from mykey +simd tx staking edit-validator --moniker "new_moniker_name" --website "new_website_url" --from mykey ``` ##### redelegate From b98b6eb076b52e30785bcc23209f2692a0325955 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Jan 2024 10:21:28 +0100 Subject: [PATCH 28/28] build(deps): Bump google.golang.org/protobuf from 1.31.0 to 1.32.0 in /depinject (#19033) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- depinject/go.mod | 2 +- depinject/go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/depinject/go.mod b/depinject/go.mod index be6de69b96a5..d48b36e2fcae 100644 --- a/depinject/go.mod +++ b/depinject/go.mod @@ -8,7 +8,7 @@ require ( github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/stretchr/testify v1.8.4 golang.org/x/exp v0.0.0-20230811145659-89c5cff77bcb - google.golang.org/protobuf v1.31.0 + google.golang.org/protobuf v1.32.0 gotest.tools/v3 v3.5.1 sigs.k8s.io/yaml v1.4.0 ) diff --git a/depinject/go.sum b/depinject/go.sum index 7f566f79f2a2..04a0336758d7 100644 --- a/depinject/go.sum +++ b/depinject/go.sum @@ -81,8 +81,8 @@ google.golang.org/grpc v1.58.3 h1:BjnpXut1btbtgN/6sp+brB2Kbm2LjNXnidYujAVbSoQ= google.golang.org/grpc v1.58.3/go.mod h1:tgX3ZQDlNJGU96V6yHh1T/JeoBQ2TXdr43YbYSsCJk0= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= -google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.32.0 h1:pPC6BG5ex8PDFnkbrGU3EixyhKcQ2aDuBS36lqK/C7I= +google.golang.org/protobuf v1.32.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=