Replies: 1 comment 1 reply
-
Hi @SureEdding , Thank you for your questions and sorry for the delayed reply. The only reward mechanism Polygon Edge has, which works for both PoA and PoS, is implemented in the executor.go file (from the State folder). The proposer is going to get the coinbase fee. The implementation is: polygon-edge/state/executor.go Lines 486 to 488 in d3d4f8a Regarding your second question, that function is part of a hook that is only called when switching from PoA to PoS: |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Ask some details about Edge implementation
Description
We want to use Edge to make our own chain, PoS, and can customize our own Tokenomics. during this process, I found some doubts and would like to ask questions here to get answers.
Q1. i don't find how Edge reward proposer (maybe not) in PoS, am I missed something?
Q2. Edge would
preDeploy
staking contract every time it builds block (if there is exist staking contract at that address, how would re-deploying effect state of blockchain?If we have already deployed the staking contract, why do we need to deploy it again during each PreStateCommit? What state changes will this cause?
Q3.
AddSealingReward
is not called anywhere, how edge reward proposer?I looked at the implementation and logic in `ibft.go` and `pos.go` and didn't find any place to redirect block proposer, and found `AddSealingReward` in the whole repository, but it was only called in the test cases. Is it possible that the current PoS implementation does not reward miners? If we want to customize our own PoS reward mechanism, where do we suggest to start?
Any replies and suggestions from the developers would be greatly appreciated.
Beta Was this translation helpful? Give feedback.
All reactions