FA-49391 / PCM sample encoding / Open access
Pcm silence run packets: silence code · case 01
Silence runs use integer zero despite an explicit unsigned PCM zero code.
ROOT CAUSE
Silence runs use integer zero despite an explicit unsigned PCM zero code.
THE FAILURE
Silence runs use integer zero despite an explicit unsigned PCM zero code.
Unsuccessful approach: Holding the last amplitude creates a DC segment instead of silence.
Case contract
Decode tagged PCM literal and silence-run packets up to a sample capacity, honoring the declared digital-silence code and skipping unknown metadata.
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(packets, zero, limit):
out=[]
for tag,payload in packets:
if tag=='audio':
out.extend(payload)
elif tag=='silence':
out.extend([0]*max(0,payload))
else:
continue
if len(out)>=limit:
out=out[:limit]
break
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 8)), [130, 131, 128, 128, 129])
check('oracle 2', solve(*([['silence', 0], ['audio', [5]]], 128, 5)), [5])
check('oracle 3', solve(*([['metadata', []], ['audio', [1, 2]]], 0, 4)), [1, 2])
check('oracle 4', solve(*([['audio', [1, 2, 3]], ['silence', 2]], 0, 2)), [1, 2])
check('oracle 5', solve(*([], 128, 5)), [])
check('oracle 6', solve(*([['silence', -1], ['silence', 2]], 128, 3)), [128, 128])
check('oracle 7', solve(*([['audio', [1]], ['audio', [2]]], 0, 0)), [])
if N == 1: check('variant packet 1', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 16]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 2: check('variant packet 2', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 24]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 3: check('variant packet 3', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 32]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 4: check('variant packet 4', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 40]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 5: check('variant packet 5', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 48]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
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 | [130, 131, 0, 0, 129] | [130, 131, 128, 128, 129] | Failed |
| oracle 2 | [5] | [5] | Passed |
| oracle 3 | [1, 2] | [1, 2] | Passed |
| oracle 4 | [1, 2] | [1, 2] | Passed |
| oracle 5 | [] | [] | Passed |
| oracle 6 | [0, 0] | [128, 128] | Failed |
| oracle 7 | [] | [] | Passed |
| variant packet 1 | [130, 131, 0, 0, 129, 130, 131, 0, 0, 129] | [130, 131, 128, 128, 129, 130, 131, 128, 128, 129] | Failed |
SHA-256 / ab2db2b0930cb9edc2251ec97cad7d20bd126a5312f0920cfda928bd85ef66b4
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(packets, zero, limit):
out=[]
for tag,payload in packets:
if tag=='audio':
out.extend(payload)
elif tag=='silence':
out.extend([out[-1] if out else zero]*max(0,payload))
else:
continue
if len(out)>=limit:
out=out[:limit]
break
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 8)), [130, 131, 128, 128, 129])
check('oracle 2', solve(*([['silence', 0], ['audio', [5]]], 128, 5)), [5])
check('oracle 3', solve(*([['metadata', []], ['audio', [1, 2]]], 0, 4)), [1, 2])
check('oracle 4', solve(*([['audio', [1, 2, 3]], ['silence', 2]], 0, 2)), [1, 2])
check('oracle 5', solve(*([], 128, 5)), [])
check('oracle 6', solve(*([['silence', -1], ['silence', 2]], 128, 3)), [128, 128])
check('oracle 7', solve(*([['audio', [1]], ['audio', [2]]], 0, 0)), [])
if N == 1: check('variant packet 1', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 16]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 2: check('variant packet 2', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 24]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 3: check('variant packet 3', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 32]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 4: check('variant packet 4', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 40]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
if N == 5: check('variant packet 5', solve(*[[['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]], ['audio', [130, 131]], ['silence', 2], ['audio', [129]]], 128, 48]), [130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129, 130, 131, 128, 128, 129])
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 | [130, 131, 131, 131, 129] | [130, 131, 128, 128, 129] | Failed |
| oracle 2 | [5] | [5] | Passed |
| oracle 3 | [1, 2] | [1, 2] | Passed |
| oracle 4 | [1, 2] | [1, 2] | Passed |
| oracle 5 | [] | [] | Passed |
| oracle 6 | [128, 128] | [128, 128] | Passed |
| oracle 7 | [] | [] | Passed |
| variant packet 1 | [130, 131, 131, 131, 129, 130, 131, 131, 131, 129] | [130, 131, 128, 128, 129, 130, 131, 128, 128, 129] | Failed |
SHA-256 / 9a8cc524d60dd1ae439b26c867787d1e1385e760e2ea9ac159f9e96ae8a68e43
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 8 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗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:44:59.738462+00:00.
Case digest / 5e1b81f8279dce1d818c1391e8d9cc68f3cf2dfd6b7fabb8ac5dbe33d84f7b32