{"abstract":"The operation returns a result or retained state that violates this contract: Order [priority,label] jobs by priority, using arrival sequence to break equal priorities independently of label lexical order.","category":"Heap invariants","checks":4,"contract":"Order [priority,label] jobs by priority, using arrival sequence to break equal priorities independently of label lexical order. Inputs are the finite Python values shown by the executable fixtures; no concurrent execution is assumed.","contract_signature":"x, y=None","evaluation_group":"model-6a91a8eb20520a09","failed_approach":"Returning arrival order without prioritization ignores unequal priorities.","family":"xr-heap-priority-ties-use-arrival-order","id":"FA-4826","implementations":{"attempt":{"sha256":"400a016445f936f0dd9baed63c2b1eefbea4f95dc7f5855f6c3f6926b91f7baa","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom collections import Counter, ChainMap, deque\nimport heapq\nN = 1\nobservations = []\ndef solve(x, y=None):\n    return [v for p,v in x]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('equal priority stable', solve([[1, 'z'], [1, 'a'], [0, 'm']]), ['m', 'z', 'a'])\ncheck('priority dominates arrival', solve([[2, 'a'], [1, 'b']]), ['b', 'a'])\ncheck('empty', solve([]), [])\ncheck('singleton', solve([[1, 'a']]), ['a'])\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":"6f0c0b9317c37d32fb85b32153497c55d7ceeb3ccc9f3063916a7c4fae40e59c","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom collections import Counter, ChainMap, deque\nimport heapq\nN = 1\nobservations = []\ndef solve(x, y=None):\n    a=[(p,v) for p,v in x]; heapq.heapify(a); return [heapq.heappop(a)[1] for _ in range(len(a))]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('equal priority stable', solve([[1, 'z'], [1, 'a'], [0, 'm']]), ['m', 'z', 'a'])\ncheck('priority dominates arrival', solve([[2, 'a'], [1, 'b']]), ['b', 'a'])\ncheck('empty', solve([]), [])\ncheck('singleton', solve([[1, 'a']]), ['a'])\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":"xr-heap-priority-ties-use-arrival-order","generated_at":"2026-09-29T14:37:43.234799+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"A controlled local-runtime regression for collection APIs, language semantics, or ownership wrappers. Fixtures include boundary and interaction cases.","root_cause":"The payload label becomes an accidental lexical tie breaker.","sha256":"44b0c60c30c20813a627bb09248d960ddd69cfbd59ba02b6750a2aacf9132d9a","title":"Heap priority ties use arrival order · case 01","variant":1,"variant_policy":"Five execution reruns of a fixed adversarial fixture suite; variant number does not alter semantic inputs.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":41.7,"exit_code":1,"observations":[{"actual":["z","a","m"],"check":"equal priority stable","expected":["m","z","a"],"passed":false},{"actual":["a","b"],"check":"priority dominates arrival","expected":["b","a"],"passed":false},{"actual":[],"check":"empty","expected":[],"passed":true},{"actual":["a"],"check":"singleton","expected":["a"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"equal priority stable\", \"actual\": [\"z\", \"a\", \"m\"], \"expected\": [\"m\", \"z\", \"a\"], \"passed\": false}, {\"check\": \"priority dominates arrival\", \"actual\": [\"a\", \"b\"], \"expected\": [\"b\", \"a\"], \"passed\": false}, {\"check\": \"empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"singleton\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":37.13,"exit_code":1,"observations":[{"actual":["m","a","z"],"check":"equal priority stable","expected":["m","z","a"],"passed":false},{"actual":["b","a"],"check":"priority dominates arrival","expected":["b","a"],"passed":true},{"actual":[],"check":"empty","expected":[],"passed":true},{"actual":["a"],"check":"singleton","expected":["a"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"equal priority stable\", \"actual\": [\"m\", \"a\", \"z\"], \"expected\": [\"m\", \"z\", \"a\"], \"passed\": false}, {\"check\": \"priority dominates arrival\", \"actual\": [\"b\", \"a\"], \"expected\": [\"b\", \"a\"], \"passed\": true}, {\"check\": \"empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"singleton\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"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."}}