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

Add support for multiple connection hops in tx chan-open-init #3950

Open
13 of 19 tasks
Tracked by #3940 ...
romac opened this issue Apr 16, 2024 · 0 comments
Open
13 of 19 tasks
Tracked by #3940 ...

Add support for multiple connection hops in tx chan-open-init #3950

romac opened this issue Apr 16, 2024 · 0 comments
Assignees
Labels
O: multi-hop Related to ICS 033 Multi-Hop Channel

Comments

@romac
Copy link
Member

romac commented Apr 16, 2024

Summary

tx chan-open-init

  • Add --connection-hops=conn1,conn2,conn3 parameter to tx chan-open-init
  • Define ConnectionHop struct
  • Define ConnectionHops struct initially with single field hops: Vec<ConnectionHop>
  • Fetch alls connections and store them in ConnectionHops
    • 1. Fetch destination connection (--dst-connection) on the destination
    • 2. Fetch the client state for the client underlying that connection on the destination chain
    • 3. Get the counterparty chain id from the client state
    • 4. Do this for all connection hops, from last to first
  • Add connection_hops: ConnectionHops field to Channel struct
  • Add support for connection hops to Channel::build_chan_open_init_and_send
    • Change connection_id field on struct Attributes to a Vec<ConnectionId>
    • Parse connection_ids from channel_open_init event into Attributes.connection_id
  • Write unit tests for tx chan-open-init with --connection-hops
  • Write integration test for single hop channel
struct ConnectionHop {
  pub connection: IdentifiedConnectionEnd,
  pub client_state: AnyClientState,
  pub reference_chain_id: ChainId,
}

For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate milestone (priority) applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@romac romac added the O: multi-hop Related to ICS 033 Multi-Hop Channel label Apr 16, 2024
@romac romac mentioned this issue Apr 16, 2024
33 tasks
@ancazamfir ancazamfir changed the title Add support for single connection hop in tx chan-open-init Add support for multiple connection hops in tx chan-open-init Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O: multi-hop Related to ICS 033 Multi-Hop Channel
Projects
Status: 🩹 Triage
Development

No branches or pull requests

2 participants