{"abstract":"The two returned values disagree whenever a leap day falls inside the span.","category":"Bond day-count conventions","checks":8,"contract":"Inputs start and end [y,m,d]. If end < start return \"end before start\". Days are actual days minus the number of 29 February dates lying in (start, end]. Return [days, days/365 rounded to 9 decimals].","evaluation_group":"w2-bond_day_count_conventions-no-leap-365","failed_approach":"Dividing actual days by 366 when a leap day is present only approximates the no-leap count.","family":"w2-bond_day_count_conventions-no-leap-365-fraction-numerator","id":"FA-61046","implementations":{"attempt":{"sha256":"078e7ff6bdabd8f83c50b88554a2f6e4509795d69288fcfa541778e9e6aeb0b4","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(a, b):\n    A = datetime.date(*a)\n    B = datetime.date(*b)\n    if B < A:\n        return 'end before start'\n    def leap(y):\n        return (y % 4 == 0 and y % 100 != 0) or y % 400 == 0\n    leapdays = sum(1 for y in range(A.year, B.year + 1) if leap(y) and A < datetime.date(y, 2, 29) <= B)\n    days = (B - A).days - leapdays\n    return [days, round((B - A).days / (366 if leapdays else 365), 9)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression fraction numerator 1', [[2104, 2, 28], [2112, 1, 7]], [2868, 7.857534247]], ['regression fraction numerator 2', [[1986, 2, 27], [1991, 10, 9]], [2049, 5.61369863]], ['partial repair probe 1', [[2104, 1, 1], [2113, 1, 13]], [3297, 9.032876712]], ['partial repair probe 2', [[2034, 2, 27], [2038, 8, 21]], [1635, 4.479452055]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[1896, 3, 15], [1899, 8, 25]], [1258, 3.446575342]], ['normal control 2', [[2068, 5, 7], [2069, 2, 20]], [289, 0.791780822]]], [['regression fraction numerator 1', [[2090, 11, 1], [2098, 8, 15]], [2842, 7.78630137]], ['regression fraction numerator 2', [[2005, 6, 30], [2008, 3, 20]], [993, 2.720547945]], ['partial repair probe 1', [[2024, 2, 15], [2029, 8, 29]], [2020, 5.534246575]], ['partial repair probe 2', [[2017, 4, 30], [2021, 2, 26]], [1397, 3.82739726]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[2067, 1, 24], [2067, 6, 15]], [142, 0.389041096]], ['normal control 2', [[2052, 10, 31], [2053, 1, 24]], [85, 0.232876712]]], [['regression fraction numerator 1', [[2023, 8, 22], [2030, 1, 9]], [2330, 6.383561644]], ['regression fraction numerator 2', [[2011, 4, 28], [2012, 4, 29]], [366, 1.002739726]], ['partial repair probe 1', [[1983, 3, 17], [1986, 3, 10]], [1088, 2.980821918]], ['partial repair probe 2', [[2096, 2, 15], [2101, 4, 10]], [1879, 5.147945205]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['normal control 1', [[1919, 5, 31], [1920, 2, 5]], [250, 0.684931507]], ['normal control 2', [[1942, 5, 31], [1943, 7, 20]], [415, 1.136986301]]], [['regression fraction numerator 1', [[2046, 10, 17], [2049, 8, 5]], [1022, 2.8]], ['regression fraction numerator 2', [[2104, 2, 28], [2105, 9, 1]], [550, 1.506849315]], ['partial repair probe 1', [[2103, 7, 31], [2110, 7, 22]], [2546, 6.975342466]], ['partial repair probe 2', [[1976, 4, 30], [1982, 8, 31]], [2313, 6.336986301]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[1904, 3, 1], [1904, 6, 24]], [115, 0.315068493]], ['normal control 2', [[2027, 7, 31], [2027, 11, 6]], [98, 0.268493151]]], [['regression fraction numerator 1', [[1988, 9, 2], [1994, 12, 11]], [2290, 6.273972603]], ['regression fraction numerator 2', [[1996, 3, 15], [2001, 1, 23]], [1774, 4.860273973]], ['partial repair probe 1', [[1941, 8, 31], [1952, 3, 31]], [3862, 10.580821918]], ['partial repair probe 2', [[1932, 4, 20], [1938, 5, 16]], [2216, 6.071232877]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[2104, 3, 15], [2104, 10, 30]], [229, 0.62739726]], ['normal control 2', [[1909, 8, 31], [1909, 11, 13]], [74, 0.202739726]]]]\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":"774128822c6b9966d8403348036444c44ee7e37ca6c4224967df455ef7b15778","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(a, b):\n    A = datetime.date(*a)\n    B = datetime.date(*b)\n    if B < A:\n        return 'end before start'\n    def leap(y):\n        return (y % 4 == 0 and y % 100 != 0) or y % 400 == 0\n    leapdays = sum(1 for y in range(A.year, B.year + 1) if leap(y) and A < datetime.date(y, 2, 29) <= B)\n    days = (B - A).days - leapdays\n    return [days, round((B - A).days / 365, 9)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression fraction numerator 1', [[2104, 2, 28], [2112, 1, 7]], [2868, 7.857534247]], ['regression fraction numerator 2', [[1986, 2, 27], [1991, 10, 9]], [2049, 5.61369863]], ['partial repair probe 1', [[2104, 1, 1], [2113, 1, 13]], [3297, 9.032876712]], ['partial repair probe 2', [[2034, 2, 27], [2038, 8, 21]], [1635, 4.479452055]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[1896, 3, 15], [1899, 8, 25]], [1258, 3.446575342]], ['normal control 2', [[2068, 5, 7], [2069, 2, 20]], [289, 0.791780822]]], [['regression fraction numerator 1', [[2090, 11, 1], [2098, 8, 15]], [2842, 7.78630137]], ['regression fraction numerator 2', [[2005, 6, 30], [2008, 3, 20]], [993, 2.720547945]], ['partial repair probe 1', [[2024, 2, 15], [2029, 8, 29]], [2020, 5.534246575]], ['partial repair probe 2', [[2017, 4, 30], [2021, 2, 26]], [1397, 3.82739726]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[2067, 1, 24], [2067, 6, 15]], [142, 0.389041096]], ['normal control 2', [[2052, 10, 31], [2053, 1, 24]], [85, 0.232876712]]], [['regression fraction numerator 1', [[2023, 8, 22], [2030, 1, 9]], [2330, 6.383561644]], ['regression fraction numerator 2', [[2011, 4, 28], [2012, 4, 29]], [366, 1.002739726]], ['partial repair probe 1', [[1983, 3, 17], [1986, 3, 10]], [1088, 2.980821918]], ['partial repair probe 2', [[2096, 2, 15], [2101, 4, 10]], [1879, 5.147945205]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['normal control 1', [[1919, 5, 31], [1920, 2, 5]], [250, 0.684931507]], ['normal control 2', [[1942, 5, 31], [1943, 7, 20]], [415, 1.136986301]]], [['regression fraction numerator 1', [[2046, 10, 17], [2049, 8, 5]], [1022, 2.8]], ['regression fraction numerator 2', [[2104, 2, 28], [2105, 9, 1]], [550, 1.506849315]], ['partial repair probe 1', [[2103, 7, 31], [2110, 7, 22]], [2546, 6.975342466]], ['partial repair probe 2', [[1976, 4, 30], [1982, 8, 31]], [2313, 6.336986301]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[1904, 3, 1], [1904, 6, 24]], [115, 0.315068493]], ['normal control 2', [[2027, 7, 31], [2027, 11, 6]], [98, 0.268493151]]], [['regression fraction numerator 1', [[1988, 9, 2], [1994, 12, 11]], [2290, 6.273972603]], ['regression fraction numerator 2', [[1996, 3, 15], [2001, 1, 23]], [1774, 4.860273973]], ['partial repair probe 1', [[1941, 8, 31], [1952, 3, 31]], [3862, 10.580821918]], ['partial repair probe 2', [[1932, 4, 20], [1938, 5, 16]], [2216, 6.071232877]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[2104, 3, 15], [2104, 10, 30]], [229, 0.62739726]], ['normal control 2', [[1909, 8, 31], [1909, 11, 13]], [74, 0.202739726]]]]\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"},"fixed":{"sha256":"42bcd279c0cd2c63af53f90feb5a7b0bd240c2604a902b6965fd26ac6118ac72","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(a, b):\n    A = datetime.date(*a)\n    B = datetime.date(*b)\n    if B < A:\n        return 'end before start'\n    def leap(y):\n        return (y % 4 == 0 and y % 100 != 0) or y % 400 == 0\n    leapdays = sum(1 for y in range(A.year, B.year + 1) if leap(y) and A < datetime.date(y, 2, 29) <= B)\n    days = (B - A).days - leapdays\n    return [days, round(days / 365, 9)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression fraction numerator 1', [[2104, 2, 28], [2112, 1, 7]], [2868, 7.857534247]], ['regression fraction numerator 2', [[1986, 2, 27], [1991, 10, 9]], [2049, 5.61369863]], ['partial repair probe 1', [[2104, 1, 1], [2113, 1, 13]], [3297, 9.032876712]], ['partial repair probe 2', [[2034, 2, 27], [2038, 8, 21]], [1635, 4.479452055]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[1896, 3, 15], [1899, 8, 25]], [1258, 3.446575342]], ['normal control 2', [[2068, 5, 7], [2069, 2, 20]], [289, 0.791780822]]], [['regression fraction numerator 1', [[2090, 11, 1], [2098, 8, 15]], [2842, 7.78630137]], ['regression fraction numerator 2', [[2005, 6, 30], [2008, 3, 20]], [993, 2.720547945]], ['partial repair probe 1', [[2024, 2, 15], [2029, 8, 29]], [2020, 5.534246575]], ['partial repair probe 2', [[2017, 4, 30], [2021, 2, 26]], [1397, 3.82739726]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[2067, 1, 24], [2067, 6, 15]], [142, 0.389041096]], ['normal control 2', [[2052, 10, 31], [2053, 1, 24]], [85, 0.232876712]]], [['regression fraction numerator 1', [[2023, 8, 22], [2030, 1, 9]], [2330, 6.383561644]], ['regression fraction numerator 2', [[2011, 4, 28], [2012, 4, 29]], [366, 1.002739726]], ['partial repair probe 1', [[1983, 3, 17], [1986, 3, 10]], [1088, 2.980821918]], ['partial repair probe 2', [[2096, 2, 15], [2101, 4, 10]], [1879, 5.147945205]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['normal control 1', [[1919, 5, 31], [1920, 2, 5]], [250, 0.684931507]], ['normal control 2', [[1942, 5, 31], [1943, 7, 20]], [415, 1.136986301]]], [['regression fraction numerator 1', [[2046, 10, 17], [2049, 8, 5]], [1022, 2.8]], ['regression fraction numerator 2', [[2104, 2, 28], [2105, 9, 1]], [550, 1.506849315]], ['partial repair probe 1', [[2103, 7, 31], [2110, 7, 22]], [2546, 6.975342466]], ['partial repair probe 2', [[1976, 4, 30], [1982, 8, 31]], [2313, 6.336986301]], ['boundary control 1', [[2024, 3, 1], [2024, 12, 31]], [305, 0.835616438]], ['boundary control 2', [[2099, 1, 1], [2101, 1, 1]], [730, 2.0]], ['normal control 1', [[1904, 3, 1], [1904, 6, 24]], [115, 0.315068493]], ['normal control 2', [[2027, 7, 31], [2027, 11, 6]], [98, 0.268493151]]], [['regression fraction numerator 1', [[1988, 9, 2], [1994, 12, 11]], [2290, 6.273972603]], ['regression fraction numerator 2', [[1996, 3, 15], [2001, 1, 23]], [1774, 4.860273973]], ['partial repair probe 1', [[1941, 8, 31], [1952, 3, 31]], [3862, 10.580821918]], ['partial repair probe 2', [[1932, 4, 20], [1938, 5, 16]], [2216, 6.071232877]], ['boundary control 1', [[2024, 2, 29], [2025, 2, 28]], [365, 1.0]], ['boundary control 2', [[2020, 1, 1], [2020, 1, 1]], [0, 0.0]], ['normal control 1', [[2104, 3, 15], [2104, 10, 30]], [229, 0.62739726]], ['normal control 2', [[1909, 8, 31], [1909, 11, 13]], [74, 0.202739726]]]]\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-no-leap-365-fraction-numerator","generated_at":"2026-09-29T14:46:51.416254+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.","repair":"Divide the leap-adjusted day count by 365.","root_cause":"The fraction is computed from the raw calendar difference instead of the adjusted day count.","sha256":"ab2e52595bd6ee39663d08e0dbc4ab713c649b6d0726e95183e1bc0373cb2b35","title":"NL/365 no-leap day count: the year fraction uses actual days while the day count excludes leap days · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":46.097,"exit_code":1,"observations":[{"actual":[2868,7.841530055],"check":"regression fraction numerator 1","expected":[2868,7.857534247],"passed":false},{"actual":[2049,5.601092896],"check":"regression fraction numerator 2","expected":[2049,5.61369863],"passed":false},{"actual":[3297,9.016393443],"check":"partial repair probe 1","expected":[3297,9.032876712],"passed":false},{"actual":[1635,4.469945355],"check":"partial repair probe 2","expected":[1635,4.479452055],"passed":false},{"actual":[365,1.0],"check":"boundary control 1","expected":[365,1.0],"passed":true},{"actual":[0,0.0],"check":"boundary control 2","expected":[0,0.0],"passed":true},{"actual":[1258,3.446575342],"check":"normal control 1","expected":[1258,3.446575342],"passed":true},{"actual":[289,0.791780822],"check":"normal control 2","expected":[289,0.791780822],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression fraction numerator 1\", \"actual\": [2868, 7.841530055], \"expected\": [2868, 7.857534247], \"passed\": false}, {\"check\": \"regression fraction numerator 2\", \"actual\": [2049, 5.601092896], \"expected\": [2049, 5.61369863], \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": [3297, 9.016393443], \"expected\": [3297, 9.032876712], \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": [1635, 4.469945355], \"expected\": [1635, 4.479452055], \"passed\": false}, {\"check\": \"boundary control 1\", \"actual\": [365, 1.0], \"expected\": [365, 1.0], \"passed\": true}, {\"check\": \"boundary control 2\", \"actual\": [0, 0.0], \"expected\": [0, 0.0], \"passed\": true}, {\"check\": \"normal control 1\", \"actual\": [1258, 3.446575342], \"expected\": [1258, 3.446575342], \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": [289, 0.791780822], \"expected\": [289, 0.791780822], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":45.935,"exit_code":1,"observations":[{"actual":[2868,7.863013699],"check":"regression fraction numerator 1","expected":[2868,7.857534247],"passed":false},{"actual":[2049,5.616438356],"check":"regression fraction numerator 2","expected":[2049,5.61369863],"passed":false},{"actual":[3297,9.04109589],"check":"partial repair probe 1","expected":[3297,9.032876712],"passed":false},{"actual":[1635,4.482191781],"check":"partial repair probe 2","expected":[1635,4.479452055],"passed":false},{"actual":[365,1.0],"check":"boundary control 1","expected":[365,1.0],"passed":true},{"actual":[0,0.0],"check":"boundary control 2","expected":[0,0.0],"passed":true},{"actual":[1258,3.446575342],"check":"normal control 1","expected":[1258,3.446575342],"passed":true},{"actual":[289,0.791780822],"check":"normal control 2","expected":[289,0.791780822],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression fraction numerator 1\", \"actual\": [2868, 7.863013699], \"expected\": [2868, 7.857534247], \"passed\": false}, {\"check\": \"regression fraction numerator 2\", \"actual\": [2049, 5.616438356], \"expected\": [2049, 5.61369863], \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": [3297, 9.04109589], \"expected\": [3297, 9.032876712], \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": [1635, 4.482191781], \"expected\": [1635, 4.479452055], \"passed\": false}, {\"check\": \"boundary control 1\", \"actual\": [365, 1.0], \"expected\": [365, 1.0], \"passed\": true}, {\"check\": \"boundary control 2\", \"actual\": [0, 0.0], \"expected\": [0, 0.0], \"passed\": true}, {\"check\": \"normal control 1\", \"actual\": [1258, 3.446575342], \"expected\": [1258, 3.446575342], \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": [289, 0.791780822], \"expected\": [289, 0.791780822], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":46.954,"exit_code":0,"observations":[{"actual":[2868,7.857534247],"check":"regression fraction numerator 1","expected":[2868,7.857534247],"passed":true},{"actual":[2049,5.61369863],"check":"regression fraction numerator 2","expected":[2049,5.61369863],"passed":true},{"actual":[3297,9.032876712],"check":"partial repair probe 1","expected":[3297,9.032876712],"passed":true},{"actual":[1635,4.479452055],"check":"partial repair probe 2","expected":[1635,4.479452055],"passed":true},{"actual":[365,1.0],"check":"boundary control 1","expected":[365,1.0],"passed":true},{"actual":[0,0.0],"check":"boundary control 2","expected":[0,0.0],"passed":true},{"actual":[1258,3.446575342],"check":"normal control 1","expected":[1258,3.446575342],"passed":true},{"actual":[289,0.791780822],"check":"normal control 2","expected":[289,0.791780822],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression fraction numerator 1\", \"actual\": [2868, 7.857534247], \"expected\": [2868, 7.857534247], \"passed\": true}, {\"check\": \"regression fraction numerator 2\", \"actual\": [2049, 5.61369863], \"expected\": [2049, 5.61369863], \"passed\": true}, {\"check\": \"partial repair probe 1\", \"actual\": [3297, 9.032876712], \"expected\": [3297, 9.032876712], \"passed\": true}, {\"check\": \"partial repair probe 2\", \"actual\": [1635, 4.479452055], \"expected\": [1635, 4.479452055], \"passed\": true}, {\"check\": \"boundary control 1\", \"actual\": [365, 1.0], \"expected\": [365, 1.0], \"passed\": true}, {\"check\": \"boundary control 2\", \"actual\": [0, 0.0], \"expected\": [0, 0.0], \"passed\": true}, {\"check\": \"normal control 1\", \"actual\": [1258, 3.446575342], \"expected\": [1258, 3.446575342], \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": [289, 0.791780822], \"expected\": [289, 0.791780822], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}