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

Implement pallet-asset-rewards #3926

Open
wants to merge 190 commits into
base: master
Choose a base branch
from
Open

Conversation

liamaharon
Copy link
Contributor

@liamaharon liamaharon commented Apr 1, 2024

Closes #3149

Description

This PR introduces pallet-asset-rewards, which allows accounts to be rewarded for freezing fungible tokens. The motivation for creating this pallet is to allow incentivising LPs.

See the pallet docs for more info about the pallet.

Runtime changes

The pallet has been added to

  • asset-hub-rococo
  • asset-hub-westend

The NativeAndAssets fungibles Union did not contain PoolAssets, so it has been renamed NativeAndNonPoolAssets

A new fungibles Union NativeAndAllAssets was created to encompass all assets and the native token.

TODO

@liamaharon liamaharon added the T1-FRAME This PR/Issue is related to core FRAME, the framework. label Apr 1, 2024
@liamaharon liamaharon changed the title Implement pallet-staking-rewards Implement pallet-asset-rewards Apr 1, 2024
@muharem
Copy link
Contributor

muharem commented Sep 13, 2024

@gui1117 thank you for review! all comments should addressed now

@muharem
Copy link
Contributor

muharem commented Sep 13, 2024

bot bench cumulus-assets --pallet=pallet_asset_rewards --runtime asset-hub-rococo

@command-bot
Copy link

command-bot bot commented Sep 13, 2024

@muharem https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/7341344 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_asset_rewards. 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 3-55b905f1-0c35-4f82-a9b8-6fb45fd24c7e to cancel this command or bot cancel to cancel all commands in this pull request.

…=asset-hub-rococo --runtime_dir=assets --target_dir=cumulus --pallet=pallet_asset_rewards
@command-bot
Copy link

command-bot bot commented Sep 13, 2024

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

@muharem
Copy link
Contributor

muharem commented Sep 13, 2024

bot bench cumulus-assets --pallet=pallet_asset_rewards --runtime asset-hub-westend

@command-bot
Copy link

command-bot bot commented Sep 13, 2024

@muharem https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/7343877 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_asset_rewards. 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 4-4850da8b-e207-4d45-a1e0-7008cc250baf to cancel this command or bot cancel to cancel all commands in this pull request.

command-bot added 2 commits September 13, 2024 12:58
…=asset-hub-westend --runtime_dir=assets --target_dir=cumulus --pallet=pallet_asset_rewards
@command-bot
Copy link

command-bot bot commented Sep 13, 2024

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

@muharem
Copy link
Contributor

muharem commented Sep 17, 2024

bot bench-all pallet --pallet=pallet_asset_rewards

@command-bot
Copy link

command-bot bot commented Sep 17, 2024

@muharem https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/7360419 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench-all/bench-all.sh" --pallet=pallet_asset_rewards. 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 1-be697617-3dd3-4733-96dd-b6f4b3bbe062 to cancel this command or bot cancel to cancel all commands in this pull request.

Copy link
Contributor

@gui1117 gui1117 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@command-bot
Copy link

command-bot bot commented Sep 17, 2024

@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench-all/bench-all.sh" --pallet=pallet_asset_rewards has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/7360419 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/7360419/artifacts/download.

AssetIdForTrustBackedAssets,
xcm::v4::Location,
>,
xcm::v4::Location,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

xcm::v5::Location everywhere, but when you rebase/merge master, it should be fixed

@paritytech-workflow-stopper
Copy link

All GitHub workflows were cancelled due to failure one of the required jobs.
Failed workflow url: https://github.com/paritytech/polkadot-sdk/actions/runs/12455651075
Failed job name: cargo-clippy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T2-pallets This PR/Issue is related to a particular pallet.
Projects
Status: Audited
Development

Successfully merging this pull request may close these issues.

[Asset Conversion] Incentives Extension
9 participants