Call SingleBlockMigrations from frame_system::Config on try_on_runtime_upgrade#9451
Conversation
bkchr
left a comment
There was a problem hiding this comment.
Besides a missing test it looks good 👍
|
I hope we can still backport stuff into unstable2507 since the runtimes will directly go to that. |
|
I think all CI checks related to this PR are now passing |
bkchr
left a comment
There was a problem hiding this comment.
Sorry for the delay. (holidays)
I'm not happy with the current test, please fix it and then we can merge this.
The fixed method is inside |
|
Also important to note that this is a bug. |
…e_upgrade (#9451) Recently, when moving the single block migrations from `frame_executive::Executive` to `SingleBlockMigrations` in `frame_system::Config`, I noticed that `try_runtime_upgrade` was ignoring the `SingleBlockMigrations` defined in frame_system. More context at polkadot-fellows/runtimes#844 Based on PR #1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but from what I understood is or will be deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). ## Follow-up Changes Will try to open a pull request tomorrow for deprecating the use of `OnRuntimeUpgrade` in `frame_executive::Executive`. (cherry picked from commit 7753112)
|
Successfully created backport PR for |
|
Successfully created backport PR for |
…e_upgrade (#9451) Recently, when moving the single block migrations from `frame_executive::Executive` to `SingleBlockMigrations` in `frame_system::Config`, I noticed that `try_runtime_upgrade` was ignoring the `SingleBlockMigrations` defined in frame_system. More context at polkadot-fellows/runtimes#844 Based on PR #1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but from what I understood is or will be deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). ## Follow-up Changes Will try to open a pull request tomorrow for deprecating the use of `OnRuntimeUpgrade` in `frame_executive::Executive`. (cherry picked from commit 7753112)
Backport #9451 into `stable2506` from RomarQ. See the [documentation](https://github.com/paritytech/polkadot-sdk/blob/master/docs/BACKPORT.md) on how to use this bot. <!-- # To be used by other automation, do not modify: original-pr-number: #${pull_number} --> Co-authored-by: Rodrigo Quelhas <22591718+RomarQ@users.noreply.github.com>
Backport #9451 into `unstable2507` from RomarQ. See the [documentation](https://github.com/paritytech/polkadot-sdk/blob/master/docs/BACKPORT.md) on how to use this bot. <!-- # To be used by other automation, do not modify: original-pr-number: #${pull_number} --> Co-authored-by: Rodrigo Quelhas <22591718+RomarQ@users.noreply.github.com>
#9638) Follow-up of #9451 Based on PR #1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but is deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). `Executive` docs will look like: <img width="800" alt="image" src="https://github.com/user-attachments/assets/6f285c26-5c61-4350-a41b-aebc6b856601" /> Companion PR in polkadot-fellows/runtimes#844
…nfig (#844) **Depends on** paritytech/polkadot-sdk#9451 --- Based on PR paritytech/polkadot-sdk#1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but from what I understood is or will be deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). Will also open a PR on polkadot-sdk side, adding a deprecation warning.
…e_upgrade (#9451) Recently, when moving the single block migrations from `frame_executive::Executive` to `SingleBlockMigrations` in `frame_system::Config`, I noticed that `try_runtime_upgrade` was ignoring the `SingleBlockMigrations` defined in frame_system. More context at polkadot-fellows/runtimes#844 Based on PR #1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but from what I understood is or will be deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). ## Follow-up Changes Will try to open a pull request tomorrow for deprecating the use of `OnRuntimeUpgrade` in `frame_executive::Executive`.
#9638) Follow-up of #9451 Based on PR #1781 and [PRDoc](https://github.com/paritytech/polkadot-sdk/blob/beb9030b249cc078b3955232074a8495e7e0302a/prdoc/1.9.0/pr_1781.prdoc#L29), the new way for providing the single block migrations should be through `SingleBlockMigrations` in `frame_system::Config`. Providing them from `frame_executive::Executive` is still supported, but is deprecated. > `SingleBlockMigrations` this is the new way of configuring migrations that run in a single block. Previously they were defined as last generic argument of Executive. This shift is brings all central configuration about migrations closer into view of the developer (migrations that are configured in Executive will still work for now but is deprecated). `Executive` docs will look like: <img width="800" alt="image" src="https://github.com/user-attachments/assets/6f285c26-5c61-4350-a41b-aebc6b856601" /> Companion PR in polkadot-fellows/runtimes#844
Recently, when moving the single block migrations from
frame_executive::ExecutivetoSingleBlockMigrationsinframe_system::Config, I noticed thattry_runtime_upgradewas ignoring theSingleBlockMigrationsdefined in frame_system. More context at polkadot-fellows/runtimes#844Based on PR #1781 and PRDoc, the new way for providing the single block migrations should be through
SingleBlockMigrationsinframe_system::Config. Providing them fromframe_executive::Executiveis still supported, but from what I understood is or will be deprecated.Follow-up Changes
Will try to open a pull request tomorrow for deprecating the use of
OnRuntimeUpgradeinframe_executive::Executive.