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

feat: Add ICS20 TransferV2 #2317

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open

Conversation

kulikthebird
Copy link
Contributor

No description provided.

@kulikthebird kulikthebird linked an issue Dec 13, 2024 that may be closed by this pull request
2 tasks
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from a1910c3 to 0031a25 Compare December 17, 2024 09:43
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from c02e541 to 2288ae6 Compare January 8, 2025 12:37
@kulikthebird kulikthebird changed the title feat: Add TransferV2 feat: Add ICS20 TransferV2 Jan 10, 2025
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch 6 times, most recently from 8622495 to 2c6e84d Compare January 27, 2025 12:22
@kulikthebird kulikthebird marked this pull request as ready for review January 27, 2025 14:46
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from 2c6e84d to 40b1383 Compare January 29, 2025 11:52
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch 4 times, most recently from bf68aef to e934799 Compare January 29, 2025 19:31
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch 4 times, most recently from 9a7f3f5 to 3714b3a Compare January 30, 2025 11:27
@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from 3714b3a to 39179ac Compare January 30, 2025 11:36
Copy link
Collaborator

@chipshort chipshort left a comment

Choose a reason for hiding this comment

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

Looks nice. Some small comments, mostly about the builder.

contracts/ibc-callbacks/src/msg.rs Outdated Show resolved Hide resolved
packages/std/src/ibc.rs Outdated Show resolved Hide resolved
packages/std/src/ibc/transfer_msg_builder.rs Outdated Show resolved Hide resolved
packages/std/src/ibc/transfer_msg_builder_v2.rs Outdated Show resolved Hide resolved
Comment on lines 107 to 108
/// It is worth to notice that the builder does not allow to add forwarding data along with
/// callbacks. It is discouraged in the IBC docs:
Copy link
Collaborator

Choose a reason for hiding this comment

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

The IBC docs specifically mention source callbacks. Destination callbacks are fine.
Can we allow that combination forwarding + destination callback in the builder?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed

@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from 4a4172f to a1b922e Compare February 3, 2025 08:01
Copy link
Collaborator

@chipshort chipshort left a comment

Choose a reason for hiding this comment

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

Some small comments in addition to what we talked about on Slack

contracts/ibc-callbacks/src/msg.rs Show resolved Hide resolved
packages/std/src/ibc/transfer_msg_builder_v2.rs Outdated Show resolved Hide resolved
let with_both_callbacks2 = with_dst_callback_builder
.with_src_callback(src_callback.clone())
.build();

Copy link
Collaborator

Choose a reason for hiding this comment

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

Can we add the combinations of forwarding + source callback here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We can't, because it is disallowed by the builder type

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ah, sorry, I meant destination callback, not source

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point, now we test that in the line above:

let unwinding = unwinding_builder
            .with_dst_callback(dst_callback.clone())
            .build();

@kulikthebird kulikthebird force-pushed the tkulik/feat/ibc_transfer_v2 branch from 8e8a6ef to 7c094bb Compare February 7, 2025 15:31
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.

Add support for IBC FungibleTokenPacketDataV2 message
2 participants