Open
Milestone
Description
Context
add_estimation_costs_for_total_system_credits_update_v0 estimates the Misc layer as ApproximateElements(1) with AllItems(1, 8). Misc holds more than that:
- the genesis core height
C; - total system credits
D; - the documents expirations tree
E, from protocol 14; - the total token supplies tree
T, from protocol 9; - from protocol 15, the Core fork activation item
[b'F', 0](feat(drive-abci)!: record Core fork activation in state (PV15) #5681).
The estimate does not decide the fee a user pays. It decides admission: validate_fees_of_event prices address-funded transitions with apply = false, and execute_event charges the actual metered cost. A transition whose address inputs cover the estimate but not the actual cost fails at execution (CorruptedCodeExecution, then dropped from the block as an internal error). That makes the gap between estimate and actual cost a rejection window, not an underpricing. Adding E and T never changed this estimator.
Proposal
- Add an estimator generation, selected by the next unreleased protocol version, whose
Misclayer matches its real element count and sizes. - Test a paid address-funded transition, after the
Miscitems of that protocol version exist, whose inputs cover the estimate exactly.
Raised in the review of #5681: #5681 (comment)
Metadata
Metadata
Assignees
Labels
No labels
Activity