chore: AH Migration backport for Interlay #1254
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR aims to protect Interlay's cross chain transfers from the upcoming AHM. During the migration, the inference of DOT reserves may lead to lost of funds, so we need to deactivate those transfers during the process.
A bit more context about this issue: https://forum.polkadot.network/t/mandatory-action-guide-for-ahm-broken-native-crosschain-transfers/14634
The proposed solution follows the approach of the ORML team implemented here: open-web3-stack/open-runtime-module-library#1033.
The affected extrinsics on Interlay are:
xtokens-> all extrinsics.xtokensuse a ReserveProvider to determine the reserve, so the patch is needed here.pallet_xcm->pallet_xcmcalls are filtered out on Interlay, so they're not affected.Please note that all other reserves aren't affected by this patch and keep working as usual. The migration status should be changed by calling the
xtokens.set_migration_phaseextrinsic. This extrinsic is only callable by the root origin on Interlay.As the Interbtc codebase deps are too far in the past, the time doesn't allow to bump everything and bring that change with the ORML crates, so we'll be using an ORML fork from the exact commit used by the Interbtc codebase. The fork is located in the R0gue GitHub organization, concretely here: https://github.com/r0gue-io/open-runtime-module-library/tree/master.
IMPORTANT: This branch slightly modifies the Kintsugi runtime, just for convenience, to allow us compiling the whole workspace. However it MUST be used only to update Interlay