FA-50041 / PCM sample encoding / Open access
Pcm channel status block: start resynchronization · case 01
A new status-block start does not terminate the partial prior PCM block.
ROOT CAUSE
A new status-block start does not terminate the partial prior PCM block.
VERIFIED REPAIR
Use the stated conversion contract at start resynchronization.
Unsuccessful approach: Only honoring start on an empty buffer also misses mid-block resynchronization.
Case contract
Group stipulated audio subframes into fixed-size channel-status blocks, preserving PCM samples and one status bit; a new start marks prior partial data incomplete.
Why this case matters
Offline PCM interchange uses these exact bounded packet and sample representation decisions.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(subframes, block_length):
blocks=[]
current=[]
for start,audio,status in subframes:
if False:
if current:
blocks.append([current,False])
current=[]
current.append([audio,status&1])
if len(current)==block_length:
blocks.append([current,True])
current=[]
return [blocks,current]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[True, 1, 3], [False, 2, 0], [False, 3, 1]], 3)), [[[[[1, 1], [2, 0], [3, 1]], True]], []])
check('oracle 2', solve(*([[True, 1, 0], [True, 2, 1], [False, 3, 2]], 3)), [[[[[1, 0]], False]], [[2, 1], [3, 0]]])
check('oracle 3', solve(*([[False, 1, 1], [False, 2, 0], [False, 3, 1], [False, 4, 0]], 2)), [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []])
check('oracle 4', solve(*([], 3)), [[], []])
check('oracle 5', solve(*([[True, 1, 1]], 1)), [[[[[1, 1]], True]], []])
check('oracle 6', solve(*([[False, 1, 2]], 3)), [[], [[1, 0]]])
check('oracle 7', solve(*([[True, 1, 0], [False, 2, 1], [True, 3, 0]], 2)), [[[[[1, 0], [2, 1]], True]], [[3, 0]]])
if N == 1: check('variant packet 1', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 2: check('variant packet 2', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 3: check('variant packet 3', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 4: check('variant packet 4', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 5: check('variant packet 5', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| oracle 1 | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
| oracle 2 | [[[[[1, 0], [2, 1], [3, 0]], True]], []] | [[[[[1, 0]], False]], [[2, 1], [3, 0]]] | Failed |
| oracle 3 | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | Passed |
| oracle 4 | [[], []] | [[], []] | Passed |
| oracle 5 | [[[[[1, 1]], True]], []] | [[[[[1, 1]], True]], []] | Passed |
| oracle 6 | [[], [[1, 0]]] | [[], [[1, 0]]] | Passed |
| oracle 7 | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | Passed |
| variant packet 1 | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
SHA-256 / 55a51052f98d495b3067e760456542e437efc8af5079fdb40b1f37d93f484f20
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(subframes, block_length):
blocks=[]
current=[]
for start,audio,status in subframes:
if start and not current:
if current:
blocks.append([current,False])
current=[]
current.append([audio,status&1])
if len(current)==block_length:
blocks.append([current,True])
current=[]
return [blocks,current]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[True, 1, 3], [False, 2, 0], [False, 3, 1]], 3)), [[[[[1, 1], [2, 0], [3, 1]], True]], []])
check('oracle 2', solve(*([[True, 1, 0], [True, 2, 1], [False, 3, 2]], 3)), [[[[[1, 0]], False]], [[2, 1], [3, 0]]])
check('oracle 3', solve(*([[False, 1, 1], [False, 2, 0], [False, 3, 1], [False, 4, 0]], 2)), [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []])
check('oracle 4', solve(*([], 3)), [[], []])
check('oracle 5', solve(*([[True, 1, 1]], 1)), [[[[[1, 1]], True]], []])
check('oracle 6', solve(*([[False, 1, 2]], 3)), [[], [[1, 0]]])
check('oracle 7', solve(*([[True, 1, 0], [False, 2, 1], [True, 3, 0]], 2)), [[[[[1, 0], [2, 1]], True]], [[3, 0]]])
if N == 1: check('variant packet 1', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 2: check('variant packet 2', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 3: check('variant packet 3', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 4: check('variant packet 4', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 5: check('variant packet 5', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| oracle 1 | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
| oracle 2 | [[[[[1, 0], [2, 1], [3, 0]], True]], []] | [[[[[1, 0]], False]], [[2, 1], [3, 0]]] | Failed |
| oracle 3 | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | Passed |
| oracle 4 | [[], []] | [[], []] | Passed |
| oracle 5 | [[[[[1, 1]], True]], []] | [[[[[1, 1]], True]], []] | Passed |
| oracle 6 | [[], [[1, 0]]] | [[], [[1, 0]]] | Passed |
| oracle 7 | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | Passed |
| variant packet 1 | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
SHA-256 / eab4527bfb34753be2a75f4473d010bd10ed479eb7809e6247166b7185a91189
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(subframes, block_length):
blocks=[]
current=[]
for start,audio,status in subframes:
if start:
if current:
blocks.append([current,False])
current=[]
current.append([audio,status&1])
if len(current)==block_length:
blocks.append([current,True])
current=[]
return [blocks,current]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[True, 1, 3], [False, 2, 0], [False, 3, 1]], 3)), [[[[[1, 1], [2, 0], [3, 1]], True]], []])
check('oracle 2', solve(*([[True, 1, 0], [True, 2, 1], [False, 3, 2]], 3)), [[[[[1, 0]], False]], [[2, 1], [3, 0]]])
check('oracle 3', solve(*([[False, 1, 1], [False, 2, 0], [False, 3, 1], [False, 4, 0]], 2)), [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []])
check('oracle 4', solve(*([], 3)), [[], []])
check('oracle 5', solve(*([[True, 1, 1]], 1)), [[[[[1, 1]], True]], []])
check('oracle 6', solve(*([[False, 1, 2]], 3)), [[], [[1, 0]]])
check('oracle 7', solve(*([[True, 1, 0], [False, 2, 1], [True, 3, 0]], 2)), [[[[[1, 0], [2, 1]], True]], [[3, 0]]])
if N == 1: check('variant packet 1', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 2: check('variant packet 2', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 3: check('variant packet 3', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 4: check('variant packet 4', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
if N == 5: check('variant packet 5', solve(*[[[True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1], [True, 1, 3], [False, 2, 0], [False, 3, 1]], 3]), [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| oracle 1 | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
| oracle 2 | [[[[[1, 0]], False]], [[2, 1], [3, 0]]] | [[[[[1, 0]], False]], [[2, 1], [3, 0]]] | Passed |
| oracle 3 | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | [[[[[1, 1], [2, 0]], True], [[[3, 1], [4, 0]], True]], []] | Passed |
| oracle 4 | [[], []] | [[], []] | Passed |
| oracle 5 | [[[[[1, 1]], True]], []] | [[[[[1, 1]], True]], []] | Passed |
| oracle 6 | [[], [[1, 0]]] | [[], [[1, 0]]] | Passed |
| oracle 7 | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | [[[[[1, 0], [2, 1]], True]], [[3, 0]]] | Passed |
| variant packet 1 | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | [[[[[1, 1], [2, 0], [3, 1]], True], [[[1, 1], [2, 0], [3, 1]], True]], []] | Passed |
SHA-256 / c41b704bd8b43b25e554e943106b5f09fd1afc04f10dd4761e5e27b1e1318b8d
Verification & scope
Stipulated finite model; no claim of hardware timing or full file-format conformance. 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.
Observations recorded using Python 3.12.14 at 2026-09-29T14:45:05.469632+00:00.
Case digest / 3d0099bc722c7d56beea80b25dc0a532a5bb05bbba3cfba1ef4806ec0e76f600