{"abstract":"An ERA of 3.375 is shown as 3.37.","category":"Sports scoring and tiebreakers","checks":9,"contract":"Pitching line aggregation. outings rows are [innings_pitched, earned_runs] where innings pitched use baseball notation \"6.2\" = 6 innings and 2 outs (the digit after the point is 0-2; otherwise return \"invalid ip <text>\"). Sum outs exactly. ERA = innings_per_game * earned runs / innings, rounded half up to two decimals. Return [total innings \"I.O\", ERA string]; with zero outs ERA is \"INF\" if any earned runs else \"0.00\".","contract_signature":"outings, innings_per_game","evaluation_group":"w2-sports-scoring-baseball-innings-pitched-era","failed_approach":"Python's round() on the exact value rounds halves to even and still misses some half-way cases.","family":"w2-sports-scoring-baseball-innings-pitched-era-era-rounding","id":"FA-84126","implementations":{"attempt":{"sha256":"074221e0519ca7230c712b1664a4887610dd3211bd4312d76d12f05c34dd85b6","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom fractions import Fraction\nimport math\nN = 1\nobservations = []\ndef solve(outings, innings_per_game):\n    outs = er = 0\n    for ip, runs in outings:\n        whole, _, part = ip.partition('.')\n        part = int(part or 0)\n        if part > 2:\n            return 'invalid ip ' + ip\n        outs += int(whole) * 3 + part\n        er += runs\n    ip_str = '%d.%d' % (outs // 3, outs % 3)\n    if outs == 0:\n        return [ip_str, 'INF' if er else '0.00']\n    v = Fraction(innings_per_game * er * 3, outs)\n    cents = round(v * 100)\n    return [ip_str, '%d.%02d' % (cents // 100, cents % 100)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ndef run(args):\n    try:\n        return solve(*args)\n    except Exception as exc:\n        return 'raised ' + type(exc).__name__\ncases = [[('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['8.0', 1]], 9), ['8.0', '1.13']),\n  ('variant scenario 1', ([['9.2', 2], ['4.3', 0], ['5.0', 0]], 9), 'invalid ip 4.3'),\n  ('variant scenario 2', ([['3.0', 2], ['7.0', 4], ['1.2', 3]], 7), ['11.2', '5.40'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['7.2', 4]], 9), ['7.2', '4.70']),\n  ('regression: era rounding', ([['8.0', 5]], 9), ['8.0', '5.63']),\n  ('variant scenario 1', ([['2.0', 0], ['2.2', 1], ['6.0', 1], ['2', 2]], 7), ['12.2', '2.21']),\n  ('variant scenario 2', ([['1.1', 4], ['2.2', 4], ['1.2', 4]], 7), ['5.2', '14.82'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['8.2', 4], ['8.2', 0]], 9), ['17.1', '2.08']),\n  ('regression: era rounding',\n   ([['3.0', 2], ['1.2', 2], ['8.2', 1], ['3.2', 2], ['4.1', 1]], 7),\n   ['21.1', '2.63']),\n  ('variant scenario 1', ([['8.1', 3], ['8', 0]], 9), ['16.1', '1.65']),\n  ('variant scenario 2', ([['5.3', 0], ['4.1', 4]], 9), 'invalid ip 5.3')],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding',\n   ([['4.0', 2], ['4.0', 1], ['0', 1], ['3.2', 2], ['5.1', 0]], 9),\n   ['17.0', '3.18']),\n  ('regression: era rounding', ([['1', 0], ['0', 0], ['6.0', 3], ['6.1', 0]], 9), ['13.1', '2.03']),\n  ('variant scenario 1',\n   ([['9.2', 0], ['7.2', 1], ['8.2', 2], ['4.2', 3], ['5.0', 3]], 9),\n   ['35.2', '2.27']),\n  ('variant scenario 2', ([['6.1', 4]], 9), ['6.1', '5.68'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding',\n   ([['3.2', 2], ['2.2', 1], ['6.0', 2], ['6', 0], ['0.1', 4]], 9),\n   ['18.2', '4.34']),\n  ('regression: era rounding', ([['8.0', 5]], 9), ['8.0', '5.63']),\n  ('variant scenario 1', ([['5.0', 3]], 7), ['5.0', '4.20']),\n  ('variant scenario 2', ([['7.0', 1], ['7.0', 0]], 9), ['14.0', '0.64'])]]\nfor label, args, expected in cases[N - 1]:\n    check(label, run(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":"5538c96e40826d3c512ca271590fee02b708d734bb15747607a1c195d28b4cb1","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom fractions import Fraction\nimport math\nN = 1\nobservations = []\ndef solve(outings, innings_per_game):\n    outs = er = 0\n    for ip, runs in outings:\n        whole, _, part = ip.partition('.')\n        part = int(part or 0)\n        if part > 2:\n            return 'invalid ip ' + ip\n        outs += int(whole) * 3 + part\n        er += runs\n    ip_str = '%d.%d' % (outs // 3, outs % 3)\n    if outs == 0:\n        return [ip_str, 'INF' if er else '0.00']\n    v = Fraction(innings_per_game * er * 3, outs)\n    cents = math.floor(v * 100)\n    return [ip_str, '%d.%02d' % (cents // 100, cents % 100)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ndef run(args):\n    try:\n        return solve(*args)\n    except Exception as exc:\n        return 'raised ' + type(exc).__name__\ncases = [[('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['8.0', 1]], 9), ['8.0', '1.13']),\n  ('variant scenario 1', ([['9.2', 2], ['4.3', 0], ['5.0', 0]], 9), 'invalid ip 4.3'),\n  ('variant scenario 2', ([['3.0', 2], ['7.0', 4], ['1.2', 3]], 7), ['11.2', '5.40'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['7.2', 4]], 9), ['7.2', '4.70']),\n  ('regression: era rounding', ([['8.0', 5]], 9), ['8.0', '5.63']),\n  ('variant scenario 1', ([['2.0', 0], ['2.2', 1], ['6.0', 1], ['2', 2]], 7), ['12.2', '2.21']),\n  ('variant scenario 2', ([['1.1', 4], ['2.2', 4], ['1.2', 4]], 7), ['5.2', '14.82'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding', ([['8.2', 4], ['8.2', 0]], 9), ['17.1', '2.08']),\n  ('regression: era rounding',\n   ([['3.0', 2], ['1.2', 2], ['8.2', 1], ['3.2', 2], ['4.1', 1]], 7),\n   ['21.1', '2.63']),\n  ('variant scenario 1', ([['8.1', 3], ['8', 0]], 9), ['16.1', '1.65']),\n  ('variant scenario 2', ([['5.3', 0], ['4.1', 4]], 9), 'invalid ip 5.3')],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding',\n   ([['4.0', 2], ['4.0', 1], ['0', 1], ['3.2', 2], ['5.1', 0]], 9),\n   ['17.0', '3.18']),\n  ('regression: era rounding', ([['1', 0], ['0', 0], ['6.0', 3], ['6.1', 0]], 9), ['13.1', '2.03']),\n  ('variant scenario 1',\n   ([['9.2', 0], ['7.2', 1], ['8.2', 2], ['4.2', 3], ['5.0', 3]], 9),\n   ['35.2', '2.27']),\n  ('variant scenario 2', ([['6.1', 4]], 9), ['6.1', '5.68'])],\n [('control complete game', ([['9.0', 2]], 9), ['9.0', '2.00']),\n  ('boundary thirds carry', ([['5.2', 1], ['1.1', 0]], 9), ['7.0', '1.29']),\n  ('boundary seven-inning game', ([['7.0', 3]], 7), ['7.0', '3.00']),\n  ('boundary no outs with runs', ([['0.0', 2]], 9), ['0.0', 'INF']),\n  ('boundary invalid out digit', ([['4.3', 1]], 9), 'invalid ip 4.3'),\n  ('control half-up rounding', ([['8.0', 3]], 9), ['8.0', '3.38']),\n  ('regression: era rounding',\n   ([['3.2', 2], ['2.2', 1], ['6.0', 2], ['6', 0], ['0.1', 4]], 9),\n   ['18.2', '4.34']),\n  ('regression: era rounding', ([['8.0', 5]], 9), ['8.0', '5.63']),\n  ('variant scenario 1', ([['5.0', 3]], 7), ['5.0', '4.20']),\n  ('variant scenario 2', ([['7.0', 1], ['7.0', 0]], 9), ['14.0', '0.64'])]]\nfor label, args, expected in cases[N - 1]:\n    check(label, run(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":"Stipulated, bounded toy contract stated in the contract field; not a claim of conformance with any governing body rulebook or operator house rules. 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-sports-scoring-baseball-innings-pitched-era-era-rounding","generated_at":"2026-09-29T14:50:27.876413+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Box scores and stat pages aggregate outs across appearances; thirds of an inning are notorious.","root_cause":"The cents are computed with floor(v * 100).","sha256":"0de1bcb4b9a4b53d88395103bb6c4cb54ed3b0b61d4c352a29f5e695dfcce408","title":"ERA truncated instead of rounded half up · 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":41.379,"exit_code":1,"observations":[{"actual":["9.0","2.00"],"check":"control complete game","expected":["9.0","2.00"],"passed":true},{"actual":["7.0","1.29"],"check":"boundary thirds carry","expected":["7.0","1.29"],"passed":true},{"actual":["7.0","3.00"],"check":"boundary seven-inning game","expected":["7.0","3.00"],"passed":true},{"actual":["0.0","INF"],"check":"boundary no outs with runs","expected":["0.0","INF"],"passed":true},{"actual":"invalid ip 4.3","check":"boundary invalid out digit","expected":"invalid ip 4.3","passed":true},{"actual":["8.0","3.38"],"check":"control half-up rounding","expected":["8.0","3.38"],"passed":true},{"actual":["8.0","1.12"],"check":"regression: era rounding","expected":["8.0","1.13"],"passed":false},{"actual":"invalid ip 4.3","check":"variant scenario 1","expected":"invalid ip 4.3","passed":true},{"actual":["11.2","5.40"],"check":"variant scenario 2","expected":["11.2","5.40"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"control complete game\", \"actual\": [\"9.0\", \"2.00\"], \"expected\": [\"9.0\", \"2.00\"], \"passed\": true}, {\"check\": \"boundary thirds carry\", \"actual\": [\"7.0\", \"1.29\"], \"expected\": [\"7.0\", \"1.29\"], \"passed\": true}, {\"check\": \"boundary seven-inning game\", \"actual\": [\"7.0\", \"3.00\"], \"expected\": [\"7.0\", \"3.00\"], \"passed\": true}, {\"check\": \"boundary no outs with runs\", \"actual\": [\"0.0\", \"INF\"], \"expected\": [\"0.0\", \"INF\"], \"passed\": true}, {\"check\": \"boundary invalid out digit\", \"actual\": \"invalid ip 4.3\", \"expected\": \"invalid ip 4.3\", \"passed\": true}, {\"check\": \"control half-up rounding\", \"actual\": [\"8.0\", \"3.38\"], \"expected\": [\"8.0\", \"3.38\"], \"passed\": true}, {\"check\": \"regression: era rounding\", \"actual\": [\"8.0\", \"1.12\"], \"expected\": [\"8.0\", \"1.13\"], \"passed\": false}, {\"check\": \"variant scenario 1\", \"actual\": \"invalid ip 4.3\", \"expected\": \"invalid ip 4.3\", \"passed\": true}, {\"check\": \"variant scenario 2\", \"actual\": [\"11.2\", \"5.40\"], \"expected\": [\"11.2\", \"5.40\"], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":40.373,"exit_code":1,"observations":[{"actual":["9.0","2.00"],"check":"control complete game","expected":["9.0","2.00"],"passed":true},{"actual":["7.0","1.28"],"check":"boundary thirds carry","expected":["7.0","1.29"],"passed":false},{"actual":["7.0","3.00"],"check":"boundary seven-inning game","expected":["7.0","3.00"],"passed":true},{"actual":["0.0","INF"],"check":"boundary no outs with runs","expected":["0.0","INF"],"passed":true},{"actual":"invalid ip 4.3","check":"boundary invalid out digit","expected":"invalid ip 4.3","passed":true},{"actual":["8.0","3.37"],"check":"control half-up rounding","expected":["8.0","3.38"],"passed":false},{"actual":["8.0","1.12"],"check":"regression: era rounding","expected":["8.0","1.13"],"passed":false},{"actual":"invalid ip 4.3","check":"variant scenario 1","expected":"invalid ip 4.3","passed":true},{"actual":["11.2","5.40"],"check":"variant scenario 2","expected":["11.2","5.40"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"control complete game\", \"actual\": [\"9.0\", \"2.00\"], \"expected\": [\"9.0\", \"2.00\"], \"passed\": true}, {\"check\": \"boundary thirds carry\", \"actual\": [\"7.0\", \"1.28\"], \"expected\": [\"7.0\", \"1.29\"], \"passed\": false}, {\"check\": \"boundary seven-inning game\", \"actual\": [\"7.0\", \"3.00\"], \"expected\": [\"7.0\", \"3.00\"], \"passed\": true}, {\"check\": \"boundary no outs with runs\", \"actual\": [\"0.0\", \"INF\"], \"expected\": [\"0.0\", \"INF\"], \"passed\": true}, {\"check\": \"boundary invalid out digit\", \"actual\": \"invalid ip 4.3\", \"expected\": \"invalid ip 4.3\", \"passed\": true}, {\"check\": \"control half-up rounding\", \"actual\": [\"8.0\", \"3.37\"], \"expected\": [\"8.0\", \"3.38\"], \"passed\": false}, {\"check\": \"regression: era rounding\", \"actual\": [\"8.0\", \"1.12\"], \"expected\": [\"8.0\", \"1.13\"], \"passed\": false}, {\"check\": \"variant scenario 1\", \"actual\": \"invalid ip 4.3\", \"expected\": \"invalid ip 4.3\", \"passed\": true}, {\"check\": \"variant scenario 2\", \"actual\": [\"11.2\", \"5.40\"], \"expected\": [\"11.2\", \"5.40\"], \"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."}}