{"abstract":"Constraint violation is traded away by objective weighting.","category":"Optimization solver contracts","checks":6,"contract":"Given candidate (name,nonnegative violation,objective) triples, return name minimizing (violation,objective), stable on exact ties; None for empty.","evaluation_group":"model-2063eccd30b7ecdb","failed_approach":"Prioritizing only the feasible flag fails to rank two infeasible candidates by violation.","family":"z-optimization-feasibility-ranking","id":"FA-12026","implementations":{"attempt":{"sha256":"8e989fbf83358cce7ba1f76b3213d074d4189136f77cb84cc66293408ff24d40","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(candidates):\n    return min(candidates,key=lambda c:(c[1]>0,c[2]))[0] if candidates else None\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('feasibility dominates', solve([(\"a\",0,100*N),(\"b\",1,0)]), 'a')\ncheck('infeasible ordering', solve([(\"a\",N,100),(\"b\",2*N,0)]), 'a')\ncheck('objective tiebreak', solve([(\"a\",0,4),(\"b\",0,2)]), 'b')\ncheck('stable ties', solve([(\"a\",N,2),(\"b\",N,2)]), 'a')\ncheck('single candidate', solve([(\"a\",N,-3)]), 'a')\ncheck('no candidates', solve([]), 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":"1eb5de2779a48953dfc64cdf14aa9f6dde69a03c0c8081a569e1ab0746ce0c49","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(candidates):\n    return min(candidates,key=lambda c:c[2]+10*c[1])[0] if candidates else None\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('feasibility dominates', solve([(\"a\",0,100*N),(\"b\",1,0)]), 'a')\ncheck('infeasible ordering', solve([(\"a\",N,100),(\"b\",2*N,0)]), 'a')\ncheck('objective tiebreak', solve([(\"a\",0,4),(\"b\",0,2)]), 'b')\ncheck('stable ties', solve([(\"a\",N,2),(\"b\",N,2)]), 'a')\ncheck('single candidate', solve([(\"a\",N,-3)]), 'a')\ncheck('no candidates', solve([]), 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":"3cda5cc81a07fb6eac84054e27e94cb959de84abe0b8cbba3c68b1d357074c7e","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(candidates):\n    return min(candidates,key=lambda c:(c[1],c[2]))[0] if candidates else None\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('feasibility dominates', solve([(\"a\",0,100*N),(\"b\",1,0)]), 'a')\ncheck('infeasible ordering', solve([(\"a\",N,100),(\"b\",2*N,0)]), 'a')\ncheck('objective tiebreak', solve([(\"a\",0,4),(\"b\",0,2)]), 'b')\ncheck('stable ties', solve([(\"a\",N,2),(\"b\",N,2)]), 'a')\ncheck('single candidate', solve([(\"a\",N,-3)]), 'a')\ncheck('no candidates', solve([]), 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":"Controlled finite inputs and explicit one-step contracts; this is not a production solver or a numerical stability benchmark. 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":"z-optimization-feasibility-ranking","generated_at":"2026-09-29T14:38:53.069521+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"This deterministic solver-step model isolates an algorithmic invariant used by iterative optimization implementations.","repair":"Order by violation first, objective second, then stable input position.","root_cause":"Finite penalty weighting allows an infeasible candidate to beat a feasible one.","sha256":"1afc9e829ff7ed3eaac8bceeb8483d736287d374ae66cb9bfbf12a173d19fc20","title":"Constraint violation is traded away by objective weighting · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":38.601,"exit_code":1,"observations":[{"actual":"a","check":"feasibility dominates","expected":"a","passed":true},{"actual":"b","check":"infeasible ordering","expected":"a","passed":false},{"actual":"b","check":"objective tiebreak","expected":"b","passed":true},{"actual":"a","check":"stable ties","expected":"a","passed":true},{"actual":"a","check":"single candidate","expected":"a","passed":true},{"actual":null,"check":"no candidates","expected":null,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"feasibility dominates\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"infeasible ordering\", \"actual\": \"b\", \"expected\": \"a\", \"passed\": false}, {\"check\": \"objective tiebreak\", \"actual\": \"b\", \"expected\": \"b\", \"passed\": true}, {\"check\": \"stable ties\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"single candidate\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"no candidates\", \"actual\": null, \"expected\": null, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":40.464,"exit_code":1,"observations":[{"actual":"b","check":"feasibility dominates","expected":"a","passed":false},{"actual":"b","check":"infeasible ordering","expected":"a","passed":false},{"actual":"b","check":"objective tiebreak","expected":"b","passed":true},{"actual":"a","check":"stable ties","expected":"a","passed":true},{"actual":"a","check":"single candidate","expected":"a","passed":true},{"actual":null,"check":"no candidates","expected":null,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"feasibility dominates\", \"actual\": \"b\", \"expected\": \"a\", \"passed\": false}, {\"check\": \"infeasible ordering\", \"actual\": \"b\", \"expected\": \"a\", \"passed\": false}, {\"check\": \"objective tiebreak\", \"actual\": \"b\", \"expected\": \"b\", \"passed\": true}, {\"check\": \"stable ties\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"single candidate\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"no candidates\", \"actual\": null, \"expected\": null, \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":41.635,"exit_code":0,"observations":[{"actual":"a","check":"feasibility dominates","expected":"a","passed":true},{"actual":"a","check":"infeasible ordering","expected":"a","passed":true},{"actual":"b","check":"objective tiebreak","expected":"b","passed":true},{"actual":"a","check":"stable ties","expected":"a","passed":true},{"actual":"a","check":"single candidate","expected":"a","passed":true},{"actual":null,"check":"no candidates","expected":null,"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"feasibility dominates\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"infeasible ordering\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"objective tiebreak\", \"actual\": \"b\", \"expected\": \"b\", \"passed\": true}, {\"check\": \"stable ties\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"single candidate\", \"actual\": \"a\", \"expected\": \"a\", \"passed\": true}, {\"check\": \"no candidates\", \"actual\": null, \"expected\": null, \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}