{"abstract":"Accrued interest near the end of a 184-day period exceeds the half-year coupon.","category":"Bond day-count conventions","checks":8,"contract":"Inputs prev and next coupon dates, settlement in [prev, next) and annual rate (semi-annual coupons). c = 100*rate, days = days(prev, settle). If days >= 183 accrued = c/2 - c*days(settle, next)/365, else accrued = c*days/365. Round to 6 decimals.","contract_signature":"prev, nxt, settle, rate","evaluation_group":"w2-bond_day_count_conventions-canadian-accrued","failed_approach":"Capping forward accrual at half a coupon still differs from the complement rule.","family":"w2-bond_day_count_conventions-canadian-accrued-late-period-complement","id":"FA-61186","implementations":{"attempt":{"sha256":"8c54a214c26911bc7aee912bed4680c7ce406195c358fca4a07bbeac18b16927","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nN = 1\nobservations = []\ndef solve(prev, nxt, settle, rate):\n    P = datetime.date(*prev)\n    Q = datetime.date(*nxt)\n    S = datetime.date(*settle)\n    days = (S - P).days\n    c = 100 * rate\n    if days >= 183:\n        acc = min(c / 2, c * days / 365)\n    else:\n        acc = c * days / 365\n    return round(acc, 6)\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression late-period complement 1', [[2028, 7, 12], [2029, 1, 12], [2029, 1, 11], 0.025], 1.243151], ['regression late-period complement 2', [[2023, 3, 7], [2023, 9, 7], [2023, 9, 6], 0.05], 2.486301], ['partial repair probe 1', [[2022, 5, 13], [2022, 11, 13], [2022, 11, 12], 0.025], 1.243151], ['partial repair probe 2', [[2025, 3, 28], [2025, 9, 28], [2025, 9, 27], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2030, 2, 20], [2030, 8, 20], [2030, 8, 19], 0.05], 2.465753], ['normal control 2', [[2038, 9, 30], [2039, 3, 30], [2039, 3, 29], 0.0825], 4.068493], ['normal control 3', [[2038, 8, 22], [2039, 2, 22], [2039, 2, 20], 0.0125], 0.623288]], [['regression late-period complement 1', [[2025, 3, 25], [2025, 9, 25], [2025, 9, 24], 0.05], 2.486301], ['regression late-period complement 2', [[2020, 3, 14], [2020, 9, 14], [2020, 9, 13], 0.0125], 0.621575], ['partial repair probe 1', [[2031, 5, 8], [2031, 11, 8], [2031, 11, 7], 0.05], 2.486301], ['partial repair probe 2', [[2015, 3, 30], [2015, 9, 30], [2015, 9, 29], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2038, 10, 4], [2039, 4, 4], [2039, 4, 3], 0.0825], 4.091096], ['normal control 2', [[2036, 2, 29], [2036, 8, 29], [2036, 8, 28], 0.05], 2.479452], ['normal control 3', [[2023, 9, 1], [2024, 3, 1], [2024, 2, 29], 0.0125], 0.619863]], [['regression late-period complement 1', [[2021, 7, 8], [2022, 1, 8], [2022, 1, 7], 0.0125], 0.621575], ['regression late-period complement 2', [[2029, 3, 24], [2029, 9, 24], [2029, 9, 23], 0.0125], 0.621575], ['partial repair probe 1', [[2016, 7, 25], [2017, 1, 25], [2017, 1, 24], 0.0125], 0.621575], ['partial repair probe 2', [[2027, 8, 27], [2028, 2, 27], [2028, 2, 26], 0.0375], 1.864726], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2028, 9, 17], [2029, 3, 17], [2029, 3, 16], 0.025], 1.232877], ['normal control 2', [[2026, 4, 16], [2026, 10, 16], [2026, 10, 15], 0.025], 1.246575], ['normal control 3', [[2019, 9, 30], [2020, 3, 30], [2019, 12, 1], 0.0375], 0.636986]], [['regression late-period complement 1', [[2017, 5, 1], [2017, 11, 1], [2017, 10, 31], 0.0125], 0.621575], ['regression late-period complement 2', [[2025, 5, 30], [2025, 11, 30], [2025, 11, 29], 0.0125], 0.621575], ['partial repair probe 1', [[2011, 3, 5], [2011, 9, 5], [2011, 9, 4], 0.0125], 0.621575], ['partial repair probe 2', [[2038, 7, 14], [2039, 1, 14], [2039, 1, 13], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2039, 4, 1], [2039, 10, 1], [2039, 9, 30], 0.05], 2.493151], ['normal control 2', [[2018, 4, 15], [2018, 10, 15], [2018, 10, 14], 0.0375], 1.869863], ['normal control 3', [[2023, 1, 31], [2023, 7, 31], [2023, 7, 29], 0.05], 2.452055]], [['regression late-period complement 1', [[2019, 5, 4], [2019, 11, 4], [2019, 11, 3], 0.0825], 4.102397], ['regression late-period complement 2', [[2028, 7, 19], [2029, 1, 19], [2029, 1, 18], 0.0125], 0.621575], ['partial repair probe 1', [[2025, 7, 30], [2026, 1, 30], [2026, 1, 29], 0.0125], 0.621575], ['partial repair probe 2', [[2021, 7, 13], [2022, 1, 13], [2022, 1, 12], 0.0825], 4.102397], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2021, 11, 24], [2022, 5, 24], [2022, 5, 23], 0.0375], 1.849315], ['normal control 2', [[2038, 2, 28], [2038, 8, 28], [2038, 5, 3], 0.0125], 0.219178], ['normal control 3', [[2017, 10, 22], [2018, 4, 22], [2018, 4, 21], 0.05], 2.479452]]]\nfor label, args, expected in fixtures[N-1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"7ee170f317e475da8402cd9d50061bf62824e0b4fe8fa9abe2a32f57740f2740","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nN = 1\nobservations = []\ndef solve(prev, nxt, settle, rate):\n    P = datetime.date(*prev)\n    Q = datetime.date(*nxt)\n    S = datetime.date(*settle)\n    days = (S - P).days\n    c = 100 * rate\n    if days >= 183:\n        acc = c * days / 365\n    else:\n        acc = c * days / 365\n    return round(acc, 6)\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression late-period complement 1', [[2028, 7, 12], [2029, 1, 12], [2029, 1, 11], 0.025], 1.243151], ['regression late-period complement 2', [[2023, 3, 7], [2023, 9, 7], [2023, 9, 6], 0.05], 2.486301], ['partial repair probe 1', [[2022, 5, 13], [2022, 11, 13], [2022, 11, 12], 0.025], 1.243151], ['partial repair probe 2', [[2025, 3, 28], [2025, 9, 28], [2025, 9, 27], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2030, 2, 20], [2030, 8, 20], [2030, 8, 19], 0.05], 2.465753], ['normal control 2', [[2038, 9, 30], [2039, 3, 30], [2039, 3, 29], 0.0825], 4.068493], ['normal control 3', [[2038, 8, 22], [2039, 2, 22], [2039, 2, 20], 0.0125], 0.623288]], [['regression late-period complement 1', [[2025, 3, 25], [2025, 9, 25], [2025, 9, 24], 0.05], 2.486301], ['regression late-period complement 2', [[2020, 3, 14], [2020, 9, 14], [2020, 9, 13], 0.0125], 0.621575], ['partial repair probe 1', [[2031, 5, 8], [2031, 11, 8], [2031, 11, 7], 0.05], 2.486301], ['partial repair probe 2', [[2015, 3, 30], [2015, 9, 30], [2015, 9, 29], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2038, 10, 4], [2039, 4, 4], [2039, 4, 3], 0.0825], 4.091096], ['normal control 2', [[2036, 2, 29], [2036, 8, 29], [2036, 8, 28], 0.05], 2.479452], ['normal control 3', [[2023, 9, 1], [2024, 3, 1], [2024, 2, 29], 0.0125], 0.619863]], [['regression late-period complement 1', [[2021, 7, 8], [2022, 1, 8], [2022, 1, 7], 0.0125], 0.621575], ['regression late-period complement 2', [[2029, 3, 24], [2029, 9, 24], [2029, 9, 23], 0.0125], 0.621575], ['partial repair probe 1', [[2016, 7, 25], [2017, 1, 25], [2017, 1, 24], 0.0125], 0.621575], ['partial repair probe 2', [[2027, 8, 27], [2028, 2, 27], [2028, 2, 26], 0.0375], 1.864726], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2028, 9, 17], [2029, 3, 17], [2029, 3, 16], 0.025], 1.232877], ['normal control 2', [[2026, 4, 16], [2026, 10, 16], [2026, 10, 15], 0.025], 1.246575], ['normal control 3', [[2019, 9, 30], [2020, 3, 30], [2019, 12, 1], 0.0375], 0.636986]], [['regression late-period complement 1', [[2017, 5, 1], [2017, 11, 1], [2017, 10, 31], 0.0125], 0.621575], ['regression late-period complement 2', [[2025, 5, 30], [2025, 11, 30], [2025, 11, 29], 0.0125], 0.621575], ['partial repair probe 1', [[2011, 3, 5], [2011, 9, 5], [2011, 9, 4], 0.0125], 0.621575], ['partial repair probe 2', [[2038, 7, 14], [2039, 1, 14], [2039, 1, 13], 0.025], 1.243151], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2039, 4, 1], [2039, 10, 1], [2039, 9, 30], 0.05], 2.493151], ['normal control 2', [[2018, 4, 15], [2018, 10, 15], [2018, 10, 14], 0.0375], 1.869863], ['normal control 3', [[2023, 1, 31], [2023, 7, 31], [2023, 7, 29], 0.05], 2.452055]], [['regression late-period complement 1', [[2019, 5, 4], [2019, 11, 4], [2019, 11, 3], 0.0825], 4.102397], ['regression late-period complement 2', [[2028, 7, 19], [2029, 1, 19], [2029, 1, 18], 0.0125], 0.621575], ['partial repair probe 1', [[2025, 7, 30], [2026, 1, 30], [2026, 1, 29], 0.0125], 0.621575], ['partial repair probe 2', [[2021, 7, 13], [2022, 1, 13], [2022, 1, 12], 0.0825], 4.102397], ['boundary control 1', [[2024, 1, 1], [2024, 7, 1], [2024, 1, 1], 0.05], 0.0], ['normal control 1', [[2021, 11, 24], [2022, 5, 24], [2022, 5, 23], 0.0375], 1.849315], ['normal control 2', [[2038, 2, 28], [2038, 8, 28], [2038, 5, 3], 0.0125], 0.219178], ['normal control 3', [[2017, 10, 22], [2018, 4, 22], [2018, 4, 21], 0.05], 2.479452]]]\nfor label, args, expected in fixtures[N-1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"A deterministic toy contract stated explicitly in the contract field; no claim of conformance to any published convention text. 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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w2-bond_day_count_conventions-canadian-accrued-late-period-complement","generated_at":"2026-09-29T14:46:52.814284+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Bond accrual and pricing systems depend on exact day-count arithmetic; a single-day error changes settlement cash.","root_cause":"The late-period formula was written as c*days/365 instead of the complement from the coupon.","sha256":"6d54c158ada38ef5dfdf4cc963d3953c8f0edb7132ca8e1c41681470db141327","title":"Canadian-style semi-annual accrued interest: the late-period branch accrues forward like the early branch · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":42.67,"exit_code":1,"observations":[{"actual":1.25,"check":"regression late-period complement 1","expected":1.243151,"passed":false},{"actual":2.5,"check":"regression late-period complement 2","expected":2.486301,"passed":false},{"actual":1.25,"check":"partial repair probe 1","expected":1.243151,"passed":false},{"actual":1.25,"check":"partial repair probe 2","expected":1.243151,"passed":false},{"actual":0.0,"check":"boundary control 1","expected":0.0,"passed":true},{"actual":2.465753,"check":"normal control 1","expected":2.465753,"passed":true},{"actual":4.068493,"check":"normal control 2","expected":4.068493,"passed":true},{"actual":0.623288,"check":"normal control 3","expected":0.623288,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression late-period complement 1\", \"actual\": 1.25, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"regression late-period complement 2\", \"actual\": 2.5, \"expected\": 2.486301, \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": 1.25, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": 1.25, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"boundary control 1\", \"actual\": 0.0, \"expected\": 0.0, \"passed\": true}, {\"check\": \"normal control 1\", \"actual\": 2.465753, \"expected\": 2.465753, \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": 4.068493, \"expected\": 4.068493, \"passed\": true}, {\"check\": \"normal control 3\", \"actual\": 0.623288, \"expected\": 0.623288, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":43.047,"exit_code":1,"observations":[{"actual":1.253425,"check":"regression late-period complement 1","expected":1.243151,"passed":false},{"actual":2.506849,"check":"regression late-period complement 2","expected":2.486301,"passed":false},{"actual":1.253425,"check":"partial repair probe 1","expected":1.243151,"passed":false},{"actual":1.253425,"check":"partial repair probe 2","expected":1.243151,"passed":false},{"actual":0.0,"check":"boundary control 1","expected":0.0,"passed":true},{"actual":2.465753,"check":"normal control 1","expected":2.465753,"passed":true},{"actual":4.068493,"check":"normal control 2","expected":4.068493,"passed":true},{"actual":0.623288,"check":"normal control 3","expected":0.623288,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression late-period complement 1\", \"actual\": 1.253425, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"regression late-period complement 2\", \"actual\": 2.506849, \"expected\": 2.486301, \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": 1.253425, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": 1.253425, \"expected\": 1.243151, \"passed\": false}, {\"check\": \"boundary control 1\", \"actual\": 0.0, \"expected\": 0.0, \"passed\": true}, {\"check\": \"normal control 1\", \"actual\": 2.465753, \"expected\": 2.465753, \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": 4.068493, \"expected\": 4.068493, \"passed\": true}, {\"check\": \"normal control 3\", \"actual\": 0.623288, \"expected\": 0.623288, \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}