Skip to content
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

implement ics06 solomachine client #676

Closed
wants to merge 37 commits into from

Conversation

DaviRain-Su
Copy link
Contributor

Closes: #641

Description

The goal of this PR is to implement the ics06 solomachine client in ibc-go. During the process, I used some types from the cosmos-rust repository, but using types from this repository resulted in version mismatch issues between ibc-proto and cosmos-sdk-proto. So, my solution was to replace the proto used in the cosmrs repository with ibc-proto.
Here are some issues encountered:

  1. cosmrs does not support no-std, enable no-std and replate cosmos-sdk-proto to ibc-proto cosmos-rust#404
  2. Version mismatch issues between ibc-proto and cosmos-sdk-proto, Fix Merge the files generated by cosmos-sdk-proto into ibc-proto-rs enable to support no-std ibc-proto-rs#102 enable no-std and replate cosmos-sdk-proto to ibc-proto cosmos-rust#404
  3. The tx::signing types are not implemented in cosmrs. Add cosmos signing type cosmos-rust#405

PR author checklist:

  • Added changelog entry, using unclog.
  • Added tests.
  • Linked to GitHub issue.
  • Updated code comments and documentation (e.g., docs/).
  • Tagged one reviewer who will be the one responsible for shepherding this PR.

Reviewer checklist:

  • Reviewed Files changed in the GitHub PR explorer.
  • Manually tested (in case integration/unit/mock tests are absent).

…tate.rs and implement Ics2ClientState for ClientState class.
…us-network/cosmos-rust repo (new-proto-v0.12.0 branch).
…te`. Updated the proto file imports in all related files.
@codecov
Copy link

codecov bot commented May 12, 2023

Codecov Report

Patch coverage has no change and project coverage change: -3.97 ⚠️

Comparison is base (af477d4) 72.99% compared to head (eba936f) 69.03%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #676      +/-   ##
==========================================
- Coverage   72.99%   69.03%   -3.97%     
==========================================
  Files         113      135      +22     
  Lines       15304    16182     +878     
==========================================
  Hits        11171    11171              
- Misses       4133     5011     +878     
Impacted Files Coverage Δ
.../ibc/src/clients/ics06_solomachine/client_state.rs 0.00% <0.00%> (ø)
...nts/ics06_solomachine/client_state/misbehaviour.rs 0.00% <0.00%> (ø)
...ts/ics06_solomachine/client_state/update_client.rs 0.00% <0.00%> (ø)
...c/src/clients/ics06_solomachine/consensus_state.rs 0.00% <0.00%> (ø)
crates/ibc/src/clients/ics06_solomachine/error.rs 0.00% <0.00%> (ø)
crates/ibc/src/clients/ics06_solomachine/header.rs 0.00% <0.00%> (ø)
.../ibc/src/clients/ics06_solomachine/misbehaviour.rs 0.00% <0.00%> (ø)
...s06_solomachine/misbehaviour/signature_and_data.rs 0.00% <0.00%> (ø)
crates/ibc/src/clients/ics06_solomachine/mod.rs 0.00% <0.00%> (ø)
crates/ibc/src/clients/ics06_solomachine/proof.rs 0.00% <0.00%> (ø)
... and 14 more

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@plafer
Copy link
Contributor

plafer commented May 15, 2023

Hey @DaviRain-Su this is a great initiative! However, since we implemented ADR 4, light clients no longer need to live in ibc-rs. The ibc-rs team currently maintains the tendermint light client because our team has that expertise, but the goal is really to not have to maintain every light client out there. Here's what I suggest:

  1. Move your implementation to a new repository
  2. We add a "list of third-party light client implementations" in our README, link to your crate there so that other people can find it.

Also note that with #296, there will be breaking changes to the ClientState trait. However they shouldn't be too difficult to fix.

@DaviRain-Su
Copy link
Contributor Author

@plafer
Copy link
Contributor

plafer commented May 22, 2023

Awesome! Is the implementation complete? If so, then we'll add a reference to it in our README

@DaviRain-Su
Copy link
Contributor Author

DaviRain-Su commented May 23, 2023

Have not, just on working. breaking on lastet implement verifySignature function.

@plafer
Copy link
Contributor

plafer commented May 23, 2023

I'll close this PR then, and please open a new issue (requesting that we add your crate to our README) when your implementation is ready!

@plafer plafer closed this May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement an Ics06 SoloMachine client
2 participants