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

pallet_asset_tx_payment can't support xcm::v4::Location as an AssetId #6911

Open
2 tasks done
JuaniRios opened this issue Dec 16, 2024 · 1 comment
Open
2 tasks done
Labels
I2-bug The node fails to follow expected behavior. T6-XCM This PR/Issue is related to XCM.

Comments

@JuaniRios
Copy link
Contributor

JuaniRios commented Dec 16, 2024

Is there an existing issue?

  • I have searched the existing issues

Experiencing problems? Have you tried our Stack Exchange first?

  • This is not a support question.

Description of bug

The pallet has the asset id as an associated type of the OnChargeAssetTransaction trait, but it expects it to implement Copy.
v3::Multilocation used to implement Copy so this was fine, but now v4::Location doesn't implement copy.

This means it's impossible to directly have Location as the AssetId, so we have to accept v3, and do some unnecessary internal conversions to v4 inside the withdraw_fee method

@JuaniRios JuaniRios added I10-unconfirmed Issue might be valid, but it's not yet known. I2-bug The node fails to follow expected behavior. labels Dec 16, 2024
@franciscoaguirre franciscoaguirre added T6-XCM This PR/Issue is related to XCM. and removed I10-unconfirmed Issue might be valid, but it's not yet known. labels Dec 16, 2024
@franciscoaguirre
Copy link
Contributor

A solution is to make pallet_asset_tx_payment require Clone instead of Copy, which is more lenient

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I2-bug The node fails to follow expected behavior. T6-XCM This PR/Issue is related to XCM.
Projects
Status: Todo
Development

No branches or pull requests

2 participants