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

Migration to recent stargate #449

Merged
merged 35 commits into from
Dec 23, 2020
Merged

Migration to recent stargate #449

merged 35 commits into from
Dec 23, 2020

Conversation

ancazamfir
Copy link
Collaborator

@ancazamfir ancazamfir commented Dec 14, 2020

Closes: cosmos/ibc-proto-rs#12
Closes: #443
Closes: #468
Closes: #379

Description

Draft PR for migration to latest tm and cosmos.
Change summary:

  • tendermint dep romac/skip-verif off v0.17

  • added confio's ics23 crate

    • not fully integrated yet
  • Height related fields version_.. change to revision_.. @adizere

  • createClient, connOpenInit, connOpenTry, chanOpenInit, chanOpenTry do not pass an ID anymore, the allocated ID is returned in the TxResult

    • minimal changes to compile the code
    • config not changed
    • relayer loop not changed
    • CLIs work because the IDs are ignored
    • tests fail @adizere
    • handlers need changes @adizere
  • connection Version is typed (used to be String)

    • changed msg structs accordingly
  • some raw types have changed

    • minimum changes so the code compiles
  • proto-compiler

    • changed the commit hash to one extracted from go.mod of Go relayer on branch colin/329-handshake-refactor
    • [X] the tonic compiler overwrites the previous prost compiler results, effect is missing files for genesis, tx, etc.
    • [X] with temp fix for ^ the protos need some manual fixes and also the genereated files (on inculde of tendermint doesn't work)
    • need to modify the proto files for tonic to compile
    • grpc client generated code is not formatted
  • added some ack and timeout related code

    • CLIs work, need to finish the relaying part

For contributor use:

  • Updated the Unreleased section of CHANGELOG.md with the issue.
  • If applicable: Unit tests written, added test to CI.
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Updated relevant documentation (docs/) and code comments.
  • Re-reviewed Files changed in the Github PR explorer.

@codecov-io
Copy link

codecov-io commented Dec 17, 2020

Codecov Report

Merging #449 (ae945fb) into master (b1b37f5) will increase coverage by 16.2%.
The diff coverage is 57.3%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    informalsystems/hermes#449      +/-   ##
=========================================
+ Coverage    13.6%   29.9%   +16.2%     
=========================================
  Files          69     156      +87     
  Lines        3752   12692    +8940     
  Branches     1374    4968    +3594     
=========================================
+ Hits          513    3800    +3287     
- Misses       2618    8202    +5584     
- Partials      621     690      +69     
Impacted Files Coverage Δ
modules/src/events.rs 0.0% <0.0%> (ø)
modules/src/ics02_client/events.rs 0.0% <0.0%> (ø)
modules/src/ics02_client/msgs.rs 0.0% <0.0%> (ø)
modules/src/ics02_client/raw.rs 0.0% <0.0%> (ø)
modules/src/ics03_connection/error.rs 13.6% <0.0%> (-19.7%) ⬇️
modules/src/ics03_connection/events.rs 0.0% <0.0%> (ø)
modules/src/ics04_channel/error.rs 75.0% <ø> (+50.0%) ⬆️
modules/src/ics04_channel/events.rs 0.0% <ø> (ø)
modules/src/ics04_channel/msgs/acknowledgement.rs 52.0% <ø> (ø)
...dules/src/ics04_channel/msgs/chan_close_confirm.rs 70.2% <ø> (ø)
... and 286 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 39ff928...ae945fb. Read the comment docs.

@ancazamfir ancazamfir marked this pull request as ready for review December 22, 2020 10:12
@adizere adizere mentioned this pull request Dec 22, 2020
8 tasks
@adizere
Copy link
Member

adizere commented Dec 23, 2020

For testing, based on instructions compiled by @ancazamfir, we used the config file loop_config.toml and commands from here.

Copy link
Member

@adizere adizere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Impressive work, Anca!

Looks good based on our raw CLIs testing for client, connections, and channels. We'll collect follow-up stuff in 469.

@adizere adizere merged commit db2be6f into master Dec 23, 2020
@adizere adizere deleted the anca/stargate_five branch December 23, 2020 14:33
@adizere adizere restored the anca/stargate_five branch December 23, 2020 14:33
@adizere adizere deleted the anca/stargate_five branch December 23, 2020 14:35
hu55a1n1 pushed a commit to hu55a1n1/hermes that referenced this pull request Sep 13, 2022
* Initial migration changes

* More changes, add some of the ack CLIs

* cleanup

* fix packet ack

* clippy and fmt fixes

* Fixed connOpenTry tests; ignored update client tests

* Fixed ack msg tests

* Added next identifier generation in mock context

* Fixed ICS26 tests

* Fix for relayer tests

* Timeout packet, add Uninit for conn and chan, extract clientId

* Fix option order in packet Tx clis

* Tx result parsing (not generalized yet)

* add extern paths back

* WIP General event parsing out of tx response

* change packet envelope to packet

* Make the code compile, return clientID in relayer and CLI

* event parsing and matching for conn open init

* Change tm dependency, fix update client CLI

* log fix and move to cosmos v0.40.0-rc5 (no changes)

* Finished connection CLIs

* Event parsing and fixes for channel open CLIs

* add more event attributes, some refactor of the packet CLIs and packet relaying

* cleanup CLI output for channel, add more fields to events

* Fix relayer connection loop for dynamic IDs

* Fix relayer channel loop for dynamic IDs, started on config cleanup

* Cleanup relayer config

* update Changelog

* fix channel verification for packets

* Fix changelog typo

Co-authored-by: Adi Seredinschi <adi@informal.systems>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants