Skip to content

Add special handling for IBC Transfer to destination callback #2484

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

Merged
merged 9 commits into from
May 26, 2025

Conversation

chipshort
Copy link
Collaborator

@chipshort chipshort commented May 21, 2025

closes #2398

This adds preparsed information that will only be filled if the packet that arrived is from an IBC transfer. I decided to add this to the message struct instead for simplicity and better discoverability.

Copy link
Member

@kulikthebird kulikthebird left a comment

Choose a reason for hiding this comment

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

LGTM

@chipshort
Copy link
Collaborator Author

chipshort commented May 22, 2025

I've added some more information to the type.
There are usecases for the sender, e.g. when implementing some kind of forwarding, you might want to refund the sender if something fails.
And it seemed a bit arbitrary to me to only handle transfers where the contract is the receiver, so I dropped that limitation and instead add the receiver address, so the contract can check it itself.

@chipshort chipshort changed the title Add funds field to destination callback Add special handling for IBC Transfer to destination callback May 22, 2025
@chipshort chipshort force-pushed the co/ibc-callbacks-funds branch from 5362759 to 9c28a86 Compare May 23, 2025 13:50
Copy link
Member

@kulikthebird kulikthebird left a comment

Choose a reason for hiding this comment

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

Good to go!

@chipshort chipshort force-pushed the co/ibc-callbacks-funds branch from 9c28a86 to e91b17e Compare May 26, 2025 12:51
@chipshort
Copy link
Collaborator Author

I rebased and added a changelog entry

@chipshort chipshort merged commit ec91dcb into main May 26, 2025
42 checks passed
@chipshort chipshort deleted the co/ibc-callbacks-funds branch May 26, 2025 13:11
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 special handling for MsgTransfer IBC destination callback
2 participants