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

Handle failed XCM transfers when off-ramping from AssetHub #346

Closed
gianfra-t opened this issue Dec 30, 2024 · 3 comments · Fixed by #349
Closed

Handle failed XCM transfers when off-ramping from AssetHub #346

gianfra-t opened this issue Dec 30, 2024 · 3 comments · Fixed by #349
Assignees
Labels
type:bug Something isn't working

Comments

@gianfra-t
Copy link
Contributor

Issue description

A user attempted an off-ramp starting from AssetHub (XCM transaction here) yet found that the application was stuck after signing.

This is most likely because we are not handling the case when the transaction is successful, yet the XCM execution itself is not. In this case, the application will wait indefinitely for the funds to arrive at Pendulum.

Also, this failed XCM should potentially have been prevented in the first place. The current theory is that it failed initially due to Existential Deposit issues, since the USDC amount attempted to be transferred was very close to the full amount the user had. A second xcm with a lower amount worked well.

Potential fixes

We could query the status of the XCM here, by listening to the events of that block and checking if the XCM failed.

Aside from that, we need to verify if the existential deposit was the root cause of the first failed off-ramp, and if so, consider it here.

@gianfra-t gianfra-t added the type:bug Something isn't working label Dec 30, 2024
@gianfra-t
Copy link
Contributor Author

gianfra-t commented Dec 30, 2024

@pendulum-chain/product although there is no risk of loosing funds with this, we should consider fixing this to make Assethub off-ramps more robust. It is very likely users will try to off-ramp all it's USDC and this happens again.

@prayagd
Copy link
Collaborator

prayagd commented Jan 1, 2025

@gianfra-t is there a ED for USDC too on Assethub? if that's the case then a quick solution would be to show the balance minus ED on the vortex UI

@gianfra-t
Copy link
Contributor Author

Yup, that's a good simple solution. I think there is an ED for any token. What remains to be seen is if it works if all balance is transferred, we may have to use the transfer_all in this case to allow for people to do that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants