Skip to main content
11 votes
Accepted

Why stakers tend to stake more on DOT than KSM?

Kusama supports 1,000 active validators while Polkadot only supports 300 currently. Kusama has 7,500 nominators. Polkadot has 24,000 nominators. This will naturally lead to more validators being ...
Shawn Tabrizi's user avatar
  • 16.2k
9 votes

Pallets needed for staking

If you want nominated proof of stake (NPoS) for validator staking of a standalone chain then you may extend the substrate-node-template by adding these further pallets from the Substrate repository: ...
Luke Schoen's user avatar
  • 2,346
8 votes
Accepted

For staking pallet, what options do I have for ElectionProvider?

As it stands now, you have two implementations in substrate: pallet-election-provider-multi-phase: This is a generic, asynchronous election pallet that can provide a wide range of elections to the ...
kianenigma's user avatar
  • 2,844
7 votes
Accepted

Customising staker reward payment

The Staking pallet is not currently set up to be configured to behave in this way. Your best bet would be to design your own pallet with this functionality in mind. Furthermore, there is a lot of ...
Shawn Tabrizi's user avatar
  • 16.2k
7 votes

Writing a test to call staking.chill() so as to remove Charlie as a Validator

No, the issue here is not related to invulnerables. Invulnerables are only immune to getting slashed when an offence occurs. Instead, the issue here is probably that you need to wait a full session ...
Shawn Tabrizi's user avatar
  • 16.2k
7 votes
Accepted

Cannot find macro `vec` in this scope when using pallet-staking

Looks like you didn't put pallet-staking/std into the list of enabled features of std of your runtime.
bkchr's user avatar
  • 11.6k
7 votes
Accepted

Why only top 256 nominators are rewarded for an oversubscribed validator on Polkadot?

Two reasons, the former being more important: It somehow encourages decentralization. One very large validator, despite being very profitable, will have a limited capacity for nominators to join and ...
kianenigma's user avatar
  • 2,844
7 votes

How get the starting Time of a an EraIndex?

The important point about the chain state is that it only contains information that is needed for future block execution. It is not a generalized database. Staking is a very good example - since we ...
Jaco's user avatar
  • 5,875
6 votes
Accepted

Staking locking vs reserving

Locks can overlap, while reserved values cannot. This means that if a value is reserved, it cannot be used in other operations that would also reserve. Consider somebody who both stakes and ...
Werner S's user avatar
  • 639
6 votes

How are rewards in DOT calculated from the era points earned by validators in Polkadot?

Indeed, the exact DOT value of each era point is not known in advance since it depends on the total number of points earned by all validators in a given era. This is designed this way so that the ...
Iker's user avatar
  • 1,426
5 votes
Accepted

How can I fetch the bagsList?

After some more research I found that BagsList is not sorted because it is a Map not an array! If someone wants to find if its address is included in the current round/era of staking: const ...
Kami's user avatar
  • 537
5 votes

How to programmatically get current unbonding information on the Polkadot relay chain?

Here's an example of how I managed to get this information using the @polkadot JavaScript libraries. Import the Polkadot JS libraries yarn add @polkadot/api @polkadot/util var { ApiPromise, ...
Rtsne42's user avatar
  • 379
5 votes
Accepted

Is it possible to specify minimum tokens for staking elections?

The pallet itself provides for this, and there is (at the time of writing) a proposal to do just what you are after on Polkadot: https://polkadot.polkassembly.io/post/905 Here is the type described: ...
Nuke's user avatar
  • 1,842
5 votes
Accepted

In polkadot staking what's the difference between Validators and Para Validators?

Validators are selected and assigned to parachains by the randomized Validator Assignment routine on-chain. Let's look at this snapshot of parachain validation on https://polkadot.js.org/apps/#/...
DrW3RK's user avatar
  • 981
5 votes
Accepted

How to determine value for param num_slashing_spans for a withdrawUnbonded tx?

When an account withdraws unbonded, there is a chance that it will no longer be a stash account at all (i.e., if it has unbonded its entire stake). When a validator gets slashed, it and its nominators ...
joepetrowski's user avatar
  • 2,975
4 votes

