Metadata for proposal and referendum
Metadata for proposal/referendum records within the referenda and the democracy pallets.
Goals:
- improve end user experience (clients can load human readable information like a description of a proposal and display it to the end user);
- metadata stored on chain, or its proof.
Implementation:
Proposals and referendums records has optional 1:1 metadata record, which stores the hash of the preimage. The preimage is supposed to be uploaded via any preimage provider (e.x preimage pallet). After the preimage is uploaded a submitter of the proposal/referendum is able to set the metadata (preimage hash).
In the democracy pallet the metadata can be set only for a proposal (public or external). If the proposal evolves to the referendum the metadata is inherited and can be reset or cleared only by root origin (due the absence of the submitter information, and a fit to the overall idea).
The preimage can store a JSON dump with title and description, IPFS hash representing the off-chain file, or any other format a runtime owner picked up.
TODO
- [ ] Companions PRs
/cmd queue -c bench-bot $ pallet dev pallet_democracy /cmd queue -c bench-bot $ pallet dev pallet_referenda
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999235 was started for your command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" pallet dev pallet_democracy. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 5-2dee6a99-a014-4dfd-8827-30966a744f72 to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999236 was started for your command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" pallet dev pallet_referenda. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 6-38d41ce4-534b-4c77-8d23-c2794f9ce26a to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem Command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" pallet dev pallet_democracy has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999235 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999235/artifacts/download.
@muharem Command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" pallet dev pallet_referenda has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999236 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1999236/artifacts/download.
This pull request has been mentioned on Polkadot Forum. There might be relevant details there:
https://forum.polkadot.network/t/a-better-treasury-system/291/16
I have removed preimage::request on set_metadata in the last commit (https://github.com/paritytech/substrate/pull/12568/commits/48ebf6d0fd49483691caaef93e4c57f9df7586a3). This wont let a submitter release its preimage deposit without removing a preimage. Same model used for proposal calls in the referenda and democracy pallets.
/cmd queue -c bench-bot $ pallet dev pallet_referenda
@muharem Could not find matching configuration bench-bot; available ones are bench, fmt, sample, try-runtime.
/cmd queue -c bench $ pallet dev pallet_referenda /cmd queue -c bench $ pallet dev pallet_democracy
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326839 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 58-ff1c8793-e9d7-49eb-bb70-f905295b2397 to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326840 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_democracy. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 59-db3007ac-6163-42d6-b09c-e9d6849ab1f9 to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_democracy has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326840 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326840/artifacts/download.
@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326839 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2326839/artifacts/download.
/cmd queue -c bench $ pallet dev pallet_referenda /cmd queue -c bench $ pallet dev pallet_democracy
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327160 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 60-c7251fb5-7411-4229-a117-b59f4069678c to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327161 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_democracy. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 61-e0f2f6d5-1c43-4c9b-a793-895654574b53 to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_democracy has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327161 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327161/artifacts/download.
@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327160 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327160/artifacts/download.
/cmd queue -c bench $ pallet dev pallet_referenda
@muharem https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327347 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda. Check out https://gitlab.parity.io/parity/mirrors/substrate/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.
Comment /cmd cancel 62-c2c49837-091d-4683-b79e-e839683954f7 to cancel this command or /cmd cancel to cancel all commands in this pull request.
@muharem Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" pallet dev pallet_referenda has finished. Result: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327347 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2327347/artifacts/download.
bot rebase
Rebased
This pull request has been mentioned on Polkadot Forum. There might be relevant details there:
https://forum.polkadot.network/t/polkadot-release-analysis-v0-9-39/2277/1