{"abstract":"Nested retry logic spends a child budget and amplifies attempts","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=stack[1] if len(stack)>1 else stack[0] but still violates a regression oracle.","family":"s3-http_retries-nested-ownership-owner","id":"FA-29501","implementations":{"attempt":{"sha256":"680fe58c0e6fc697e37056e744c9e8d0ffcb6b3c48d7c059ab3c404bf17401f1","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[1] if len(stack)>1 else 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"},"broken":{"sha256":"de1553f93fd98912c8424d83c71dc1752fdfe73e5b3578b572f7be4a1a126590","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[-1]\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-owner","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":"Nested retry logic spends a child budget and amplifies attempts","sha256":"1d9ee975119922f1611b2df94440250d7b808882652ae31ab88e0341994fcd14","title":"Nested client retry ownership: Nested retry logic spends a child budget and amplifies attempts · 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":43.463,"exit_code":1,"observations":[{"actual":[[],[]],"check":"0","expected":[[],[]],"passed":true},{"actual":[[["unowned",null]],[]],"check":"1","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["retry","inner"],["retry","inner"],["retry","inner"]],[["outer",2,0],["inner",9,3]]],"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\", \"inner\"], [\"retry\", \"inner\"], [\"retry\", \"inner\"]], [[\"outer\", 2, 0], [\"inner\", 9, 3]]], \"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"},"broken":{"elapsed_ms":42.665,"exit_code":1,"observations":[{"actual":[[],[]],"check":"0","expected":[[],[]],"passed":true},{"actual":[[["unowned",null]],[]],"check":"1","expected":[[["unowned",null]],[]],"passed":true},{"actual":[[["retry","inner"],["retry","inner"],["retry","inner"]],[["outer",2,0],["inner",9,3]]],"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\", \"inner\"], [\"retry\", \"inner\"], [\"retry\", \"inner\"]], [[\"outer\", 2, 0], [\"inner\", 9, 3]]], \"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."}}