Skip to content

Conversation

@sandtreader
Copy link
Collaborator

One-line deletion! Fixes #299

This is an interesting one - it turns out although there was the mechanism to post stake refunds to the end of epoch, it was never actually actioned until @lowhung rightly added it in 497214e:

             self.pots.deposits -= deposit;
 
+            // Schedule refund
+            self.stake_refunds.push((stake_address.clone(), deposit));
+

So we were previously only debiting the deposits pot, but not actually paying to the reward account - but adding this meant debiting the pot twice, but does pay the reward. So we gained one, lost one. Now we gain both :-)

@sandtreader sandtreader requested a review from lowhung October 27, 2025 17:26
@sandtreader sandtreader merged commit 13438a0 into main Oct 27, 2025
2 checks passed
@sandtreader sandtreader deleted the prc/299-stake-address-deposit-fix branch October 27, 2025 17:42
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.

Fix stake address deposit repayment timing

3 participants