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

Add claim_assets extrinsic to pallet-xcm #3403

Merged
merged 28 commits into from
Mar 1, 2024
Merged

Conversation

franciscoaguirre
Copy link
Contributor

@franciscoaguirre franciscoaguirre commented Feb 20, 2024

If an XCM execution fails or ends with leftover assets, these will be trapped.
In order to claim them, a custom XCM has to be executed, with the ClaimAsset instruction.
However, arbitrary XCM execution is not allowed everywhere yet and XCM itself is still not easy enough to use for users out there with trapped assets.
This new extrinsic in pallet-xcm will allow these users to easily claim their assets, without concerning themselves with writing arbitrary XCMs.

Part of fixing #3495

@franciscoaguirre franciscoaguirre requested a review from a team as a code owner February 20, 2024 11:25
@franciscoaguirre franciscoaguirre changed the title Add claim_assets extrinsic to pallet-xcm Add claim_assets extrinsic to pallet-xcm Feb 20, 2024
@franciscoaguirre franciscoaguirre added the T6-XCM This PR/Issue is related to XCM. label Feb 20, 2024
@franciscoaguirre
Copy link
Contributor Author

bot fmt

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5274796 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/fmt/fmt.sh". Check out https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment bot cancel 5-d84311d5-e612-4d99-923e-9b7c4383a0d1 to cancel this command or bot cancel to cancel all commands in this pull request.

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre Command "$PIPELINE_SCRIPTS_DIR/commands/fmt/fmt.sh" has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5274796 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5274796/artifacts/download.

@franciscoaguirre franciscoaguirre marked this pull request as draft February 20, 2024 11:36
@franciscoaguirre
Copy link
Contributor Author

bot fmt

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5280685 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/fmt/fmt.sh". Check out https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment bot cancel 6-553d1d91-4d1f-4e36-ba58-b5ba944ed967 to cancel this command or bot cancel to cancel all commands in this pull request.

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre Command "$PIPELINE_SCRIPTS_DIR/commands/fmt/fmt.sh" has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5280685 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5280685/artifacts/download.

@franciscoaguirre
Copy link
Contributor Author

bot help

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

Here's a link to docs

@franciscoaguirre
Copy link
Contributor Author

bot bench cumulus-assets --runtime asset-hub-westend --pallet pallet_xcm

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5282967 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=asset-hub-westend --runtime_dir=assets --target_dir=cumulus --pallet=pallet_xcm. Check out https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment bot cancel 7-90d2532d-a4e0-4919-97d9-408dbde57b98 to cancel this command or bot cancel to cancel all commands in this pull request.

…=asset-hub-westend --runtime_dir=assets --target_dir=cumulus --pallet=pallet_xcm
@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=asset-hub-westend --runtime_dir=assets --target_dir=cumulus --pallet=pallet_xcm has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5282967 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5282967/artifacts/download.

@franciscoaguirre
Copy link
Contributor Author

bot bench cumulus-assets --runtime asset-hub-rococo --pallet pallet_xcm
bot bench cumulus-collectives --pallet pallet_xcm
bot bench cumulus-coretime --runtime coretime-rococo --pallet pallet_xcm
bot bench cumulus-coretime --runtime coretime-westend --pallet pallet_xcm
bot bench cumulus-bridge-hubs --runtime bridge-hub-rococo --pallet pallet_xcm
bot bench cumulus-bridge-hubs --runtime bridge-hub-westend --pallet pallet_xcm
bot bench cumulus-people --runtime people-rococo --pallet pallet_xcm
bot bench cumulus-people --runtime people-westend --pallet pallet_xcm
bot bench polkadot-pallet --runtime rococo --pallet pallet_xcm
bot bench polkadot-pallet --runtime westend --pallet pallet_xcm

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5284753 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=asset-hub-rococo --runtime_dir=assets --target_dir=cumulus --pallet=pallet_xcm. Check out https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment bot cancel 8-559e95c8-48fc-4d09-bd92-67ea9ed0ec63 to cancel this command or bot cancel to cancel all commands in this pull request.

@command-bot
Copy link

command-bot bot commented Feb 20, 2024

@franciscoaguirre https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5284754 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=collectives-westend --runtime_dir=collectives --target_dir=cumulus --pallet=pallet_xcm. Check out https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment bot cancel 9-9182b51d-8c18-40fd-884b-7269a464bc36 to cancel this command or bot cancel to cancel all commands in this pull request.

