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

remove parameters; clean inflation related code in polkadot runtime #497

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kianenigma
Copy link
Contributor

output of the test:

Oct 30 12:37:54.179  INFO runtime::polkadot: total-staked = 848019558.366 DOT (8,480,195,583,663,520,091)    
Oct 30 12:37:54.179  INFO runtime::polkadot: total-issuance = 1512066550.617 DOT (15,120,665,506,175,654,580)    
Oct 30 12:37:54.179  INFO runtime::polkadot: staking-rate = 56.0834811152987811%    
Oct 30 12:37:54.179  INFO runtime::polkadot: era-duration = 86400000    
Oct 30 12:37:54.179  INFO runtime::polkadot: maxStakingRewards = None    
Oct 30 12:37:54.179  INFO runtime::polkadot: 💰 Inflation ==> staking = 279477.810 DOT (2,794,778,104,198,508) / leftover = 49319.613 DOT (493,196,136,035,030)    
Oct 30 12:37:54.179  INFO runtime::polkadot: inflation_rate runtime API: InflationInfo { inflation: 7.9368900607918775%, next_mint: (2794778104198508, 493196136035030) }    

// reverse-engineer the current inflation by looking at the total minted against the total
// issuance.
let inflation =
Perquintill::from_rational((next_mint.0 + next_mint.1) * 365, stake_able_issuance);
Copy link
Member

Choose a reason for hiding this comment

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

The era_payout code uses 365.25 (*36525 / 100) normally for a year.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants