Description
When calling getDestinationXcmWeightToFeeAsset with Interlay parachain, we have following behavior:
-
If the Interlay url is given in the chainUrl
const destinationFeesInfo = await AssetTransferApi.getDestinationXcmWeightToFeeAsset(
'interlay-parachain',
'wss://interlay-rpc.dwellir.com',
this.safeXcmVersion,
dryRunResult,
tokenCode,
);
the following error is thrown:
Error estimating fee:' TypeError: Cannot read properties of undefined (reading 'queryXcmWeight')
-
If the Bifrost url is given in the chainUrl
const destinationFeesInfo = await AssetTransferApi.getDestinationXcmWeightToFeeAsset(
'interlay-parachain',
'wss://bifrost-polkadot.ibp.network',
this.safeXcmVersion,
dryRunResult,
tokenCode,
);
The fee is retrieved
Root Cause
It seems that Interlay does not currently support the xcmPaymentApi so the queryXcmWeight function is not found when using their runtime.
Suggested Solution
Update the API to check for this error case.
Credits
Creadits to @marshacb for checking this issue.
Description
When calling
getDestinationXcmWeightToFeeAssetwithInterlayparachain, we have following behavior:If the Interlay url is given in the
chainUrlthe following error is thrown:
If the Bifrost url is given in the
chainUrlThe fee is retrieved
Root Cause
It seems that
Interlaydoes not currently support thexcmPaymentApiso thequeryXcmWeightfunction is not found when using their runtime.Suggested Solution
Update the API to check for this error case.
Credits
Creadits to @marshacb for checking this issue.