polkadot/runtime/rococo/src/lib.rs Outdated Show resolved Hide resolved
polkadot/runtime/rococo/src/lib.rs Outdated Show resolved Hide resolved
polkadot/runtime/rococo/src/lib.rs Outdated Show resolved Hide resolved
polkadot/runtime/rococo/src/lib.rs Outdated Show resolved Hide resolved
polkadot/runtime/rococo/src/lib.rs Outdated Show resolved Hide resolved
polkadot/xcm/pallet-xcm/src/lib.rs Outdated Show resolved Hide resolved
polkadot/xcm/pallet-xcm/src/lib.rs Outdated Show resolved Hide resolved
polkadot/xcm/pallet-xcm/src/lib.rs Outdated Show resolved Hide resolved
polkadot/xcm/pallet-xcm/src/lib.rs Show resolved Hide resolved
polkadot/xcm/pallet-xcm/src/lib.rs Outdated Show resolved Hide resolved
@acatangiu acatangiu added this pull request to the merge queue Feb 27, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 27, 2024
@acatangiu acatangiu added this pull request to the merge queue Mar 1, 2024
Merged via the queue into master with commit 6508866 Mar 1, 2024
129 of 130 checks passed
@acatangiu acatangiu deleted the claim-assets-extrinsic branch March 1, 2024 08:02
franciscoaguirre added a commit that referenced this pull request Mar 1, 2024
If an XCM execution fails or ends with leftover assets, these will be
trapped.
In order to claim them, a custom XCM has to be executed, with the
`ClaimAsset` instruction.
However, arbitrary XCM execution is not allowed everywhere yet and XCM
itself is still not easy enough to use for users out there with trapped
assets.
This new extrinsic in `pallet-xcm` will allow these users to easily
claim their assets, without concerning themselves with writing arbitrary
XCMs.

Part of fixing #3495

---------

Co-authored-by: command-bot <>
Co-authored-by: Adrian Catangiu <adrian@parity.io>
acatangiu added a commit that referenced this pull request Mar 1, 2024
Backport #3403 to
polkadot-sdk 1.7.0

Co-authored-by: Adrian Catangiu <adrian@parity.io>
ordian added a commit that referenced this pull request Mar 4, 2024
* master:
  Finish documenting `#[pallet::xxx]` macros  (#2638)
  Remove `as frame_system::DefaultConfig` from the required syntax in `derive_impl` (#3505)
  provisioner: allow multiple cores assigned to the same para (#3233)
  subsystem-bench: add regression tests for availability read and write (#3311)
  make SelfParaId a metadata constant (#3517)
  Fix crash of synced parachain node run with `--sync=warp` (#3523)
  [Backport] Node version and spec_version bumps and ordering of the prdoc files from 1.8.0 (#3508)
  Add `claim_assets` extrinsic to `pallet-xcm` (#3403)
ordian added a commit that referenced this pull request Mar 4, 2024
…data

* ao-collator-parent-head-data:
  add a comment (review)
  Finish documenting `#[pallet::xxx]` macros  (#2638)
  Remove `as frame_system::DefaultConfig` from the required syntax in `derive_impl` (#3505)
  provisioner: allow multiple cores assigned to the same para (#3233)
  subsystem-bench: add regression tests for availability read and write (#3311)
  make SelfParaId a metadata constant (#3517)
  Fix crash of synced parachain node run with `--sync=warp` (#3523)
  [Backport] Node version and spec_version bumps and ordering of the prdoc files from 1.8.0 (#3508)
  Add `claim_assets` extrinsic to `pallet-xcm` (#3403)
skunert pushed a commit to skunert/polkadot-sdk that referenced this pull request Mar 4, 2024
If an XCM execution fails or ends with leftover assets, these will be
trapped.
In order to claim them, a custom XCM has to be executed, with the
`ClaimAsset` instruction.
However, arbitrary XCM execution is not allowed everywhere yet and XCM
itself is still not easy enough to use for users out there with trapped
assets.
This new extrinsic in `pallet-xcm` will allow these users to easily
claim their assets, without concerning themselves with writing arbitrary
XCMs.

Part of fixing paritytech#3495

---------

Co-authored-by: command-bot <>
Co-authored-by: Adrian Catangiu <adrian@parity.io>
@failedpolkatransfer
Copy link

is there a steps in claiming trapped assets?

@Polkadot-Forum
Copy link

This pull request has been mentioned on Polkadot Forum. There might be relevant details there:

https://forum.polkadot.network/t/parity-tech-update-for-march/7226/1

@Polkadot-Forum
Copy link

This pull request has been mentioned on Polkadot Forum. There might be relevant details there:

https://forum.polkadot.network/t/xcm-user-and-developer-experience-improvements/4511/21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T6-XCM This PR/Issue is related to XCM.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants