Track lifetime settled amounts per agent#144
Open
jamilahmadzai wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
settleandsettle_allto add positive billed stroops with saturating arithmetic.Closes #82
Bounty: GrantFox OSS campaign for issue #82
Security notes
saturating_addto clamp ati128::MAXinstead of overflowing.settledevent payload is unchanged.settle_allis included so batch drains cannot undercount lifetime settled value compared with single-servicesettle.0for fresh agents/deployments.Validation
cargo fmt --all -- --checkcargo buildcargo test -p escrow total_settled -- --nocapture(5 passed)clippystep with the same existingescrowtest-module warnings present onmain(262c66b, latest main CI run28393140941also failed withcould not compile escrow (lib test) due to 155 previous errors).cargo testcurrently fails on existing baseline failures reproducible from cleanmain, including the owner-scoped settlement expectation tests and event-count tests unrelated to this change.