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

FRAME: Revamp Preimage pallet to use Consideration #1363

Merged
merged 55 commits into from Sep 17, 2023

Conversation

gavofyork
Copy link
Member

@gavofyork gavofyork commented Sep 2, 2023

Make Preimage pallet use Consideration instead of handling deposits directly.

Other half of paritytech/substrate#13666.
Depends/based on #1361.

Script for the lazy migration that should be run manually once: migrate-preimage-lazy.py.

TODO

  • Migration code.

@gavofyork gavofyork added the T2-pallets This PR/Issue is related to a particular pallet. label Sep 2, 2023
@gavofyork gavofyork changed the title Frame: Revamp Preimage pallet to use Consideration FRAME: Revamp Preimage pallet to use Consideration Sep 2, 2023
@gavofyork gavofyork marked this pull request as ready for review September 3, 2023 11:14
gavofyork and others added 9 commits September 6, 2023 12:51
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez
Copy link
Member

ggwpez commented Sep 6, 2023

bot bench substrate-pallet --pallet=pallet_preimage

@command-bot
Copy link

command-bot bot commented Sep 6, 2023

@ggwpez https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3593250 was started for your command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=dev --target_dir=substrate --pallet=pallet_preimage. 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 2-0ac52503-4b00-40f4-9768-a8a9466dc8ce to cancel this command or bot cancel to cancel all commands in this pull request.

…=dev --target_dir=substrate --pallet=pallet_preimage
@command-bot
Copy link

command-bot bot commented Sep 6, 2023

@ggwpez Command "$PIPELINE_SCRIPTS_DIR/commands/bench/bench.sh" --subcommand=pallet --runtime=dev --target_dir=substrate --pallet=pallet_preimage has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3593250 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3593250/artifacts/download.

substrate/frame/preimage/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/preimage/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/preimage/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/preimage/src/lib.rs Show resolved Hide resolved
substrate/frame/preimage/src/lib.rs Show resolved Hide resolved
substrate/frame/preimage/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/preimage/src/tests.rs Outdated Show resolved Hide resolved
gavofyork and others added 5 commits September 12, 2023 13:18
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
@gavofyork gavofyork requested a review from a team September 14, 2023 14:55
@paritytech-cicd-pr
Copy link

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-clippy
Logs: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3698484

@gavofyork gavofyork merged commit d787269 into master Sep 17, 2023
107 of 109 checks passed
@gavofyork gavofyork deleted the gav-consideration-preimage branch September 17, 2023 11:19
svyatonik added a commit to svyatonik/runtimes that referenced this pull request Nov 3, 2023
[requires migration. onchain or offchain?]
@xlc xlc mentioned this pull request Nov 15, 2023
3 tasks
bkchr added a commit to polkadot-fellows/runtimes that referenced this pull request Nov 20, 2023
In the PR we bump versions for all dependacy crates from `polkadot-sdk`
and apply all required changes

Changes:
- `parachains_runtime_api_impl` `v5` -> `v7`,
  - from paritytech/polkadot-sdk#1543;
- `Consideration` setup for preimage pallet instances,
  - from  paritytech/polkadot-sdk#1363;
- `experimental` feature removed for `pallet-society`, `pallet-xcm`,
`runtime-common` crates,
  - from paritytech/polkadot-sdk#1503;
- `pallet_election_provider_multi_phase::Config::SignedDepositBase` set
to `GeometricDepositBase`,
  - from paritytech/polkadot-sdk#1547;
- support `open_outbound_hrmp_channel_for_benchmarks_or_tests` func
rename,
  - from paritytech/polkadot-sdk#1422;
- missing weight functions added for `runtime_parachains_hrmp` and
`pallet_preimage`;

TODO:
- [x] Deleted the Copy&paste para scheduler migration from
#26 in
b666613. This should be applied in the
next runtime upgrade, but i did not properly check yet.

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Bastian Köcher <git@kchr.de>
Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com>
@Polkadot-Forum
Copy link

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

https://forum.polkadot.network/t/polkadot-release-analysis-v1-2-0/4451/2

bgallois pushed a commit to duniter/duniter-polkadot-sdk that referenced this pull request Mar 25, 2024
Make Preimage pallet use Consideration instead of handling deposits
directly.

Other half of paritytech/substrate#13666.
Depends/based on paritytech#1361.

Script for the lazy migration that should be run manually once:
[migrate-preimage-lazy.py](https://github.com/ggwpez/substrate-scripts/blob/master/migrate-preimage-lazy.py).

## TODO

- [x] Migration code.

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: command-bot <>
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
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: Done
Status: Audited
Development

Successfully merging this pull request may close these issues.

None yet

5 participants