{"abstract":"Appending in download completion order corrupts segment byte order.","category":"Streaming segment lifecycle","checks":4,"contract":"Assemble nonoverlapping contiguous downloaded byte chunks supplied in arbitrary completion order, ordered by their absolute byte offsets. Coverage validity is prevalidated.","evaluation_group":"xmed-download-chunks-offset-assembly","failed_approach":"Sorting byte payloads instead of offsets also corrupts assembly.","family":"xmed-download-chunks-offset-assembly","id":"FA-11146","implementations":{"attempt":{"sha256":"03a2c348b0e591d38e0757efa7158bcfeabf554b990b0dd87388148ec2690216","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(chunks):\n    return [byte for offset,data in sorted(chunks,key=lambda x:x[1]) for byte in data]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1',solve(*([[2, [1, 2]], [0, [8, 9]]],)),[8, 9, 1, 2])\ncheck('fixture 2',solve(*([[0, [3]]],)),[3])\ncheck('fixture 3',solve(*([],)),[])\ncheck('fixture 4',solve(*([[1, [0]], [0, [9]]],)),[9, 0])\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":"bcbcc17232cec1d9e2675bd0eb7b5eed3165236959e300643b9450c2cd2d3b80","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(chunks):\n    return [byte for offset,data in chunks for byte in data]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1',solve(*([[2, [1, 2]], [0, [8, 9]]],)),[8, 9, 1, 2])\ncheck('fixture 2',solve(*([[0, [3]]],)),[3])\ncheck('fixture 3',solve(*([],)),[])\ncheck('fixture 4',solve(*([[1, [0]], [0, [9]]],)),[9, 0])\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":"443b92e845b02c53136cd505d7c203ac4d13ac37df77c60882d113dbbf270d8c","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(chunks):\n    return [byte for offset,data in sorted(chunks,key=lambda x:x[0]) for byte in data]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('fixture 1',solve(*([[2, [1, 2]], [0, [8, 9]]],)),[8, 9, 1, 2])\ncheck('fixture 2',solve(*([[0, [3]]],)),[3])\ncheck('fixture 3',solve(*([],)),[])\ncheck('fixture 4',solve(*([[1, [0]], [0, [9]]],)),[9, 0])\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":"xmed-download-chunks-offset-assembly","generated_at":"2026-09-29T14:38:45.397883+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"A deterministic local media controller stage; metadata and downloaded data are supplied explicitly. No external player, service or codec is required.","repair":"Preserve the media contract: Assemble nonoverlapping contiguous downloaded byte chunks supplied in arbitrary completion order, ordered by their absolute byte offsets. Coverage validity is prevalidated.","root_cause":"Appending in download completion order corrupts segment byte order.","sha256":"0b6b88f47e361ccf25fce8d294a48bcf00b4655c24c81ffb91513e535c4cd3ba","title":"Download chunks offset assembly · 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":39.394,"exit_code":1,"observations":[{"actual":[1,2,8,9],"check":"fixture 1","expected":[8,9,1,2],"passed":false},{"actual":[3],"check":"fixture 2","expected":[3],"passed":true},{"actual":[],"check":"fixture 3","expected":[],"passed":true},{"actual":[0,9],"check":"fixture 4","expected":[9,0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1\", \"actual\": [1, 2, 8, 9], \"expected\": [8, 9, 1, 2], \"passed\": false}, {\"check\": \"fixture 2\", \"actual\": [3], \"expected\": [3], \"passed\": true}, {\"check\": \"fixture 3\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"fixture 4\", \"actual\": [0, 9], \"expected\": [9, 0], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":38.863,"exit_code":1,"observations":[{"actual":[1,2,8,9],"check":"fixture 1","expected":[8,9,1,2],"passed":false},{"actual":[3],"check":"fixture 2","expected":[3],"passed":true},{"actual":[],"check":"fixture 3","expected":[],"passed":true},{"actual":[0,9],"check":"fixture 4","expected":[9,0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1\", \"actual\": [1, 2, 8, 9], \"expected\": [8, 9, 1, 2], \"passed\": false}, {\"check\": \"fixture 2\", \"actual\": [3], \"expected\": [3], \"passed\": true}, {\"check\": \"fixture 3\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"fixture 4\", \"actual\": [0, 9], \"expected\": [9, 0], \"passed\": false}], \"passed\": false}\n"},"fixed":{"elapsed_ms":39.725,"exit_code":0,"observations":[{"actual":[8,9,1,2],"check":"fixture 1","expected":[8,9,1,2],"passed":true},{"actual":[3],"check":"fixture 2","expected":[3],"passed":true},{"actual":[],"check":"fixture 3","expected":[],"passed":true},{"actual":[9,0],"check":"fixture 4","expected":[9,0],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"fixture 1\", \"actual\": [8, 9, 1, 2], \"expected\": [8, 9, 1, 2], \"passed\": true}, {\"check\": \"fixture 2\", \"actual\": [3], \"expected\": [3], \"passed\": true}, {\"check\": \"fixture 3\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"fixture 4\", \"actual\": [9, 0], \"expected\": [9, 0], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}