forked from hyperweb-io/telescope
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3,572 changed files
with
309,764 additions
and
269,929 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
syntax = "proto3"; | ||
|
||
package amino; | ||
|
||
import "google/protobuf/descriptor.proto"; | ||
|
||
// TODO(fdymylja): once we fully migrate to protov2 the go_package needs to be updated. | ||
// We need this right now because gogoproto codegen needs to import the extension. | ||
option go_package = "github.com/cosmos/cosmos-sdk/types/tx/amino"; | ||
|
||
extend google.protobuf.MessageOptions { | ||
// name is the string used when registering a concrete | ||
// type into the Amino type registry, via the Amino codec's | ||
// `RegisterConcrete()` method. This string MUST be at most 39 | ||
// characters long, or else the message will be rejected by the | ||
// Ledger hardware device. | ||
string name = 11110001; | ||
|
||
// encoding describes the encoding format used by Amino for the given | ||
// message. The field type is chosen to be a string for | ||
// flexibility, but it should ideally be short and expected to be | ||
// machine-readable, for example "base64" or "utf8_json". We | ||
// highly recommend to use underscores for word separation instead of spaces. | ||
// | ||
// If left empty, then the Amino encoding is expected to be the same as the | ||
// Protobuf one. | ||
// | ||
// This annotation should not be confused with the `encoding` | ||
// one which operates on the field level. | ||
string message_encoding = 11110002; | ||
} | ||
|
||
extend google.protobuf.FieldOptions { | ||
// encoding describes the encoding format used by Amino for | ||
// the given field. The field type is chosen to be a string for | ||
// flexibility, but it should ideally be short and expected to be | ||
// machine-readable, for example "base64" or "utf8_json". We | ||
// highly recommend to use underscores for word separation instead of spaces. | ||
// | ||
// If left empty, then the Amino encoding is expected to be the same as the | ||
// Protobuf one. | ||
// | ||
// This annotation should not be confused with the | ||
// `message_encoding` one which operates on the message level. | ||
string encoding = 11110003; | ||
|
||
// field_name sets a different field name (i.e. key name) in | ||
// the amino JSON object for the given field. | ||
// | ||
// Example: | ||
// | ||
// message Foo { | ||
// string bar = 1 [(amino.field_name) = "baz"]; | ||
// } | ||
// | ||
// Then the Amino encoding of Foo will be: | ||
// `{"baz":"some value"}` | ||
string field_name = 11110004; | ||
|
||
// dont_omitempty sets the field in the JSON object even if | ||
// its value is empty, i.e. equal to the Golang zero value. To learn what | ||
// the zero values are, see https://go.dev/ref/spec#The_zero_value. | ||
// | ||
// Fields default to `omitempty`, which is the default behavior when this | ||
// annotation is unset. When set to true, then the field value in the | ||
// JSON object will be set, i.e. not `undefined`. | ||
// | ||
// Example: | ||
// | ||
// message Foo { | ||
// string bar = 1; | ||
// string baz = 2 [(amino.dont_omitempty) = true]; | ||
// } | ||
// | ||
// f := Foo{}; | ||
// out := AminoJSONEncoder(&f); | ||
// out == {"baz":""} | ||
bool dont_omitempty = 11110005; | ||
} |
57 changes: 57 additions & 0 deletions
57
__fixtures__/osmojs/cosmos-sdk/proto/cosmos/auth/v1beta1/auth.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
syntax = "proto3"; | ||
package cosmos.auth.v1beta1; | ||
|
||
import "amino/amino.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
import "gogoproto/gogo.proto"; | ||
import "google/protobuf/any.proto"; | ||
|
||
option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; | ||
|
||
// BaseAccount defines a base account type. It contains all the necessary fields | ||
// for basic account functionality. Any custom account type should extend this | ||
// type for additional functionality (e.g. vesting). | ||
message BaseAccount { | ||
option (amino.name) = "cosmos-sdk/BaseAccount"; | ||
option (gogoproto.goproto_getters) = false; | ||
option (gogoproto.goproto_stringer) = false; | ||
option (gogoproto.equal) = false; | ||
|
||
option (cosmos_proto.implements_interface) = "AccountI"; | ||
|
||
string address = 1; | ||
google.protobuf.Any pub_key = 2 [ | ||
(gogoproto.jsontag) = "public_key,omitempty", | ||
(gogoproto.moretags) = "yaml:\"public_key\"", | ||
(amino.field_name) = "public_key" | ||
]; | ||
uint64 account_number = 3 [(gogoproto.moretags) = "yaml:\"account_number\""]; | ||
uint64 sequence = 4; | ||
} | ||
|
||
// ModuleAccount defines an account for modules that holds coins on a pool. | ||
message ModuleAccount { | ||
option (amino.name) = "cosmos-sdk/ModuleAccount"; | ||
option (gogoproto.goproto_getters) = false; | ||
option (gogoproto.goproto_stringer) = false; | ||
option (cosmos_proto.implements_interface) = "ModuleAccountI"; | ||
|
||
BaseAccount base_account = 1 [(gogoproto.embed) = true, (gogoproto.moretags) = "yaml:\"base_account\""]; | ||
string name = 2; | ||
repeated string permissions = 3; | ||
} | ||
|
||
// Params defines the parameters for the auth module. | ||
message Params { | ||
option (amino.name) = "cosmos-sdk/x/auth/Params"; | ||
option (gogoproto.equal) = true; | ||
option (gogoproto.goproto_stringer) = false; | ||
|
||
uint64 max_memo_characters = 1 [(gogoproto.moretags) = "yaml:\"max_memo_characters\""]; | ||
uint64 tx_sig_limit = 2 [(gogoproto.moretags) = "yaml:\"tx_sig_limit\""]; | ||
uint64 tx_size_cost_per_byte = 3 [(gogoproto.moretags) = "yaml:\"tx_size_cost_per_byte\""]; | ||
uint64 sig_verify_cost_ed25519 = 4 | ||
[(gogoproto.customname) = "SigVerifyCostED25519", (gogoproto.moretags) = "yaml:\"sig_verify_cost_ed25519\""]; | ||
uint64 sig_verify_cost_secp256k1 = 5 | ||
[(gogoproto.customname) = "SigVerifyCostSecp256k1", (gogoproto.moretags) = "yaml:\"sig_verify_cost_secp256k1\""]; | ||
} |
18 changes: 18 additions & 0 deletions
18
__fixtures__/osmojs/cosmos-sdk/proto/cosmos/auth/v1beta1/genesis.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
syntax = "proto3"; | ||
package cosmos.auth.v1beta1; | ||
|
||
import "google/protobuf/any.proto"; | ||
import "gogoproto/gogo.proto"; | ||
import "cosmos/auth/v1beta1/auth.proto"; | ||
import "amino/amino.proto"; | ||
|
||
option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; | ||
|
||
// GenesisState defines the auth module's genesis state. | ||
message GenesisState { | ||
// params defines all the paramaters of the module. | ||
Params params = 1 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; | ||
|
||
// accounts are the accounts present at genesis. | ||
repeated google.protobuf.Any accounts = 2; | ||
} |
87 changes: 87 additions & 0 deletions
87
__fixtures__/osmojs/cosmos-sdk/proto/cosmos/auth/v1beta1/query.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
syntax = "proto3"; | ||
package cosmos.auth.v1beta1; | ||
|
||
import "cosmos/base/query/v1beta1/pagination.proto"; | ||
import "gogoproto/gogo.proto"; | ||
import "google/protobuf/any.proto"; | ||
import "google/api/annotations.proto"; | ||
import "cosmos/auth/v1beta1/auth.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
|
||
option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; | ||
|
||
// Query defines the gRPC querier service. | ||
service Query { | ||
// Accounts returns all the existing accounts | ||
// | ||
// Since: cosmos-sdk 0.43 | ||
rpc Accounts(QueryAccountsRequest) returns (QueryAccountsResponse) { | ||
option (google.api.http).get = "/cosmos/auth/v1beta1/accounts"; | ||
} | ||
|
||
// Account returns account details based on address. | ||
rpc Account(QueryAccountRequest) returns (QueryAccountResponse) { | ||
option (google.api.http).get = "/cosmos/auth/v1beta1/accounts/{address}"; | ||
} | ||
|
||
// Params queries all parameters. | ||
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { | ||
option (google.api.http).get = "/cosmos/auth/v1beta1/params"; | ||
} | ||
|
||
// ModuleAccounts returns all the existing module accounts. | ||
rpc ModuleAccounts(QueryModuleAccountsRequest) returns (QueryModuleAccountsResponse) { | ||
option (google.api.http).get = "/cosmos/auth/v1beta1/module_accounts"; | ||
} | ||
} | ||
|
||
// QueryAccountsRequest is the request type for the Query/Accounts RPC method. | ||
// | ||
// Since: cosmos-sdk 0.43 | ||
message QueryAccountsRequest { | ||
// pagination defines an optional pagination for the request. | ||
cosmos.base.query.v1beta1.PageRequest pagination = 1; | ||
} | ||
|
||
// QueryAccountsResponse is the response type for the Query/Accounts RPC method. | ||
// | ||
// Since: cosmos-sdk 0.43 | ||
message QueryAccountsResponse { | ||
// accounts are the existing accounts | ||
repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "AccountI"]; | ||
|
||
// pagination defines the pagination in the response. | ||
cosmos.base.query.v1beta1.PageResponse pagination = 2; | ||
} | ||
|
||
// QueryAccountRequest is the request type for the Query/Account RPC method. | ||
message QueryAccountRequest { | ||
option (gogoproto.equal) = false; | ||
option (gogoproto.goproto_getters) = false; | ||
|
||
// address defines the address to query for. | ||
string address = 1; | ||
} | ||
|
||
// QueryAccountResponse is the response type for the Query/Account RPC method. | ||
message QueryAccountResponse { | ||
// account defines the account of the corresponding address. | ||
google.protobuf.Any account = 1 [(cosmos_proto.accepts_interface) = "AccountI"]; | ||
} | ||
|
||
// QueryParamsRequest is the request type for the Query/Params RPC method. | ||
message QueryParamsRequest {} | ||
|
||
// QueryParamsResponse is the response type for the Query/Params RPC method. | ||
message QueryParamsResponse { | ||
// params defines the parameters of the module. | ||
Params params = 1 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// QueryModuleAccountsRequest is the request type for the Query/ModuleAccounts RPC method. | ||
message QueryModuleAccountsRequest {} | ||
|
||
// QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. | ||
message QueryModuleAccountsResponse { | ||
repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "ModuleAccountI"]; | ||
} |
Oops, something went wrong.