-
Notifications
You must be signed in to change notification settings - Fork 101
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
[coretime-kusama] Bump broker and add migration to import leases to fix launch issues #276
Merged
fellowship-merge-bot
merged 17 commits into
polkadot-fellows:main
from
seadanda:donal-kusama-leases-fix
Apr 19, 2024
Merged
[coretime-kusama] Bump broker and add migration to import leases to fix launch issues #276
fellowship-merge-bot
merged 17 commits into
polkadot-fellows:main
from
seadanda:donal-kusama-leases-fix
Apr 19, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eskimor
approved these changes
Apr 19, 2024
bkchr
approved these changes
Apr 19, 2024
// Because we also run start_sales, 12 expiring leases are removed from the original 47, | ||
// leaving 35. | ||
let leases = Leases::<Runtime>::get(); | ||
assert_eq!(leases.len(), 35); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested change
assert_eq!(leases.len(), 35); | |
assert_eq!(leases.len(), LEASES.iter().filter(|(_, l)| sale_info.region_length * Timeslice::get() > l).count()); |
This should achieve the same?
Co-authored-by: Bastian Köcher <[email protected]>
bkchr
reviewed
Apr 19, 2024
Co-authored-by: Bastian Köcher <[email protected]>
joepetrowski
approved these changes
Apr 19, 2024
/merge |
Enabled Available commands
For more information see the documentation |
fellowship-merge-bot
bot
merged commit Apr 19, 2024
4211c34
into
polkadot-fellows:main
35 of 36 checks passed
bkchr
added a commit
that referenced
this pull request
Apr 19, 2024
…ix launch issues (#276) For the transition to coretime, the relay runtime upgrade includes a migration which sends a few XCMs to the coretime chain with Transacts. This calls `set_lease` (a broker extrinsic on the coretime chain) for all the leases that are currently in the relay state to get them a lease on the coretime chain. This happened yesterday but the XCM didn't have enough weight and so the leases weren't migrated over. We decided to make a runtime upgrade since there was a bug with the renewals for short leases anyway. This PR solves both issues. The bump to the broker pallet fixes a bug where very short leases (ending in the first 28 days after running start_sales) could not be renewed. This PR includes a migration which does three things: 1. Imports a hardcoded list of leases into the state 2. Adds three cores to ensure there are enough cores for everyone to renew while also leaving the intended 3 for the open market 3. restarts sales The migration also tests the renewal fix with try-runtime. - [ ] Does not require a CHANGELOG entry --------- Co-authored-by: Bastian Köcher <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
For the transition to coretime, the relay runtime upgrade includes a migration which sends a few XCMs to the coretime chain with Transacts. This calls
set_lease
(a broker extrinsic on the coretime chain) for all the leases that are currently in the relay state to get them a lease on the coretime chain.This happened yesterday but the XCM didn't have enough weight and so the leases weren't migrated over. We decided to make a runtime upgrade since there was a bug with the renewals for short leases anyway. This PR solves both issues.
The bump to the broker pallet fixes a bug where very short leases (ending in the first 28 days after running start_sales) could not be renewed.
This PR includes a migration which does three things:
The migration also tests the renewal fix with try-runtime.