cosmos / ibc-proto-rs

Rust Protobuf definitions and gRPC clients for interacting with Cosmos SDK, IBC and Interchain Security
Apache License 2.0
45 stars 26 forks source link

Server side code generation for the proto files #8

Closed adizere closed 2 years ago

adizere commented 3 years ago

Crate

ibc-proto

Summary

Enable server-side compilation of Rust code for proto files.

Problem Definition

Motivation

Currently, integration tests between Hermes and the ibc crate are rather thin: there's only a few tests with the most complete ones in ForeignClient. In these tests, we are able to build a ChainRuntime<MockChain> and play out some basic Hermes functionality (such as client creation) against a Mock chain; these tests don't exercise any serialization and their coverage is very limited. It would be ideal to be able to go further, and have an external Mock chain running as a separate process that acts as a real chain would, and which builds on our ibc crate. The tendermock project is an attempt to do that -- building a chain (albeit, a mock one) around the ibc crate, so that Hermes can interact with our IBC-rust implementation.

There are a few goals we're pursuing with this:

Problem

Among others, Tendermock needs to be able to spawn a gRPC server and a JsonRPC as well as a websocket (just like a TM full node would), and for doing so it needs access to server-side proto definitions.

Originally proposed some time ago https://github.com/informalsystems/ibc-rs/issues/425#issuecomment-735920505 but it got overlooked.

Acceptance Criteria


For Admin Use

adizere commented 2 years ago

No longer relevant.