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

Feat/runtime 1302 release prep #1432

Merged
merged 10 commits into from
Mar 5, 2025
Merged

Conversation

ipapandinas
Copy link
Contributor

  • Removes old migrations and helpers, and cleanup storage value migration for pallet dAppStaking.
  • Prepares for the runtime-1302 release for Shiden.

@ipapandinas ipapandinas added shiden related to shiden runtime runtime This PR/Issue is related to the topic “runtime”. labels Mar 4, 2025
@ipapandinas ipapandinas requested a review from Dinonard March 4, 2025 14:25
Copy link
Member

@Dinonard Dinonard left a comment

Choose a reason for hiding this comment

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

LGTM

What I'd suggest to do as an extra check - after mimicking runtime upgrade via chopsticks, you can force trigger a new era, and check that new tier config was correctly calculated from the tier parameters.

The way to do this is to first disable the safeguard.
Executing this call should do it:
0x63000a040480802ef6eba87d4e0518600ef1e62725100b7b5a91cad652ab8b6acdaa827d15e10400

Then it's just a matter of calling dappStaking->force to trigger a new era.

Copy link

github-actions bot commented Mar 5, 2025

Code Coverage

Package Line Rate Branch Rate Health
precompiles/assets-erc20/src 78% 0%
pallets/ethereum-checked/src 76% 0%
precompiles/dispatch-lockdrop/src 83% 0%
pallets/xc-asset-config/src 48% 0%
primitives/src 54% 0%
pallets/dapp-staking/src/test 0% 0%
precompiles/dapp-staking/src/test 0% 0%
pallets/astar-xcm-benchmarks/src 86% 0%
chain-extensions/pallet-assets/src 54% 0%
primitives/src/xcm 62% 0%
pallets/dynamic-evm-base-fee/src 82% 0%
chain-extensions/types/assets/src 0% 0%
chain-extensions/types/unified-accounts/src 0% 0%
pallets/dapp-staking/src/benchmarking 95% 0%
precompiles/sr25519/src 56% 0%
pallets/astar-xcm-benchmarks/src/generic 100% 0%
pallets/static-price-provider/src 91% 0%
chain-extensions/unified-accounts/src 0% 0%
pallets/dapp-staking/src 84% 0%
pallets/inflation/src 90% 0%
pallets/collective-proxy/src 94% 0%
pallets/unified-accounts/src 81% 0%
precompiles/dapp-staking/src 89% 0%
pallets/collator-selection/src 86% 0%
precompiles/substrate-ecdsa/src 67% 0%
pallets/price-aggregator/src 75% 0%
pallets/astar-xcm-benchmarks/src/fungible 100% 0%
pallets/vesting-mbm/src 87% 0%
precompiles/unified-accounts/src 100% 0%
pallets/dapp-staking/rpc/runtime-api/src 0% 0%
precompiles/xcm/src 69% 0%
Summary 78% (3639 / 4682) 0% (0 / 0)

Minimum allowed line rate is 50%

Copy link
Contributor

@ermalkaleci ermalkaleci left a comment

Choose a reason for hiding this comment

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

LGTM

@ipapandinas
Copy link
Contributor Author

@Dinonard - I tested your suggestion with TierSlotsArgs = (50,40), and the number of slots value is correctly recalculated to 44 (0.08 * 50 + 40) when I force-triggered a new era.

@ipapandinas ipapandinas merged commit 4edc57e into master Mar 5, 2025
8 checks passed
@ipapandinas ipapandinas deleted the feat/runtime-1302-release-prep branch March 5, 2025 15:17
@Dinonard
Copy link
Member

Dinonard commented Mar 5, 2025

@Dinonard - I tested your suggestion with TierSlotsArgs = (50,40), and the number of slots value is correctly recalculated to 44 (0.08 * 50 + 40) when I force-triggered a new era.

Great!

But one more check you mention (50, 40), but it should be pub const TierSlotsArgs: (u64, u64) = (100, 50);?

I've checked Shiden now, and there are 85 slots?

@ipapandinas
Copy link
Contributor Author

But one more check you mention (50, 40), but it should be pub const TierSlotsArgs: (u64, u64) = (100, 50);?

(50, 40) was an example of value I used locally with Chopsticks; we are using (100, 50) in the Shiden runtime.

I've checked Shiden now, and there are 85 slots?

I am calculating 58 slots on Shiden now by summing slotsPerTier values in tierConfig. Given a token average price of 0.08 SDN from the circular buffer and using our linear formula this works: 0.08 * 100 + 50 = 58

@Dinonard
Copy link
Member

Dinonard commented Mar 5, 2025

But one more check you mention (50, 40), but it should be pub const TierSlotsArgs: (u64, u64) = (100, 50);?

(50, 40) was an example of value I used locally with Chopsticks; we are using (100, 50) in the Shiden runtime.

I've checked Shiden now, and there are 85 slots?

I am calculating 58 slots on Shiden now by summing slotsPerTier values in tierConfig. Given a token average price of 0.08 SDN from the circular buffer and using our linear formula this works: 0.08 * 100 + 50 = 58

Oh that's right, all good then! ✅

Let's upgrade tomorrow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
runtime This PR/Issue is related to the topic “runtime”. shiden related to shiden runtime
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants