{"abstract":"A fixed thirty-day model loses long months and leap days.","category":"Calendar arithmetic","checks":4,"contract":"Valid ISO Gregorian dates in years 1 through 9999; generated dates must remain in that range. Month is 1 through 12 and zero-based weekday is Monday 0 through Sunday 6 unless the output convention says otherwise. Calendar month length. Exact operational definition: calendar.monthrange(year,month)[1]","evaluation_group":"model-599c5b45d0a5d530","failed_approach":"The February repair uses an incomplete century rule.","family":"xn-calendar-month-length","id":"FA-6481","implementations":{"attempt":{"sha256":"0c123c4ed9d03f3b7d7ddaa82afc4f41a24f1fbb17931fbd2ae5d36074771bef","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nimport calendar\nimport statistics\nimport itertools\nfrom fractions import Fraction\nfrom datetime import date, datetime, timedelta, timezone\nfrom decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR\n\nN = 1\nobservations = []\ndef solve(year, month):\n    return 29 if month==2 and year%4==0 else (28 if month==2 else (31 if month in [1,3,5,7,8,10,12] else 30))\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1: (2024, 2)', solve(*(2024, 2)), 29)\ncheck('fixture 2: (2100, 2)', solve(*(2100, 2)), 28)\ncheck('fixture 3: (2023, 1)', solve(*(2023, 1)), 31)\ncheck('fixture 4: (2023, 4)', solve(*(2023, 4)), 30)\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":"ef64be1cd9e4511f28aca57e589903cacf467aece92e4208b2ec84f6f66b018c","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nimport calendar\nimport statistics\nimport itertools\nfrom fractions import Fraction\nfrom datetime import date, datetime, timedelta, timezone\nfrom decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR\n\nN = 1\nobservations = []\ndef solve(year, month):\n    return 30 if month!=2 else 28\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1: (2024, 2)', solve(*(2024, 2)), 29)\ncheck('fixture 2: (2100, 2)', solve(*(2100, 2)), 28)\ncheck('fixture 3: (2023, 1)', solve(*(2023, 1)), 31)\ncheck('fixture 4: (2023, 4)', solve(*(2023, 4)), 30)\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":"ff492778d9f49978f967bcb8e82f6676986bc8e731c827c915a5e4cdbad9a6cb","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nimport calendar\nimport statistics\nimport itertools\nfrom fractions import Fraction\nfrom datetime import date, datetime, timedelta, timezone\nfrom decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR\n\nN = 1\nobservations = []\ndef solve(year, month):\n    return calendar.monthrange(year,month)[1]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1: (2024, 2)', solve(*(2024, 2)), 29)\ncheck('fixture 2: (2100, 2)', solve(*(2100, 2)), 28)\ncheck('fixture 3: (2023, 1)', solve(*(2023, 1)), 31)\ncheck('fixture 4: (2023, 4)', solve(*(2023, 4)), 30)\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":" 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":"xn-calendar-month-length","generated_at":"2026-09-29T14:38:02.415814+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Small exact fixtures expose this error without platform timing, external services, or probabilistic observations. Calendar conventions results depend on the stated convention.","repair":"Apply the specified mathematical contract directly, preserving all terms and boundary cases: return calendar.monthrange(year,month)[1]","root_cause":"A fixed thirty-day model loses long months and leap days.","sha256":"766d88cc0f74ed579b81a879d7dce73355cbed407b2b14f9479e81c8b3864da8","title":"Calendar month length · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":117.656,"exit_code":1,"observations":[{"actual":29,"check":"fixture 1: (2024, 2)","expected":29,"passed":true},{"actual":29,"check":"fixture 2: (2100, 2)","expected":28,"passed":false},{"actual":31,"check":"fixture 3: (2023, 1)","expected":31,"passed":true},{"actual":30,"check":"fixture 4: (2023, 4)","expected":30,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1: (2024, 2)\", \"actual\": 29, \"expected\": 29, \"passed\": true}, {\"check\": \"fixture 2: (2100, 2)\", \"actual\": 29, \"expected\": 28, \"passed\": false}, {\"check\": \"fixture 3: (2023, 1)\", \"actual\": 31, \"expected\": 31, \"passed\": true}, {\"check\": \"fixture 4: (2023, 4)\", \"actual\": 30, \"expected\": 30, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":42.411,"exit_code":1,"observations":[{"actual":28,"check":"fixture 1: (2024, 2)","expected":29,"passed":false},{"actual":28,"check":"fixture 2: (2100, 2)","expected":28,"passed":true},{"actual":30,"check":"fixture 3: (2023, 1)","expected":31,"passed":false},{"actual":30,"check":"fixture 4: (2023, 4)","expected":30,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1: (2024, 2)\", \"actual\": 28, \"expected\": 29, \"passed\": false}, {\"check\": \"fixture 2: (2100, 2)\", \"actual\": 28, \"expected\": 28, \"passed\": true}, {\"check\": \"fixture 3: (2023, 1)\", \"actual\": 30, \"expected\": 31, \"passed\": false}, {\"check\": \"fixture 4: (2023, 4)\", \"actual\": 30, \"expected\": 30, \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":43.231,"exit_code":0,"observations":[{"actual":29,"check":"fixture 1: (2024, 2)","expected":29,"passed":true},{"actual":28,"check":"fixture 2: (2100, 2)","expected":28,"passed":true},{"actual":31,"check":"fixture 3: (2023, 1)","expected":31,"passed":true},{"actual":30,"check":"fixture 4: (2023, 4)","expected":30,"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1: (2024, 2)\", \"actual\": 29, \"expected\": 29, \"passed\": true}, {\"check\": \"fixture 2: (2100, 2)\", \"actual\": 28, \"expected\": 28, \"passed\": true}, {\"check\": \"fixture 3: (2023, 1)\", \"actual\": 31, \"expected\": 31, \"passed\": true}, {\"check\": \"fixture 4: (2023, 4)\", \"actual\": 30, \"expected\": 30, \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}