Skip to content

Replay failed XCM messages command#1589

Merged
claravanstaden merged 4 commits intomainfrom
clara/replay-ref
Oct 1, 2025
Merged

Replay failed XCM messages command#1589
claravanstaden merged 4 commits intomainfrom
clara/replay-ref

Conversation

@claravanstaden
Copy link
Contributor

@claravanstaden claravanstaden commented Sep 30, 2025

Replays failed transactions after Polkadot 1.7.1 upgrade.

@alistair-singh
Copy link
Contributor

# select message_id, sender_address, token_address, destination_address, amount from transfer_status_to_ethereum where status = 0;
                             message_id                             |                           sender_address                           |               token_address                |            destination_address             |         amount
--------------------------------------------------------------------+--------------------------------------------------------------------+--------------------------------------------+--------------------------------------------+-------------------------
 0x1ae83a0cba8f448c466fb0863fc25827b6978b7c3b3f93785184412cb2632e31 | 0xce6451a1009f679e180da08fd56dd122ed4409e997e903507f455611dab59036 | 0x0000000000000000000000000000000000000000 | 0xad8d4c544a6ce24b89841354b2738e026a12bca4 |      350000000000000000
 0xe259e4fb1c24f7cf4e6d2a9d50e13794de5fd6863083addc3d55ddff3b3d58cd | 0xd27ae5ce63ee6fb5c53f3e08d91c8df695514cb8076d42a63b1b064de0227620 | 0x7fc66500c84a76ad7e9c93437bfc5ac33e2ddae9 | 0xa9c415d6881e1a992861a7fa6bef3ed4736152c2 |   212116067921877821839
 0xc8864869cd4ed5921d5cc251290357ffb24f905e1a475a2ba6c9ecd96c55df71 | 0x455448002265a7503597ab32bab72eaa186e6329fb7b68f30000000000000000 | 0x7fc66500c84a76ad7e9c93437bfc5ac33e2ddae9 | 0x2265a7503597ab32bab72eaa186e6329fb7b68f3 |    33044703802651993696
 0xf701fb349a04e4c923e26aab4e0288975d904507cdc32a3d3bdab8105507c736 | 0x7279fcf9694718e1234d102825dccaf332f0ea36edf1ca7c0358c4b68260d24b | 0x56072c95faa701256059aa122697b133aded9279 | 0x601d579ecd0464a1a090ceef81a703465a1679cd | 90413710543975890000000
 0xd289d29c0ccbca0fe47be2a0bf8d09af3a90d719ce62129d75714a342750b6e4 | 0x7279fcf9694718e1234d102825dccaf332f0ea36edf1ca7c0358c4b68260d24b | 0x18084fba666a33d37592fa2633fd49a74dd93a88 | 0x601d579ecd0464a1a090ceef81a703465a1679cd |      250830765728855800
 0xe4cff6bf2217eb4cf9332d2daee1ada70b405402414a2249a6e9b42ab759f93f | 0x0a6679243e822e0538039d187529d67c1bb74d8d5f121be63d00243233b4b01c | 0x9d39a5de30e57443bff2a8307a4256c8797a3497 | 0x9117900a3794ad6d167dd97853f82a1aa07f9bbc | 16716000000000000000000

weight_limit: WeightLimit::Unlimited,
check_origin: None,
},
DescendOrigin(Junctions::X1([Junction::Parachain(1000)])),
Copy link
Contributor

Choose a reason for hiding this comment

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

We should test in chopsticks without the DescendOrigin. Not sure if its needed as we dont really validate the origin of asset hub.

Copy link
Contributor

@yrong yrong Oct 1, 2025

Choose a reason for hiding this comment

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

we dont really validate the origin of asset hub.

We do — the Barrier enforced on BH will deny ExportMessage from anywhere (including the Relay chain) except AH.

So it looks like this PR won’t work. Replaying the transaction would still require constructing an XCM from AH - Potentially a Transact that sends ExportMessage directly to BH to bypass the 1.5DOT fee - which seems a bit too complicated.

Or, we may need to reconsider upgrading the Gateway to unlock the asset directly to the recipient?

Copy link
Contributor

@yrong yrong Oct 1, 2025

Choose a reason for hiding this comment

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

Draft #1590 for reference.

Copy link
Contributor

@alistair-singh alistair-singh left a comment

Choose a reason for hiding this comment

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

Confirmed the users and amounts as per the data above.

