{"abstract":"Evaluates the right operand even when the left short-circuits and changes the required Python-language result.","category":"Python evaluation","checks":6,"contract":"Evaluate left and rhs() or left or rhs(), returning [the actual selected operand,call log]. Python Boolean operators preserve operand values and call the right side only when needed. 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-short-circuit-operands","failed_approach":"The alternative still fails because it uses OR semantics for the AND operation.","family":"xl-short-circuit-operands-eager-right-evaluation","id":"FA-5286","implementations":{"attempt":{"sha256":"dbce60fb0fcd0ca202721f1ed8134aa0be9cf460e1fefdddce6ed0c20c51e4aa","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(operation, left, right):\n    calls=[]\n    def rhs():\n        calls.append('right')\n        return right\n    result=left or rhs()\n    return [result,calls]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('false AND returns original', solve('and', 0, 'right'), [0, []])\ncheck('true AND evaluates right', solve('and', 'left', 'right'), ['right', ['right']])\ncheck('true OR retains left', solve('or', 'left', 'right'), ['left', []])\ncheck('false OR evaluates right', solve('or', None, 'right'), ['right', ['right']])\ncheck('empty right remains empty', solve('and', 1, []), [[], ['right']])\ncheck('empty left preserved', solve('and', [], None), [[], []])\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":"2bfbd532c10d6b57ea4a7f14e9e1ea1c30d2e038e9491167983da8a0d2e6feec","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(operation, left, right):\n    calls=[]\n    def rhs():\n        calls.append('right')\n        return right\n    r=rhs()\n    result=(left and r) if operation=='and' else (left or r)\n    return [result,calls]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('false AND returns original', solve('and', 0, 'right'), [0, []])\ncheck('true AND evaluates right', solve('and', 'left', 'right'), ['right', ['right']])\ncheck('true OR retains left', solve('or', 'left', 'right'), ['left', []])\ncheck('false OR evaluates right', solve('or', None, 'right'), ['right', ['right']])\ncheck('empty right remains empty', solve('and', 1, []), [[], ['right']])\ncheck('empty left preserved', solve('and', [], None), [[], []])\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":"67f8092f6d183ed42cc99f0ce81dc31a6e2bae5c877264ef67f6499b77de26ab","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(operation, left, right):\n    calls=[]\n    def rhs():\n        calls.append('right')\n        return right\n    result=(left and rhs()) if operation==\"and\" else (left or rhs())\n    return [result,calls]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('false AND returns original', solve('and', 0, 'right'), [0, []])\ncheck('true AND evaluates right', solve('and', 'left', 'right'), ['right', ['right']])\ncheck('true OR retains left', solve('or', 'left', 'right'), ['left', []])\ncheck('false OR evaluates right', solve('or', None, 'right'), ['right', ['right']])\ncheck('empty right remains empty', solve('and', 1, []), [[], ['right']])\ncheck('empty left preserved', solve('and', [], None), [[], []])\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-short-circuit-operands-eager-right-evaluation","generated_at":"2026-09-29T14:37:47.895061+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":"Evaluate left and rhs() or left or rhs(), returning [the actual selected operand,call log]. Python Boolean operators preserve operand values and call the right side only when needed.","root_cause":"Evaluates the right operand even when the left short-circuits. The executable reproducer isolates this operation from the rest of the contract.","sha256":"a08d69a5339ede8ce8c5668812dabe99adb2ca5c68f939f59dd752bf0d95ae1d","title":"Short circuit operands: Evaluates the right operand even when the left short-circuits · 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":36.003,"exit_code":1,"observations":[{"actual":["right",["right"]],"check":"false AND returns original","expected":[0,[]],"passed":false},{"actual":["left",[]],"check":"true AND evaluates right","expected":["right",["right"]],"passed":false},{"actual":["left",[]],"check":"true OR retains left","expected":["left",[]],"passed":true},{"actual":["right",["right"]],"check":"false OR evaluates right","expected":["right",["right"]],"passed":true},{"actual":[1,[]],"check":"empty right remains empty","expected":[[],["right"]],"passed":false},{"actual":[null,["right"]],"check":"empty left preserved","expected":[[],[]],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"false AND returns original\", \"actual\": [\"right\", [\"right\"]], \"expected\": [0, []], \"passed\": false}, {\"check\": \"true AND evaluates right\", \"actual\": [\"left\", []], \"expected\": [\"right\", [\"right\"]], \"passed\": false}, {\"check\": \"true OR retains left\", \"actual\": [\"left\", []], \"expected\": [\"left\", []], \"passed\": true}, {\"check\": \"false OR evaluates right\", \"actual\": [\"right\", [\"right\"]], \"expected\": [\"right\", [\"right\"]], \"passed\": true}, {\"check\": \"empty right remains empty\", \"actual\": [1, []], \"expected\": [[], [\"right\"]], \"passed\": false}, {\"check\": \"empty left preserved\", \"actual\": [null, [\"right\"]], \"expected\": [[], []], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":34.36,"exit_code":1,"observations":[{"actual":[0,["right"]],"check":"false AND returns original","expected":[0,[]],"passed":false},{"actual":["right",["right"]],"check":"true AND evaluates right","expected":["right",["right"]],"passed":true},{"actual":["left",["right"]],"check":"true OR retains left","expected":["left",[]],"passed":false},{"actual":["right",["right"]],"check":"false OR evaluates right","expected":["right",["right"]],"passed":true},{"actual":[[],["right"]],"check":"empty right remains empty","expected":[[],["right"]],"passed":true},{"actual":[[],["right"]],"check":"empty left preserved","expected":[[],[]],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"false AND returns original\", \"actual\": [0, [\"right\"]], \"expected\": [0, []], \"passed\": false}, {\"check\": \"true AND evaluates right\", \"actual\": [\"right\", [\"right\"]], \"expected\": [\"right\", [\"right\"]], \"passed\": true}, {\"check\": \"true OR retains left\", \"actual\": [\"left\", [\"right\"]], \"expected\": [\"left\", []], \"passed\": false}, {\"check\": \"false OR evaluates right\", \"actual\": [\"right\", [\"right\"]], \"expected\": [\"right\", [\"right\"]], \"passed\": true}, {\"check\": \"empty right remains empty\", \"actual\": [[], [\"right\"]], \"expected\": [[], [\"right\"]], \"passed\": true}, {\"check\": \"empty left preserved\", \"actual\": [[], [\"right\"]], \"expected\": [[], []], \"passed\": false}], \"passed\": false}\n"},"fixed":{"elapsed_ms":37.309,"exit_code":0,"observations":[{"actual":[0,[]],"check":"false AND returns original","expected":[0,[]],"passed":true},{"actual":["right",["right"]],"check":"true AND evaluates right","expected":["right",["right"]],"passed":true},{"actual":["left",[]],"check":"true OR retains left","expected":["left",[]],"passed":true},{"actual":["right",["right"]],"check":"false OR evaluates right","expected":["right",["right"]],"passed":true},{"actual":[[],["right"]],"check":"empty right remains empty","expected":[[],["right"]],"passed":true},{"actual":[[],[]],"check":"empty left preserved","expected":[[],[]],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"false AND returns original\", \"actual\": [0, []], \"expected\": [0, []], \"passed\": true}, {\"check\": \"true AND evaluates right\", \"actual\": [\"right\", [\"right\"]], \"expected\": [\"right\", [\"right\"]], \"passed\": true}, {\"check\": \"true OR retains left\", \"actual\": [\"left\", []], \"expected\": [\"left\", []], \"passed\": true}, {\"check\": \"false OR evaluates right\", \"actual\": [\"right\", [\"right\"]], \"expected\": [\"right\", [\"right\"]], \"passed\": true}, {\"check\": \"empty right remains empty\", \"actual\": [[], [\"right\"]], \"expected\": [[], [\"right\"]], \"passed\": true}, {\"check\": \"empty left preserved\", \"actual\": [[], []], \"expected\": [[], []], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}