What are these items in ElectionProviderMultiPhase?

tl;dr The Config types in your question are configuration parameters for the deposit of submitting a signed solution and reward for a signed solution accepted at the end of the signed phase. Context ...
zekemostov's user avatar
4 votes
Accepted

Constant `MaxNominations` is removed from the Kusama runtime starting from 9170

Unfortunately this was removed accidentally in https://github.com/paritytech/substrate/pull/10601. This PR will bring it back, thanks for reporting this.
kianenigma's user avatar
  • 2,844
4 votes

Runtime panic when peering with node:

The issue might be that initial_authorities accounts don't have any funds, and therefore they don't exist. The error you see comes from the staking module, presumably because it didn't get any valid ...
André's user avatar
  • 2,465
4 votes

For staking pallet, what options do I have for ElectionProvider?

Also, please note, that if you use the latest version of substrate, there are 2 newly introduced structs onchain::BoundedExecution , and onchain::UnboundedExecution. As its name implies, ...
Georges's user avatar
  • 41
4 votes
Accepted

How do the Staking Rewards payouts work?

So, validators are paid proportionally to the amount of era points they have collected. Payments occur at the end of every era. end_era triggers the payout for the finished era. do_payout_stakers ...
Alejandro Martínez's user avatar
4 votes
Accepted

Is it possible to disable new validators from joining?

You could apply a filter to your runtime which would block users from making a call to the validate function. /// Use this filter to block users from calling `validate` in the Staking pallet. pub ...
Shawn Tabrizi's user avatar
  • 16.2k
4 votes
Accepted

Are validators elected at the end of each Era or Epoch?

Assuming you are using BABE/Aura and GRANDPA, epoch and era are completely separate conceptual entities. Epochs belong to BABE/Aura and are the chunks of time containing authoring slots. Sessions and ...
joepetrowski's user avatar
  • 2,975
4 votes
Accepted

Possible to claim Payouts for very old Era?

correct, when new era triggered the underlying storage like ErasStakers* and ErasValidator* will be removed and unclaimable. Staking reward is usually a model of inflation(mint/deposit) so no transfer/...
Ron's user avatar
  • 608
4 votes

How to recover to normal election from `staking.StakingElectionFailed` with `Fallback = BoundedExecution`?

For anyone who may encounter this problem here is the solution and also the explanation. Explanation You may encounter this problem when update older substrate version to the newer one. In my case, it ...
Daniel Lam's user avatar
4 votes

What is the difference between currentEra and activeEra

ActiveEra is the era that we are on. CurrentEra is the era that staking is on. For example, if the election failed. ActiveEra will still be increased, but the CurrentEra not. And one day you found ...
AurevoirXavier's user avatar
  • 10.8k
4 votes
Accepted

Substrate change node template from PoA to PoS

The following posts may help: How to upgrade consensus engine of a live chain from PoA to PoS? How to change consensus engine from PoA to PoS? Also, you may want to consider the parachain route: ...
Bruno's user avatar
  • 8,335
4 votes

Why unbonding period of polkdot is 28 era(28 days) and why not 27 eras or some other number?

The unbonding period has to be longer than or equal to the grace period of slashes. Otherwise the nominator would be able to send their DOTs out and avoid them being slashed. I believe that the 28 ...
Iker's user avatar
  • 1,426
3 votes

How do I check the status of nominations for a staking account?

Nominators active in a specific era - const VALIDATOR = "1..." const NOMINATORS = ["1...", "1..."] const opt_era_info = await api.query.staking.activeEra() const ...
Xiu Hung's user avatar
  • 527
3 votes

Using unspent funds from Treasury as staking rewards

You can reimplement OnUnbalanced, draining the treasury account as long as it contains funds, and otherwise minting. However the overall proposal contains some contention: spending (using the normal ...
Gav's user avatar
  • 2,681
3 votes
Accepted

The purpose of epochs in staking

In a proof-of-stake protocol there are usually two distinct categories of systems for determining the eligibility of a given validator to issue a block: Computed publicly by performing some ...
André's user avatar
  • 2,465

Only top scored, non community-wiki answers of a minimum length are eligible