Fix bug, using invalid calculation result on the edge of the term
If it starts consensus at the edge of the term, it uses invalid calculation.
Let it wait for completion of reward calculation.
@@ -742,6 +742,9 @@ func (es *ExtensionStateImpl) OnExecutionEnd(wc state.WorldContext, totalFee *bi
}
}
case term.StartHeight():
+ if err = es.checkCalculationDone(calculator); err != nil {
+ return err
+ }
if err = es.applyCalculationResult(calculator, blockHeight); err != nil {
return err
}
