FAILURE MAP
← Case archive

FA-58441 / Loan amortization schedules / Open access

Interest-only period with funding stub: stub day count · case 01

The first interest-only bill misses the funding day.

Verified by executionVariant 1 · 7 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The stub counts 30 - fund_day days, excluding the funding day itself.

THE FAILURE

The stub counts 30 - fund_day days, excluding the funding day itself.

Unsuccessful approach: Counting fund_day days bills the days before funding instead of after.

Case contract

x = {'principal', 'rate_bp', 'io_months' >= 1, 'amort_months' >= 1, 'fund_day' 1..30}. IO month m pays interest round_half_up(P*bp*days/(120000*30)) with days = 31 - fund_day for the first IO month and 30 otherwise. Then the level payment on the full principal over amort_months (exact annuity, half-up) amortizes with monthly interest round_half_up(balance*bp/120000); the last month pays balance + interest. Return {'io_bills': list of IO payments, 'payment', 'final_payment', 'total_interest'}.

Why this case matters

Amortization engines drive borrower statements, payoff quotes and investor remittances; a misplaced rounding step, boundary or ordering rule compounds across hundreds of periods.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
    def rnd(n, d):
        q, r = divmod(n, d)
        return q + (1 if 2 * r >= d else 0)
    def level(P, n):
        if n <= 0 or P <= 0:
            return 0
        if bp == 0:
            exact = Fraction(P, n)
        else:
            r = Fraction(bp, 120000)
            exact = P * r / (1 - (1 + r) ** -n)
        return math.floor(exact + Fraction(1, 2))
    bp = x['rate_bp']
    P = x['principal']
    io_bills = []
    total_int = 0
    for m in range(x['io_months']):
        days = 30 - x['fund_day'] if m == 0 else 30
        interest = rnd(P * bp * days, 120000 * 30)
        io_bills.append(interest)
        total_int += interest
    pay = level(P, x['amort_months'])
    bal = P
    final = 0
    for k in range(1, x['amort_months'] + 1):
        interest = rnd(bal * bp, 120000)
        total_int += interest
        if k == x['amort_months']:
            final = bal + interest
        else:
            bal -= pay - interest
    return {'io_bills': io_bills, 'payment': pay, 'final_payment': final, 'total_interest': total_int}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression: stub day count', {'principal': 3000000, 'rate_bp': 500, 'io_months': 3, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [12500, 12500, 12500], 'payment': 56614, 'final_payment': 56596, 'total_interest': 434322}], ['control 1', {'principal': 12345, 'rate_bp': 0, 'io_months': 1, 'amort_months': 24, 'fund_day': 2}, {'io_bills': [0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 2', {'principal': 12345, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0], 'payment': 12345, 'final_payment': 12345, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}], ['control 4', {'principal': 100000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0, 0], 'payment': 1667, 'final_payment': 1647, 'total_interest': 0}], ['control 5', {'principal': 100000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 12, 'fund_day': 29}, {'io_bills': [0], 'payment': 8333, 'final_payment': 8337, 'total_interest': 0}], ['control 6', {'principal': 100000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 1, 'fund_day': 30}, {'io_bills': [0, 0, 0], 'payment': 100000, 'final_payment': 100000, 'total_interest': 0}]], [['regression: stub day count', {'principal': 100000, 'rate_bp': 725, 'io_months': 2, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [604, 604], 'payment': 1992, 'final_payment': 1987, 'total_interest': 20723}], ['control 1', {'principal': 12345, 'rate_bp': 0, 'io_months': 3, 'amort_months': 12, 'fund_day': 1}, {'io_bills': [0, 0, 0], 'payment': 1029, 'final_payment': 1026, 'total_interest': 0}], ['control 2', {'principal': 3000000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 2}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 50000, 'final_payment': 50000, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 10417, 'final_payment': 10409, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0, 0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 2}, {'io_bills': [0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 12, 'fund_day': 1}, {'io_bills': [0, 0, 0], 'payment': 20833, 'final_payment': 20837, 'total_interest': 0}]], [['regression: stub day count', {'principal': 3000000, 'rate_bp': 500, 'io_months': 2, 'amort_months': 24, 'fund_day': 29}, {'io_bills': [833, 12500], 'payment': 131614, 'final_payment': 131618, 'total_interest': 172073}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 29}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4159, 'total_interest': 0}], ['control 2', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 30}, {'io_bills': [0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 30}, {'io_bills': [0], 'payment': 250000, 'final_payment': 250000, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 29}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 6', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 1}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}]], [['regression: stub day count', {'principal': 250000, 'rate_bp': 500, 'io_months': 12, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [556, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042], 'payment': 4718, 'final_payment': 4703, 'total_interest': 45083}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 29}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 1667, 'final_payment': 1647, 'total_interest': 0}], ['control 2', {'principal': 250000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0, 0, 0], 'payment': 250000, 'final_payment': 250000, 'total_interest': 0}], ['control 3', {'principal': 12345, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 4', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 5', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 29}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 30}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}]], [['regression: stub day count', {'principal': 12345, 'rate_bp': 725, 'io_months': 1, 'amort_months': 12, 'fund_day': 2}, {'io_bills': [72], 'payment': 1070, 'final_payment': 1065, 'total_interest': 562}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 30}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4159, 'total_interest': 0}], ['control 2', {'principal': 3000000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 125000, 'final_payment': 125000, 'total_interest': 0}], ['control 3', {'principal': 12345, 'rate_bp': 0, 'io_months': 3, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 1, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 12, 'fund_day': 30}, {'io_bills': [0, 0], 'payment': 1029, 'final_payment': 1026, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}]]]
for label, args, expected in fixtures[N-1]:
    try:
        actual = solve(args)
    except Exception as exc:
        actual = 'raised ' + type(exc).__name__
    check(label, actual, expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
regression: stub day count{'final_payment': 56596, 'io_bills': [12083, 12500, 12500], 'payment': 56614, 'total_interest': 433905}{'final_payment': 56596, 'io_bills': [12500, 12500, 12500], 'payment': 56614, 'total_interest': 434322}Failed
control 1{'final_payment': 523, 'io_bills': [0], 'payment': 514, 'total_interest': 0}{'final_payment': 523, 'io_bills': [0], 'payment': 514, 'total_interest': 0}Passed
control 2{'final_payment': 12345, 'io_bills': [0], 'payment': 12345, 'total_interest': 0}{'final_payment': 12345, 'io_bills': [0], 'payment': 12345, 'total_interest': 0}Passed
control 3{'final_payment': 4147, 'io_bills': [0, 0], 'payment': 4167, 'total_interest': 0}{'final_payment': 4147, 'io_bills': [0, 0], 'payment': 4167, 'total_interest': 0}Passed
control 4{'final_payment': 1647, 'io_bills': [0, 0, 0], 'payment': 1667, 'total_interest': 0}{'final_payment': 1647, 'io_bills': [0, 0, 0], 'payment': 1667, 'total_interest': 0}Passed
control 5{'final_payment': 8337, 'io_bills': [0], 'payment': 8333, 'total_interest': 0}{'final_payment': 8337, 'io_bills': [0], 'payment': 8333, 'total_interest': 0}Passed
control 6{'final_payment': 100000, 'io_bills': [0, 0, 0], 'payment': 100000, 'total_interest': 0}{'final_payment': 100000, 'io_bills': [0, 0, 0], 'payment': 100000, 'total_interest': 0}Passed

SHA-256 / 0aa4cf1424025b2ea87447995e8d51186aa08cbfd5abbf2d6da94d11c0894441

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
    def rnd(n, d):
        q, r = divmod(n, d)
        return q + (1 if 2 * r >= d else 0)
    def level(P, n):
        if n <= 0 or P <= 0:
            return 0
        if bp == 0:
            exact = Fraction(P, n)
        else:
            r = Fraction(bp, 120000)
            exact = P * r / (1 - (1 + r) ** -n)
        return math.floor(exact + Fraction(1, 2))
    bp = x['rate_bp']
    P = x['principal']
    io_bills = []
    total_int = 0
    for m in range(x['io_months']):
        days = x['fund_day'] if m == 0 else 30
        interest = rnd(P * bp * days, 120000 * 30)
        io_bills.append(interest)
        total_int += interest
    pay = level(P, x['amort_months'])
    bal = P
    final = 0
    for k in range(1, x['amort_months'] + 1):
        interest = rnd(bal * bp, 120000)
        total_int += interest
        if k == x['amort_months']:
            final = bal + interest
        else:
            bal -= pay - interest
    return {'io_bills': io_bills, 'payment': pay, 'final_payment': final, 'total_interest': total_int}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression: stub day count', {'principal': 3000000, 'rate_bp': 500, 'io_months': 3, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [12500, 12500, 12500], 'payment': 56614, 'final_payment': 56596, 'total_interest': 434322}], ['control 1', {'principal': 12345, 'rate_bp': 0, 'io_months': 1, 'amort_months': 24, 'fund_day': 2}, {'io_bills': [0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 2', {'principal': 12345, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0], 'payment': 12345, 'final_payment': 12345, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}], ['control 4', {'principal': 100000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0, 0], 'payment': 1667, 'final_payment': 1647, 'total_interest': 0}], ['control 5', {'principal': 100000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 12, 'fund_day': 29}, {'io_bills': [0], 'payment': 8333, 'final_payment': 8337, 'total_interest': 0}], ['control 6', {'principal': 100000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 1, 'fund_day': 30}, {'io_bills': [0, 0, 0], 'payment': 100000, 'final_payment': 100000, 'total_interest': 0}]], [['regression: stub day count', {'principal': 100000, 'rate_bp': 725, 'io_months': 2, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [604, 604], 'payment': 1992, 'final_payment': 1987, 'total_interest': 20723}], ['control 1', {'principal': 12345, 'rate_bp': 0, 'io_months': 3, 'amort_months': 12, 'fund_day': 1}, {'io_bills': [0, 0, 0], 'payment': 1029, 'final_payment': 1026, 'total_interest': 0}], ['control 2', {'principal': 3000000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 2}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 50000, 'final_payment': 50000, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 10417, 'final_payment': 10409, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0, 0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 2}, {'io_bills': [0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 12, 'fund_day': 1}, {'io_bills': [0, 0, 0], 'payment': 20833, 'final_payment': 20837, 'total_interest': 0}]], [['regression: stub day count', {'principal': 3000000, 'rate_bp': 500, 'io_months': 2, 'amort_months': 24, 'fund_day': 29}, {'io_bills': [833, 12500], 'payment': 131614, 'final_payment': 131618, 'total_interest': 172073}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 29}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4159, 'total_interest': 0}], ['control 2', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 30}, {'io_bills': [0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 3', {'principal': 250000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 30}, {'io_bills': [0], 'payment': 250000, 'final_payment': 250000, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 29}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 6', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 1}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}]], [['regression: stub day count', {'principal': 250000, 'rate_bp': 500, 'io_months': 12, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [556, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042, 1042], 'payment': 4718, 'final_payment': 4703, 'total_interest': 45083}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 29}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 1667, 'final_payment': 1647, 'total_interest': 0}], ['control 2', {'principal': 250000, 'rate_bp': 0, 'io_months': 3, 'amort_months': 1, 'fund_day': 2}, {'io_bills': [0, 0, 0], 'payment': 250000, 'final_payment': 250000, 'total_interest': 0}], ['control 3', {'principal': 12345, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 15}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 206, 'final_payment': 191, 'total_interest': 0}], ['control 4', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 5', {'principal': 3000000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 1, 'fund_day': 29}, {'io_bills': [0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 60, 'fund_day': 30}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}]], [['regression: stub day count', {'principal': 12345, 'rate_bp': 725, 'io_months': 1, 'amort_months': 12, 'fund_day': 2}, {'io_bills': [72], 'payment': 1070, 'final_payment': 1065, 'total_interest': 562}], ['control 1', {'principal': 100000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 30}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 4167, 'final_payment': 4159, 'total_interest': 0}], ['control 2', {'principal': 3000000, 'rate_bp': 0, 'io_months': 12, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], 'payment': 125000, 'final_payment': 125000, 'total_interest': 0}], ['control 3', {'principal': 12345, 'rate_bp': 0, 'io_months': 3, 'amort_months': 24, 'fund_day': 15}, {'io_bills': [0, 0, 0], 'payment': 514, 'final_payment': 523, 'total_interest': 0}], ['control 4', {'principal': 3000000, 'rate_bp': 0, 'io_months': 2, 'amort_months': 1, 'fund_day': 15}, {'io_bills': [0, 0], 'payment': 3000000, 'final_payment': 3000000, 'total_interest': 0}], ['control 5', {'principal': 12345, 'rate_bp': 0, 'io_months': 2, 'amort_months': 12, 'fund_day': 30}, {'io_bills': [0, 0], 'payment': 1029, 'final_payment': 1026, 'total_interest': 0}], ['control 6', {'principal': 250000, 'rate_bp': 0, 'io_months': 1, 'amort_months': 60, 'fund_day': 1}, {'io_bills': [0], 'payment': 4167, 'final_payment': 4147, 'total_interest': 0}]]]
for label, args, expected in fixtures[N-1]:
    try:
        actual = solve(args)
    except Exception as exc:
        actual = 'raised ' + type(exc).__name__
    check(label, actual, expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
regression: stub day count{'final_payment': 56596, 'io_bills': [417, 12500, 12500], 'payment': 56614, 'total_interest': 422239}{'final_payment': 56596, 'io_bills': [12500, 12500, 12500], 'payment': 56614, 'total_interest': 434322}Failed
control 1{'final_payment': 523, 'io_bills': [0], 'payment': 514, 'total_interest': 0}{'final_payment': 523, 'io_bills': [0], 'payment': 514, 'total_interest': 0}Passed
control 2{'final_payment': 12345, 'io_bills': [0], 'payment': 12345, 'total_interest': 0}{'final_payment': 12345, 'io_bills': [0], 'payment': 12345, 'total_interest': 0}Passed
control 3{'final_payment': 4147, 'io_bills': [0, 0], 'payment': 4167, 'total_interest': 0}{'final_payment': 4147, 'io_bills': [0, 0], 'payment': 4167, 'total_interest': 0}Passed
control 4{'final_payment': 1647, 'io_bills': [0, 0, 0], 'payment': 1667, 'total_interest': 0}{'final_payment': 1647, 'io_bills': [0, 0, 0], 'payment': 1667, 'total_interest': 0}Passed
control 5{'final_payment': 8337, 'io_bills': [0], 'payment': 8333, 'total_interest': 0}{'final_payment': 8337, 'io_bills': [0], 'payment': 8333, 'total_interest': 0}Passed
control 6{'final_payment': 100000, 'io_bills': [0, 0, 0], 'payment': 100000, 'total_interest': 0}{'final_payment': 100000, 'io_bills': [0, 0, 0], 'payment': 100000, 'total_interest': 0}Passed

SHA-256 / fafd24f80a11099f3985b37b9e270a2a574372d61c59cca0913e0f5db85b54d1

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 7 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

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

Sign in to the archive ↗

Verification & scope

A deterministic bounded teaching model with stipulated toy lending rules stated in the contract; money is integer cents and rates are basis points; it makes no claim of conformance to any regulation, servicing standard or product. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:46:26.716123+00:00.

Case digest / a625afe4907285826b80d6fbe65bb24a8a17d2bb5ff95068fc749a7fc9a389a5