An Australian receipt, stored as Thai baht
A receipt scanner has an obvious job — read the total — and a second one nobody thinks about: work out what currency that total is in. Get the first wrong and the user sees it immediately. Get the second wrong and nothing looks broken at all. The number on screen is exactly the number on the paper. It is simply filed as the wrong kind of money, and it quietly poisons a budget.
Over two days I found five of these. Every one had the same cause, and I had not noticed the pattern until they were lined up next to each other.
1. A terminal ID
A Japanese convenience-store receipt came back as Canadian dollars. The receipt prints 小計 ¥380, 税 ¥38, 合計 ¥418 — yen symbols three times. It also prints this:
端末番号:1CAD
That is a terminal number. The scanner looked for ISO currency codes, found CAD inside 1CAD, and returned Canadian dollars before it ever looked at the ¥ symbols. The check excluded a preceding letter, but not a preceding digit.
2. ALDI's tax column
Two receipts from Australia — one from a restaurant in Double Bay, Sydney, one from ALDI in Carindale — were stored as Thai baht. Roughly twenty-three times wrong.
The Sydney one contains the line ฿ $10.00. The ฿ is not a currency. It is what optical character recognition produces when it misreads a letter. The real amount is sitting right beside it, in dollars.
The ALDI one is better. Its line reads:
1.39 ฿
On an Australian ALDI receipt, a B in that column means the item is GST-free. The scanner read the B as ฿ and concluded the receipt was Thai.
Both receipts say TAX INVOICE. One prints an ABN. One prints an NSW postcode. The country-evidence score was 10 to 1 for Australia — and it lost to a single mis-shaped character.
3. A word on a menu
Then it got sillier. The scanner treats a printed ISO code as strong evidence, which is sensible for Total EUR 12.50. But seven of those codes are also ordinary English words:
TRY OUR NEW MENU→ Turkish liraPLEASE TRY AGAIN→ Turkish lira, on a declined-card slipMOP AND BUCKET SET→ Macanese patacaAED PADS REPLACEMENT→ UAE dirham, on a defibrillatorRM 214→ Malaysian ringgit, on a room numberFr. 12 Sept→ Swiss franc, on the German for Friday
No OCR error is needed for any of these. The receipt simply prints normal English. And several — AED, INR, CHF — are medical abbreviations, on an app that reads pharmacy receipts.
4. Absence mistaken for evidence
Hong Kong receipts print a bare $ with no country marker, so most were being stored in whatever currency the user's phone was set to. The obvious fix looked clean: Traditional Chinese script, plus a $, and no Taiwanese marker, must mean Hong Kong. It matched 9 of 10 Hong Kong receipts and none of the 454 receipts from anywhere else.
Then a real Taiwanese receipt arrived. 台灣大哥大, a telecom bill, printing:
實繳金額 $ 665
Traditional Chinese, a bare dollar sign, no NT$, no 元, no 統一發票. Exactly the shape the rule called Hong Kong. Two real receipts were enough to kill it.
5. What actually worked
The fix for Taiwan was the opposite move. Every Taiwanese business receipt prints 統編 — the company's tax ID. It appears on 43 of 43 Taiwanese receipts in our test set, and on zero of the other 430. That is positive evidence, and it shipped the same day.
The pattern
All five are the same bug: a single spurious token outranking accumulated evidence. A terminal ID beat three yen symbols. One misread character beat an ABN and a postcode. The word "try" beat everything.
The rules that survive contact with real paper are the ones built on evidence being present, never on it being absent. 統編 shipped. "No Taiwanese markers, therefore Hong Kong" did not.
Why the tests could not find them
None of this came from the test suite. The 431 receipts we check on every release happen not to contain the word TRY in capitals, and the two Australian receipts were filed under the United States in a public dataset, so nobody had ever looked at them as Australian.
They came from lining the bugs up and asking what shape they had. The corpus then proved the fixes safe: every change was measured across all 431 receipts before shipping, and the word fix changed exactly zero of them while removing six failure modes.
That is the honest division of labour. A test suite tells you whether a change is safe. It does not tell you what is wrong. For that, you still have to look at the receipts.
ReceiptIQ is checked against 431 receipts from ten countries before every release — 391 photographs of real receipts, plus 40 synthetic Taiwanese e-invoices. The fixes above went out the same week they were found.