You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently there is no easy way to build on top of cosm-tome and generically handle different clients. I think the current method of bundling ChainConfig and a generic client T together inside CosmTome is not the best api. If I don't know which client I want to use at compile time there is no easy way to build on top. My suggestion is to completely do away with the CosmTome type and instead simply use extension traits. For every client that is CosmosClient we get all of the nice cosm_tome methods.
This is much more flexible since it allows users to utilize the CosmosClient trait much more easily. It would also make dynamic dispatch possible with clients that are unknown at compile time. If you're okay with this change I would love to submit a PR. This issue is currently blocking me in my development of wasm-deploy.
0xForerunner
changed the title
Change the api to something that is more conducive to handling clients generically
Change the api to something that is more conducive to handling clients through dynamic dispatch
Mar 27, 2023
So my current project has required me to have support for the latest version of tendermint_rpc. I am currently working on a very large overhaul with lots of rather sweeping changes (including the one referenced above). Will submit a draft PR when I'm a little closer to completion.
Currently there is no easy way to build on top of cosm-tome and generically handle different clients. I think the current method of bundling ChainConfig and a generic client T together inside CosmTome is not the best api. If I don't know which client I want to use at compile time there is no easy way to build on top. My suggestion is to completely do away with the CosmTome type and instead simply use extension traits. For every client that is CosmosClient we get all of the nice cosm_tome methods.
Here is an example of the current api
and here is what it could look like with my suggested change
The text was updated successfully, but these errors were encountered: