Skip to content

feat: deterministic split rounding fairness#391

Closed
menawar wants to merge 2 commits intoRemitwise-Org:mainfrom
menawar:feature/remit-split-remainder-fairness
Closed

feat: deterministic split rounding fairness#391
menawar wants to merge 2 commits intoRemitwise-Org:mainfrom
menawar:feature/remit-split-remainder-fairness

Conversation

@menawar
Copy link
Copy Markdown
Contributor

@menawar menawar commented Mar 25, 2026

Summary

  • implement largest-remainder rounding with deterministic tie-break order (spending, savings, bills, insurance) to eliminate drift
  • keep split sum exactly equal to total_amount for all inputs
  • update tests (unit + gas/bench) and refresh snapshots document the new rounding policy

Testing-

cargo test -p remittance_split

Notes- snapshots updated due to rounding policy change

Closes #246

@Baskarayelu
Copy link
Copy Markdown
Contributor

@menawar Please resolve the conflicts

@menawar menawar closed this by deleting the head repository Apr 13, 2026
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.

Improve split rounding fairness with deterministic remainder policy

2 participants