1

If Alice sends some amount of native relaychain assets to Alice on a parachain and those assets got trapped in some reason, for example lack of amount to execute a message. For AssetTrap and ClaimAsset I use the default pallet-xcm pallet from parity:

type AssetTrap = PolkadotXcm;
type AssetClaims = PolkadotXcm;

What exact XCM message should I execute and where(on the relaychain or on the parachain?)to get thise assets back?

I tried to execute message ClaimAsset + BuyExecution + DepositAsset but I just catch an UnknownClaim Error The ClaimAsset Message looks like

assets: {Concrete: {parents: 1, interior: Here}, fun: Fungable{Fungible: 500_000}}
ticket: {parents: 0, interior: {X1(GeneralIndex(1))}}

Due to pallet code(https://github.com/paritytech/polkadot/blob/37468cac42343dc56e31f83e59da6d8ce12a02a7/xcm/pallet-xcm/src/lib.rs#L1848) maybe I have something wrong with the Origin, but I run the execution from Alice which is a proper reciever account.

1 Answer 1

1

As you have correctly noted, assuming the assets parameter matches exactly what was being trapped, it is indeed a problem with the origin.

I do not know what kind of operation that led to the assets being trapped, but whatever it may be, the origin of the asset claim instruction needs to be the same as the origin of the aforementioned instruction.

It would seem to me from what you've written that it is not clear to you what an origin is. For example, the Alice account on the parachain is a completely different origin from the Alice account on the relay chain.

Therefore, if your original operation that resulted in assets being trapped had the origin of the Alice account from the relay chain, then the subsequent AssetClaim instruction must also be sent from the Alice account from the relay chain, regardless of where the trapped assets are located, because doing so is the only way where the two origins match.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.