{"abstract":"A retry consumes the wrong number of parent budget slots","category":"HTTP retries","checks":7,"contract":"enter(layer, allowance) pushes a retry scope. A child with any ancestor delegates retry to the oldest scope and never spends its local cap. fail returns retry/exhausted charged to oldest scope. leave pops the current scope; success clears every scope. Return decision pairs and remaining scope budgets.","contract_signature":"events","evaluation_group":"s3-http_retries-nested-ownership","failed_approach":"The attempted repair changes the faulty site to owner[2]+=2 but still violates a regression oracle.","family":"s3-http_retries-nested-ownership-charge","id":"FA-29511","implementations":{"attempt":{"sha256":"54b818ba2680090f5af61a03f39b692dbd1704b79a16bf82cde86b59eeb6ab1d","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(events):\n    stack=[]; out=[]\n    for e in events:\n        if e[0]=='enter':\n            stack.append([e[1],e[2],0])\n        elif e[0]=='leave':\n            if stack: stack.pop()\n        elif e[0]=='success':\n            stack.clear()\n        elif e[0]=='fail':\n            if not stack:\n                out.append(['unowned',None]); continue\n            owner=stack[0]\n            if owner[2]>=owner[1]:\n                out.append(['exhausted',owner[0]])\n            else:\n                owner[2]+=2\n                out.append(['retry',owner[0]])\n    return [out,stack]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('0', solve([]), [[],[]])\ncheck('1', solve([('fail',)]), [[['unowned',None]],[]])\ncheck('2', solve([('enter','outer',2),('enter','inner',9),('fail',),('fail',),('fail',)]), [[['retry','outer'],['retry','outer'],['exhausted','outer']],[['outer',2,2],['inner',9,0]]])\ncheck('3', solve([('enter','only',N),('fail',)]), [[['retry','only']],[['only',N,1]]])\ncheck('4', solve([('enter','outer',1),('enter','inner',1),('leave',),('fail',)]), [[['retry','outer']],[['outer',1,1]]])\ncheck('5', solve([('enter','a',0),('enter','b',N),('success',),('fail',)]), [[['unowned',None]],[]])\ncheck('6', solve([('enter','a',0),('fail',),('leave',),('leave',)]), [[['exhausted','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":"cea16a320815ad4617ead532e1b6a7805436631b6ebf89786aeaf558e65b525e","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(events):\n    stack=[]; out=[]\n    for e in events:\n        if e[0]=='enter':\n            stack.append([e[1],e[2],0])\n        elif e[0]=='leave':\n            if stack: stack.pop()\n        elif e[0]=='success':\n            stack.clear()\n        elif e[0]=='fail':\n            if not stack:\n                out.append(['unowned',None]); continue\n            owner=stack[0]\n            if owner[2]>=owner[1]:\n                out.append(['exhausted',owner[0]])\n            else:\n                owner[2]=1\n                out.append(['retry',owner[0]])\n    return [out,stack]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('0', solve([]), [[],[]])\ncheck('1', solve([('fail',)]), [[['unowned',None]],[]])\ncheck('2', solve([('enter','outer',2),('enter','inner',9),('fail',),('fail',),('fail',)]), [[['retry','outer'],['retry','outer'],['exhausted','outer']],[['outer',2,2],['inner',9,0]]])\ncheck('3', solve([('enter','only',N),('fail',)]), [[['retry','only']],[['only',N,1]]])\ncheck('4', solve([('enter','outer',1),('enter','inner',1),('leave',),('fail',)]), [[['retry','outer']],[['outer',1,1]]])\ncheck('5', solve([('enter','a',0),('enter','b',N),('success',),('fail',)]), [[['unowned',None]],[]])\ncheck('6', solve([('enter','a',0),('fail',),('leave',),('leave',)]), [[['exhausted','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":"Stipulated bounded simulator, not a complete HTTP implementation or a standards conformance claim. 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":"s3-http_retries-nested-ownership-charge","generated_at":"2026-09-29T14:41:44.112872+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Offline deterministic model of HTTP request retries.","root_cause":"A retry consumes the wrong number of parent budget slots","sha256":"687b2db445e14eb1e6b04f20d1ecb51d7334faa286d3dd686b491db68d133f07","title":"Nested client retry ownership: A retry consumes the wrong number of parent budget slots · 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":42.819,"exit_code":1,"observations":[{"actual":[[],[]],"check":"0","expected":[[],[]],"passed":true},{"actual":[[["unowned",null]],[]],"check":"1","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["retry","outer"],["exhausted","outer"],["exhausted","outer"]],[["outer",2,2],["inner",9,0]]],"check":"2","expected":[[["retry","outer"],["retry","outer"],["exhausted","outer"]],[["outer",2,2],["inner",9,0]]],"passed":false},{"actual":[[["retry","only"]],[["only",1,2]]],"check":"3","expected":[[["retry","only"]],[["only",1,1]]],"passed":false},{"actual":[[["retry","outer"]],[["outer",1,2]]],"check":"4","expected":[[["retry","outer"]],[["outer",1,1]]],"passed":false},{"actual":[[["unowned",null]],[]],"check":"5","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["exhausted","a"]],[]],"check":"6","expected":[[["exhausted","a"]],[]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"0\", \"actual\": [[], []], \"expected\": [[], []], \"passed\": true}, {\"check\": \"1\", \"actual\": [[[\"unowned\", null]], []], \"expected\": [[[\"unowned\", null]], []], \"passed\": true}, {\"check\": \"2\", \"actual\": [[[\"retry\", \"outer\"], [\"exhausted\", \"outer\"], [\"exhausted\", \"outer\"]], [[\"outer\", 2, 2], [\"inner\", 9, 0]]], \"expected\": [[[\"retry\", \"outer\"], [\"retry\", \"outer\"], [\"exhausted\", \"outer\"]], [[\"outer\", 2, 2], [\"inner\", 9, 0]]], \"passed\": false}, {\"check\": \"3\", \"actual\": [[[\"retry\", \"only\"]], [[\"only\", 1, 2]]], \"expected\": [[[\"retry\", \"only\"]], [[\"only\", 1, 1]]], \"passed\": false}, {\"check\": \"4\", \"actual\": [[[\"retry\", \"outer\"]], [[\"outer\", 1, 2]]], \"expected\": [[[\"retry\", \"outer\"]], [[\"outer\", 1, 1]]], \"passed\": false}, {\"check\": \"5\", \"actual\": [[[\"unowned\", null]], []], \"expected\": [[[\"unowned\", null]], []], \"passed\": true}, {\"check\": \"6\", \"actual\": [[[\"exhausted\", \"a\"]], []], \"expected\": [[[\"exhausted\", \"a\"]], []], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":42.256,"exit_code":1,"observations":[{"actual":[[],[]],"check":"0","expected":[[],[]],"passed":true},{"actual":[[["unowned",null]],[]],"check":"1","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["retry","outer"],["retry","outer"],["retry","outer"]],[["outer",2,1],["inner",9,0]]],"check":"2","expected":[[["retry","outer"],["retry","outer"],["exhausted","outer"]],[["outer",2,2],["inner",9,0]]],"passed":false},{"actual":[[["retry","only"]],[["only",1,1]]],"check":"3","expected":[[["retry","only"]],[["only",1,1]]],"passed":true},{"actual":[[["retry","outer"]],[["outer",1,1]]],"check":"4","expected":[[["retry","outer"]],[["outer",1,1]]],"passed":true},{"actual":[[["unowned",null]],[]],"check":"5","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["exhausted","a"]],[]],"check":"6","expected":[[["exhausted","a"]],[]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"0\", \"actual\": [[], []], \"expected\": [[], []], \"passed\": true}, {\"check\": \"1\", \"actual\": [[[\"unowned\", null]], []], \"expected\": [[[\"unowned\", null]], []], \"passed\": true}, {\"check\": \"2\", \"actual\": [[[\"retry\", \"outer\"], [\"retry\", \"outer\"], [\"retry\", \"outer\"]], [[\"outer\", 2, 1], [\"inner\", 9, 0]]], \"expected\": [[[\"retry\", \"outer\"], [\"retry\", \"outer\"], [\"exhausted\", \"outer\"]], [[\"outer\", 2, 2], [\"inner\", 9, 0]]], \"passed\": false}, {\"check\": \"3\", \"actual\": [[[\"retry\", \"only\"]], [[\"only\", 1, 1]]], \"expected\": [[[\"retry\", \"only\"]], [[\"only\", 1, 1]]], \"passed\": true}, {\"check\": \"4\", \"actual\": [[[\"retry\", \"outer\"]], [[\"outer\", 1, 1]]], \"expected\": [[[\"retry\", \"outer\"]], [[\"outer\", 1, 1]]], \"passed\": true}, {\"check\": \"5\", \"actual\": [[[\"unowned\", null]], []], \"expected\": [[[\"unowned\", null]], []], \"passed\": true}, {\"check\": \"6\", \"actual\": [[[\"exhausted\", \"a\"]], []], \"expected\": [[[\"exhausted\", \"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."}}