-
Notifications
You must be signed in to change notification settings - Fork 13
Blasrodri/migrate hyp to ev prover #285
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
blasrodri
wants to merge
11
commits into
damian/add-create-ism-command
Choose a base branch
from
blasrodri/migrate-hyp-to-ev-prover
base: damian/add-create-ism-command
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 8 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
b586cee
feat: migrate hyp CLI functionality to ev-prover
blasrodri 2f7185e
fix: correct MsgCreateMailbox proto field order and add validator sor…
blasrodri 237731a
feat: add proto trigger file to enable buf generation of ISM/hook mod…
blasrodri 9defb89
feat: create hyp-cli binary for Hyperlane deployment
blasrodri b7026b7
chore: update proto files for Hyperlane modules
blasrodri 7eae30e
chore: ignore generated files and build artifacts
blasrodri b182d09
fmt
blasrodri 0f42ddd
fix: allow clippy too_many_arguments for MsgCreateZkExecutionIsm::new
blasrodri d43644d
refactor: remove vendored proto files, use buf registry for cosmos deps
blasrodri 7e13602
refactor: replace manual proto types with generated types from buf re…
blasrodri 84f886c
chore: remove unused generated proto files and cargo fmt
blasrodri File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
|
|
@@ -13,4 +13,6 @@ build | |
| pgo-data.profdata | ||
| proof_storage/ | ||
|
|
||
| hyperlane/hyp | ||
| hyperlane/hyp | ||
| hyperlane/cmd/hyp/hyp | ||
| crates/src/ | ||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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 hidden or 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,84 @@ | ||
| 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; | ||
|
|
||
| // oneof_name sets the type name for the given field oneof field. This is used | ||
| // by the Amino JSON encoder to encode the type of the oneof field, and must be the same string in | ||
| // the RegisterConcrete() method usage used to register the concrete type. | ||
| string oneof_name = 11110006; | ||
| } | ||
91 changes: 91 additions & 0 deletions
91
crates/celestia-grpc-client/proto-deps/cosmos/app/v1alpha1/module.proto
This file contains hidden or 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,91 @@ | ||
| syntax = "proto3"; | ||
|
|
||
| package cosmos.app.v1alpha1; | ||
|
|
||
| import "google/protobuf/descriptor.proto"; | ||
|
|
||
| extend google.protobuf.MessageOptions { | ||
| // module indicates that this proto type is a config object for an app module | ||
| // and optionally provides other descriptive information about the module. | ||
| // It is recommended that a new module config object and go module is versioned | ||
| // for every state machine breaking version of a module. The recommended | ||
| // pattern for doing this is to put module config objects in a separate proto | ||
| // package from the API they expose. Ex: the cosmos.group.v1 API would be | ||
| // exposed by module configs cosmos.group.module.v1, cosmos.group.module.v2, etc. | ||
| ModuleDescriptor module = 57193479; | ||
| } | ||
|
|
||
| // ModuleDescriptor describes an app module. | ||
| message ModuleDescriptor { | ||
| // go_import names the package that should be imported by an app to load the | ||
| // module in the runtime module registry. It is required to make debugging | ||
| // of configuration errors easier for users. | ||
| string go_import = 1; | ||
|
|
||
| // use_package refers to a protobuf package that this module | ||
| // uses and exposes to the world. In an app, only one module should "use" | ||
| // or own a single protobuf package. It is assumed that the module uses | ||
| // all of the .proto files in a single package. | ||
| repeated PackageReference use_package = 2; | ||
|
|
||
| // can_migrate_from defines which module versions this module can migrate | ||
| // state from. The framework will check that one module version is able to | ||
| // migrate from a previous module version before attempting to update its | ||
| // config. It is assumed that modules can transitively migrate from earlier | ||
| // versions. For instance if v3 declares it can migrate from v2, and v2 | ||
| // declares it can migrate from v1, the framework knows how to migrate | ||
| // from v1 to v3, assuming all 3 module versions are registered at runtime. | ||
| repeated MigrateFromInfo can_migrate_from = 3; | ||
| } | ||
|
|
||
| // PackageReference is a reference to a protobuf package used by a module. | ||
| message PackageReference { | ||
| // name is the fully-qualified name of the package. | ||
| string name = 1; | ||
|
|
||
| // revision is the optional revision of the package that is being used. | ||
| // Protobuf packages used in Cosmos should generally have a major version | ||
| // as the last part of the package name, ex. foo.bar.baz.v1. | ||
| // The revision of a package can be thought of as the minor version of a | ||
| // package which has additional backwards compatible definitions that weren't | ||
| // present in a previous version. | ||
| // | ||
| // A package should indicate its revision with a source code comment | ||
| // above the package declaration in one of its files containing the | ||
| // text "Revision N" where N is an integer revision. All packages start | ||
| // at revision 0 the first time they are released in a module. | ||
| // | ||
| // When a new version of a module is released and items are added to existing | ||
| // .proto files, these definitions should contain comments of the form | ||
| // "Since: Revision N" where N is an integer revision. | ||
| // | ||
| // When the module runtime starts up, it will check the pinned proto | ||
| // image and panic if there are runtime protobuf definitions that are not | ||
| // in the pinned descriptor which do not have | ||
| // a "Since Revision N" comment or have a "Since Revision N" comment where | ||
| // N is <= to the revision specified here. This indicates that the protobuf | ||
| // files have been updated, but the pinned file descriptor hasn't. | ||
| // | ||
| // If there are items in the pinned file descriptor with a revision | ||
| // greater than the value indicated here, this will also cause a panic | ||
| // as it may mean that the pinned descriptor for a legacy module has been | ||
| // improperly updated or that there is some other versioning discrepancy. | ||
| // Runtime protobuf definitions will also be checked for compatibility | ||
| // with pinned file descriptors to make sure there are no incompatible changes. | ||
| // | ||
| // This behavior ensures that: | ||
| // * pinned proto images are up-to-date | ||
| // * protobuf files are carefully annotated with revision comments which | ||
| // are important good client UX | ||
| // * protobuf files are changed in backwards and forwards compatible ways | ||
| uint32 revision = 2; | ||
| } | ||
|
|
||
| // MigrateFromInfo is information on a module version that a newer module | ||
| // can migrate from. | ||
| message MigrateFromInfo { | ||
|
|
||
| // module is the fully-qualified protobuf name of the module config object | ||
| // for the previous module version, ex: "cosmos.group.module.v1.Module". | ||
| string module = 1; | ||
| } |
56 changes: 56 additions & 0 deletions
56
crates/celestia-grpc-client/proto-deps/cosmos/base/query/v1beta1/pagination.proto
This file contains hidden or 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,56 @@ | ||
| syntax = "proto3"; | ||
| package cosmos.base.query.v1beta1; | ||
|
|
||
| option go_package = "github.com/cosmos/cosmos-sdk/types/query"; | ||
|
|
||
| // PageRequest is to be embedded in gRPC request messages for efficient | ||
| // pagination. Ex: | ||
| // | ||
| // message SomeRequest { | ||
| // Foo some_parameter = 1; | ||
| // PageRequest pagination = 2; | ||
| // } | ||
| message PageRequest { | ||
| // 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. | ||
| bytes key = 1; | ||
|
|
||
| // 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. | ||
| uint64 offset = 2; | ||
|
|
||
| // 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. | ||
| uint64 limit = 3; | ||
|
|
||
| // 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. | ||
| bool count_total = 4; | ||
|
|
||
| // reverse is set to true if results are to be returned in the descending order. | ||
| // | ||
| // Since: cosmos-sdk 0.43 | ||
| bool reverse = 5; | ||
| } | ||
|
|
||
| // PageResponse is to be embedded in gRPC response messages where the | ||
| // corresponding request message has used PageRequest. | ||
| // | ||
| // message SomeResponse { | ||
| // repeated Bar results = 1; | ||
| // PageResponse page = 2; | ||
| // } | ||
| message PageResponse { | ||
| // 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. | ||
| bytes next_key = 1; | ||
|
|
||
| // total is total number of results available if PageRequest.count_total | ||
| // was set, its value is undefined otherwise | ||
| uint64 total = 2; | ||
| } |
61 changes: 61 additions & 0 deletions
61
crates/celestia-grpc-client/proto-deps/cosmos/base/v1beta1/coin.proto
This file contains hidden or 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,61 @@ | ||
| syntax = "proto3"; | ||
| package cosmos.base.v1beta1; | ||
|
|
||
| import "gogoproto/gogo.proto"; | ||
| import "cosmos_proto/cosmos.proto"; | ||
| import "amino/amino.proto"; | ||
|
|
||
| option go_package = "github.com/cosmos/cosmos-sdk/types"; | ||
| option (gogoproto.goproto_stringer_all) = false; | ||
| option (gogoproto.stringer_all) = false; | ||
|
|
||
| // 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. | ||
| message Coin { | ||
| option (gogoproto.equal) = true; | ||
|
|
||
| string denom = 1; | ||
| string amount = 2 [ | ||
| (cosmos_proto.scalar) = "cosmos.Int", | ||
| (gogoproto.customtype) = "cosmossdk.io/math.Int", | ||
| (gogoproto.nullable) = false, | ||
| (amino.dont_omitempty) = true | ||
| ]; | ||
| } | ||
|
|
||
| // DecCoin defines a token with a denomination and a decimal amount. | ||
| // | ||
| // NOTE: The amount field is an Dec which implements the custom method | ||
| // signatures required by gogoproto. | ||
| message DecCoin { | ||
| option (gogoproto.equal) = true; | ||
|
|
||
| string denom = 1; | ||
| string amount = 2 [ | ||
| (cosmos_proto.scalar) = "cosmos.Dec", | ||
| (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", | ||
| (gogoproto.nullable) = false | ||
| ]; | ||
| } | ||
|
|
||
| // IntProto defines a Protobuf wrapper around an Int object. | ||
| // Deprecated: Prefer to use math.Int directly. It supports binary Marshal and Unmarshal. | ||
| message IntProto { | ||
| string int = 1 [ | ||
| (cosmos_proto.scalar) = "cosmos.Int", | ||
| (gogoproto.customtype) = "cosmossdk.io/math.Int", | ||
| (gogoproto.nullable) = false | ||
| ]; | ||
| } | ||
|
|
||
| // DecProto defines a Protobuf wrapper around a Dec object. | ||
| // Deprecated: Prefer to use math.LegacyDec directly. It supports binary Marshal and Unmarshal. | ||
| message DecProto { | ||
| string dec = 1 [ | ||
| (cosmos_proto.scalar) = "cosmos.Dec", | ||
| (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", | ||
| (gogoproto.nullable) = false | ||
| ]; | ||
| } |
30 changes: 30 additions & 0 deletions
30
crates/celestia-grpc-client/proto-deps/cosmos/msg/v1/msg.proto
This file contains hidden or 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,30 @@ | ||
| syntax = "proto3"; | ||
|
|
||
| package cosmos.msg.v1; | ||
|
|
||
| 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/msgservice"; | ||
|
|
||
| extend google.protobuf.ServiceOptions { | ||
| // service indicates that the service is a Msg service and that requests | ||
| // must be transported via blockchain transactions rather than gRPC. | ||
| // Tooling can use this annotation to distinguish between Msg services and | ||
| // other types of services via reflection. | ||
| bool service = 11110000; | ||
| } | ||
|
|
||
| extend google.protobuf.MessageOptions { | ||
| // signer must be used in cosmos messages in order | ||
| // to signal to external clients which fields in a | ||
| // given cosmos message must be filled with signer | ||
| // information (address). | ||
| // The field must be the protobuf name of the message | ||
| // field extended with this MessageOption. | ||
| // The field must either be of string kind, or of message | ||
| // kind in case the signer information is contained within | ||
| // a message inside the cosmos message. | ||
| repeated string signer = 11110000; | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i probably need to be able to import this differently