{"abstract":"Suppresses ValueError even when the policy is disabled and changes the required Python-language result.","category":"Context managers","checks":5,"contract":"A context manager suppresses only ValueError when enabled. __exit__ observes the actual exception class or None on normal exit; unsuppressed exceptions reach the outer handler and skip after. Inputs use the finite Python types shown in the fixtures. An error string denotes the specified caught exception, not an unhandled process failure.","evaluation_group":"xl-context-exception-suppression","failed_approach":"The alternative still fails because it passes a normal-exit placeholder to the exception-reporting path.","family":"xl-context-exception-suppression-ignore-policy","id":"FA-5141","implementations":{"attempt":{"sha256":"e7ec64ae1df37a67c908d585438581897af96e1c38f94bc13cc9ddba2df5a42a","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(error, enabled):\n    log=[]\n    class Manager:\n        def __enter__(self):\n            log.append('enter')\n            return self\n        def __exit__(self, typ, exc, tb):\n            log.append('exit:none')\n            return typ is ValueError and enabled\n    try:\n        with Manager():\n            log.append('body')\n            if error=='value': raise ValueError('value')\n            if error=='key': raise KeyError('key')\n            if error=='type': raise TypeError('type')\n        log.append('after')\n    except Exception as exc:\n        log.append('caught:'+type(exc).__name__)\n    return log\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('normal exit', solve('none', True), ['enter', 'body', 'exit:none', 'after'])\ncheck('selected error suppressed', solve('value', True), ['enter', 'body', 'exit:ValueError', 'after'])\ncheck('disabled propagation', solve('value', False), ['enter', 'body', 'exit:ValueError', 'caught:ValueError'])\ncheck('unrelated error propagates', solve('key', True), ['enter', 'body', 'exit:KeyError', 'caught:KeyError'])\ncheck('other unrelated type', solve('type', True), ['enter', 'body', 'exit:TypeError', 'caught:TypeError'])\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":"13f503211282da046e42b6d88dae8b6bab7b377d13143c436ba23d5a8a15ad17","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(error, enabled):\n    log=[]\n    class Manager:\n        def __enter__(self):\n            log.append('enter')\n            return self\n        def __exit__(self, typ, exc, tb):\n            log.append('exit:'+('none' if typ is None else typ.__name__))\n            return typ is ValueError\n    try:\n        with Manager():\n            log.append('body')\n            if error=='value': raise ValueError('value')\n            if error=='key': raise KeyError('key')\n            if error=='type': raise TypeError('type')\n        log.append('after')\n    except Exception as exc:\n        log.append('caught:'+type(exc).__name__)\n    return log\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('normal exit', solve('none', True), ['enter', 'body', 'exit:none', 'after'])\ncheck('selected error suppressed', solve('value', True), ['enter', 'body', 'exit:ValueError', 'after'])\ncheck('disabled propagation', solve('value', False), ['enter', 'body', 'exit:ValueError', 'caught:ValueError'])\ncheck('unrelated error propagates', solve('key', True), ['enter', 'body', 'exit:KeyError', 'caught:KeyError'])\ncheck('other unrelated type', solve('type', True), ['enter', 'body', 'exit:TypeError', 'caught:TypeError'])\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":"28bc3eb1a5f50a36a2e2c15669ed1394b41285c80e1d21dfd5ce2359cd5baecb","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(error, enabled):\n    log=[]\n    class Manager:\n        def __enter__(self):\n            log.append('enter')\n            return self\n        def __exit__(self, typ, exc, tb):\n            log.append('exit:'+('none' if typ is None else typ.__name__))\n            return typ is ValueError and enabled\n    try:\n        with Manager():\n            log.append('body')\n            if error=='value': raise ValueError('value')\n            if error=='key': raise KeyError('key')\n            if error=='type': raise TypeError('type')\n        log.append('after')\n    except Exception as exc:\n        log.append('caught:'+type(exc).__name__)\n    return log\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('normal exit', solve('none', True), ['enter', 'body', 'exit:none', 'after'])\ncheck('selected error suppressed', solve('value', True), ['enter', 'body', 'exit:ValueError', 'after'])\ncheck('disabled propagation', solve('value', False), ['enter', 'body', 'exit:ValueError', 'caught:ValueError'])\ncheck('unrelated error propagates', solve('key', True), ['enter', 'body', 'exit:KeyError', 'caught:KeyError'])\ncheck('other unrelated type', solve('type', True), ['enter', 'body', 'exit:TypeError', 'caught:TypeError'])\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":"xl-context-exception-suppression-ignore-policy","generated_at":"2026-09-29T14:37:46.464996+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Runs Python standard-library language operations in a deterministic local reproducer. Literal expected answers are authored independently. Related defects share an evaluation group to avoid benchmark split leakage.","repair":"A context manager suppresses only ValueError when enabled. __exit__ observes the actual exception class or None on normal exit; unsuppressed exceptions reach the outer handler and skip after.","root_cause":"Suppresses ValueError even when the policy is disabled. The executable reproducer isolates this operation from the rest of the contract.","sha256":"44b9b625a31b1997a8635c8a0bd61504cb478c5fdceea88c94c644ead2482dbf","title":"Context exception suppression: Suppresses ValueError even when the policy is disabled · case 01","variant":1,"variant_policy":"The five numbered cases rerun the same authored boundary fixtures; they are reproducibility runs, not independent input variants.","verification":{"attempt":{"elapsed_ms":37.619,"exit_code":1,"observations":[{"actual":["enter","body","exit:none","after"],"check":"normal exit","expected":["enter","body","exit:none","after"],"passed":true},{"actual":["enter","body","exit:none","after"],"check":"selected error suppressed","expected":["enter","body","exit:ValueError","after"],"passed":false},{"actual":["enter","body","exit:none","caught:ValueError"],"check":"disabled propagation","expected":["enter","body","exit:ValueError","caught:ValueError"],"passed":false},{"actual":["enter","body","exit:none","caught:KeyError"],"check":"unrelated error propagates","expected":["enter","body","exit:KeyError","caught:KeyError"],"passed":false},{"actual":["enter","body","exit:none","caught:TypeError"],"check":"other unrelated type","expected":["enter","body","exit:TypeError","caught:TypeError"],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"normal exit\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"passed\": true}, {\"check\": \"selected error suppressed\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"passed\": false}, {\"check\": \"disabled propagation\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"caught:ValueError\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"caught:ValueError\"], \"passed\": false}, {\"check\": \"unrelated error propagates\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"caught:KeyError\"], \"expected\": [\"enter\", \"body\", \"exit:KeyError\", \"caught:KeyError\"], \"passed\": false}, {\"check\": \"other unrelated type\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"caught:TypeError\"], \"expected\": [\"enter\", \"body\", \"exit:TypeError\", \"caught:TypeError\"], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":35.659,"exit_code":1,"observations":[{"actual":["enter","body","exit:none","after"],"check":"normal exit","expected":["enter","body","exit:none","after"],"passed":true},{"actual":["enter","body","exit:ValueError","after"],"check":"selected error suppressed","expected":["enter","body","exit:ValueError","after"],"passed":true},{"actual":["enter","body","exit:ValueError","after"],"check":"disabled propagation","expected":["enter","body","exit:ValueError","caught:ValueError"],"passed":false},{"actual":["enter","body","exit:KeyError","caught:KeyError"],"check":"unrelated error propagates","expected":["enter","body","exit:KeyError","caught:KeyError"],"passed":true},{"actual":["enter","body","exit:TypeError","caught:TypeError"],"check":"other unrelated type","expected":["enter","body","exit:TypeError","caught:TypeError"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"normal exit\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"passed\": true}, {\"check\": \"selected error suppressed\", \"actual\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"passed\": true}, {\"check\": \"disabled propagation\", \"actual\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"caught:ValueError\"], \"passed\": false}, {\"check\": \"unrelated error propagates\", \"actual\": [\"enter\", \"body\", \"exit:KeyError\", \"caught:KeyError\"], \"expected\": [\"enter\", \"body\", \"exit:KeyError\", \"caught:KeyError\"], \"passed\": true}, {\"check\": \"other unrelated type\", \"actual\": [\"enter\", \"body\", \"exit:TypeError\", \"caught:TypeError\"], \"expected\": [\"enter\", \"body\", \"exit:TypeError\", \"caught:TypeError\"], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":36.816,"exit_code":0,"observations":[{"actual":["enter","body","exit:none","after"],"check":"normal exit","expected":["enter","body","exit:none","after"],"passed":true},{"actual":["enter","body","exit:ValueError","after"],"check":"selected error suppressed","expected":["enter","body","exit:ValueError","after"],"passed":true},{"actual":["enter","body","exit:ValueError","caught:ValueError"],"check":"disabled propagation","expected":["enter","body","exit:ValueError","caught:ValueError"],"passed":true},{"actual":["enter","body","exit:KeyError","caught:KeyError"],"check":"unrelated error propagates","expected":["enter","body","exit:KeyError","caught:KeyError"],"passed":true},{"actual":["enter","body","exit:TypeError","caught:TypeError"],"check":"other unrelated type","expected":["enter","body","exit:TypeError","caught:TypeError"],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"normal exit\", \"actual\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:none\", \"after\"], \"passed\": true}, {\"check\": \"selected error suppressed\", \"actual\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"after\"], \"passed\": true}, {\"check\": \"disabled propagation\", \"actual\": [\"enter\", \"body\", \"exit:ValueError\", \"caught:ValueError\"], \"expected\": [\"enter\", \"body\", \"exit:ValueError\", \"caught:ValueError\"], \"passed\": true}, {\"check\": \"unrelated error propagates\", \"actual\": [\"enter\", \"body\", \"exit:KeyError\", \"caught:KeyError\"], \"expected\": [\"enter\", \"body\", \"exit:KeyError\", \"caught:KeyError\"], \"passed\": true}, {\"check\": \"other unrelated type\", \"actual\": [\"enter\", \"body\", \"exit:TypeError\", \"caught:TypeError\"], \"expected\": [\"enter\", \"body\", \"exit:TypeError\", \"caught:TypeError\"], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}