FAILURE MAP
← Case archive

FA-62097 / Currency rounding and FX conversion / Member archive

Fully offset currencies remain in the settlement instruction list · case 02

A currency that nets to zero still produces a zero payment instruction.

Member previewVariant 2 · 3 implementations · 6 checks per implementation

Case contract

solve(trades): each trade is [pay_ccy, pay_amount, recv_ccy, recv_amount] from our side. Net per currency = received - paid. Return [[ccy, net], ...] sorted by currency code, omitting currencies whose net is exactly zero; nets are plain strings at the currency exponent (JPY 0, KWD 3, else 2).

Why this case matters

Currency amounts must be rounded at the right stage and in the right unit, or ledgers, quotes and settlements drift by minor units.

One recorded failure

Sample boundary fixture

This sample comes from the broken implementation of a controlled reproducer.

Boundary fixtureActualExpectedOutcome
regression zero-net-omission 1[["CHF", "0.88"], ["EUR", "0.92"], ["GBP", "-0.79"], ["KWD", "-0.307"], ["USD", "0.00"]][["CHF", "0.88"], ["EUR", "0.92"], ["GBP", "-0.79"], ["KWD", "-0.307"]]Failed

MEMBER ARCHIVE

The complete case is available to members.

This record includes three runnable implementations, regression fixtures, execution results, and source hashes.

Member access is invitation-based. Sign in with your invited account to inspect the sources.

Sign in to the archive ↗