Comment on lines +864 to +881
let failed_messages: Vec<(AssetType, u128, [u8; 20], [u8; 32])> = vec![
// SKY token transfer
(
AssetType::Erc20(hex!("56072c95faa701256059aa122697b133aded9279")),
90413710543975890000000,
hex!("601d579ecd0464a1a090ceef81a703465a1679cd"),
hex!("f701fb349a04e4c923e26aab4e0288975d904507cdc32a3d3bdab8105507c736"),
),
// sUSDe token transfer
(
AssetType::Erc20(hex!("9d39a5de30e57443bff2a8307a4256c8797a3497")),
16716000000000000000000,
hex!("9117900a3794ad6d167dd97853f82a1aa07f9bbc"),
hex!("e4cff6bf2217eb4cf9332d2daee1ada70b405402414a2249a6e9b42ab759f93f"),
),
// tBTC v2 token transfer
(
AssetType::Erc20(hex!("18084fba666a33d37592fa2633fd49a74dd93a88")),
Copy link
Contributor

@yrong yrong Oct 1, 2025

Choose a reason for hiding this comment

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

Double-checked — everything looks as expected. Just a nitpick: better to list the failing transfers in strict order:

select message_id, token_address, destination_address, amount from transfer_status_to_ethereum where status = 0 order by timestamp ASC;

Copy link
Contributor

@yrong yrong left a comment

Choose a reason for hiding this comment

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

+1

@yrong yrong mentioned this pull request Oct 1, 2025
@claravanstaden
Copy link
Contributor Author

Preimage:

Preimage Hash: 0x96f63057d3d22f4bb5f201bd17208e4363dbf06b3c698bc95777795983fb7628
Preimage Size: 985
0x630005000100a10f050c2f0000060201824ceaa2e972fd0e1f0005010100a90f05342f0000260704001400040001030056072c95faa701256059aa122697b133aded9279001b8098cb9060334a5625130a130001030056072c95faa701256059aa122697b133aded92790004000d01020400010300601d579ecd0464a1a090ceef81a703465a1679cd2cf701fb349a04e4c923e26aab4e0288975d904507cdc32a3d3bdab8105507c7362cf701fb349a04e4c923e26aab4e0288975d904507cdc32a3d3bdab8105507c73626070400140004000103009d39a5de30e57443bff2a8307a4256c8797a3497001b0000b015d6da192d8a030a13000103009d39a5de30e57443bff2a8307a4256c8797a34970004000d010204000103009117900a3794ad6d167dd97853f82a1aa07f9bbc2ce4cff6bf2217eb4cf9332d2daee1ada70b405402414a2249a6e9b42ab759f93f2ce4cff6bf2217eb4cf9332d2daee1ada70b405402414a2249a6e9b42ab759f93f260704001400040001030018084fba666a33d37592fa2633fd49a74dd93a880013f8f601a240217b030a130001030018084fba666a33d37592fa2633fd49a74dd93a880004000d01020400010300601d579ecd0464a1a090ceef81a703465a1679cd2cd289d29c0ccbca0fe47be2a0bf8d09af3a90d719ce62129d75714a342750b6e42cd289d29c0ccbca0fe47be2a0bf8d09af3a90d719ce62129d75714a342750b6e426070400140004000103007fc66500c84a76ad7e9c93437bfc5ac33e2ddae90017606612b9075f96ca010a13000103007fc66500c84a76ad7e9c93437bfc5ac33e2ddae90004000d010204000103002265a7503597ab32bab72eaa186e6329fb7b68f32cc8864869cd4ed5921d5cc251290357ffb24f905e1a475a2ba6c9ecd96c55df712cc8864869cd4ed5921d5cc251290357ffb24f905e1a475a2ba6c9ecd96c55df7126070400140004000103007fc66500c84a76ad7e9c93437bfc5ac33e2ddae900178f692894efa7b37f0b0a13000103007fc66500c84a76ad7e9c93437bfc5ac33e2ddae90004000d01020400010300a9c415d6881e1a992861a7fa6bef3ed4736152c22ce259e4fb1c24f7cf4e6d2a9d50e13794de5fd6863083addc3d55ddff3b3d58cd2ce259e4fb1c24f7cf4e6d2a9d50e13794de5fd6863083addc3d55ddff3b3d58cd2607040014000400000013000063472573db040a1300000004000d01020400010300ad8d4c544a6ce24b89841354b2738e026a12bca42c1ae83a0cba8f448c466fb0863fc25827b6978b7c3b3f93785184412cb2632e312c1ae83a0cba8f448c466fb0863fc25827b6978b7c3b3f93785184412cb2632e312000

@claravanstaden claravanstaden merged commit 4329251 into main Oct 1, 2025
1 of 2 checks passed
@claravanstaden claravanstaden deleted the clara/replay-ref branch October 1, 2025 11:20
stiiifff pushed a commit to datahaven-xyz/snowbridge that referenced this pull request Nov 25, 2025
* update metadata

* upgrade xcm and replay command

* try routing through asset hub

* fix relative dest

---------

Co-authored-by: Alistair Singh <alistair.singh7@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants