feat(parser): warn when receipt totals do not reconcile #95
Labels
No labels
area:backend
area:frontend
area:infra
area:ocr
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
phase:M1
phase:M2
phase:M3
phase:M4
phase:M5
phase:M6
phase:M7
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
TJC/bill-splitter#95
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent: #77 (Phase B, capability). Invariants live in the epic.
Flag receipts whose parts do not add up to the printed total.
Anchors
ReceiptParser.cs:211-new Bill(tax, tip, service, total?.Amount ?? 0);the parsed pieces to reconcile.
ReceiptParser.cs:82.backend/src/BillSplitter.Domain/Bill.cs- field names.Steps
Parsing/Validation: comparesum(items) + tax + tip + serviceagainst the printed grand total within atolerance.
Warningsentry the host sees at review. No DTO/Redischange.
Done
expected.jsononly if a receiptlegitimately does not reconcile, with justification in the PR.
Not planning this: the reconcile signal is already covered.
SplitCalculatorowns the items-vs-total checksum (bill.checksumMinor) andChecksumBannershows it on the review screen, formatted and live. A parser-level warning would be a duplicate of that math (which CLAUDE.md keeps solely inSplitCalculator). See #108 for the details.