FAILURE MAP
← Case archive

FA-58062 / Double-entry ledger accounting / Member archive

Account running balance report: credit-normal sign map · case 02

A liability ledger shows credits as decreases in the running balance.

Member previewVariant 2 · 3 implementations · 7 checks per implementation

Case contract

x = {'normal': 'D'|'C', 'opening': balance before all lines, 'lines': [[seq, day, side, amount]], 'from': day, 'to': day}. Balances are signed positive on the normal side. The report opening is the opening plus every line dated before 'from'. Lines dated from..to inclusive are listed in (day, seq) order with the running balance after each; closing is the last running balance (the report opening if none). Return {'opening', 'rows': [[seq, day, running]], 'closing'}.

Why this case matters

Ledger software must keep debits equal to credits and apply normal-balance, period and cutoff rules exactly; small sign or boundary slips silently misstate financial statements.

One recorded failure

Sample boundary fixture

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

Boundary fixtureActualExpectedOutcome
regression: credit-normal sign map{"closing": 210, "opening": 250, "rows": [[5, 5, 260], [4, 8, 210]]}{"closing": 290, "opening": 250, "rows": [[5, 5, 240], [4, 8, 290]]}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 ↗