Repository navigation
test(moq-audio): replay the subscription budget trace natively, finishing audio playout - #9475
Conversation
Quest-Claim: 376b485e527f9c57
…ive decode path Finishes the audio playout epic: moq play's budget lands every flush whole and measures the browser's target series; a budget that only follows the delay drops the flush it should measure. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 37 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
There was a problem hiding this comment.
✅ No new issues found.
Approach: sound. The PR replays the browser's subscription-budget trace through the native Consumer and checks it against the native estimator fed directly. Because the conformance corpus already holds both estimators to one reference, this closes the native gap without adding a duplicate fixture.
Reviewed changes
Reviewed the full diff: the two native decode-path tests and the quest-doc cleanup that finishes the epic.
- Native trace replay:
flushes()reproducestrace(300, 6, 0)exactly. That is 3000 paced packets at +50 ms, then each run of six shares the arrival of its last packet.budgetreads every packet up to the newest of each arrival before it samplesconsumer.delay(). - Reach budget test:
(delay + 2s).max(2s)matchesmoq play'sseen.saturating_add(REACH).max(floor)inrs/moq-cli/src/play/media.rs. The test asserts the browser's three checks, and also that the series equalsjitter::Targetfed every arrival directly. - Counter-case: a budget that follows the delay drops packets and stays under 120 ms at onset, so the positive test can't pass vacuously.
- Quest cleanup: deletes
quest/m2/audio-playout/README.md. No references to it remain. Links now point atdoc/concept/audio-jitter.mdor #9475, andaudio-calibratedrops itsRequiredentry.
claude-opus-5-5 | 𝕏

Claims quest/m2/audio-playout/README.md and finishes the epic.
Closes #2812
Problem
The epic's last owed item: the browser's
playout.test.ts"subscription budget" trace replayed through the native decode path too, asserting the same target series. Without it nothing showsmoq play's subscription reaches a flush that starts after the target settled at its floor, rather than skipping the oldest packets of each flush before the estimator sees them.Approach
Two tests in
rs/moq-audio/src/decode/consumer.rsreplay the same trace (a minute of 20 ms packets over a 50 ms path, then six seconds flushed six at a time) throughConsumer, one PCM packet per group, every packet of an arrival landing before any is read:the_subscription_reaches_a_flush_that_starts_after_the_target_settled:moq play's budget (delay plus the 2 s reach, floored at the 2 s it opens with). Asserts the browser's checks (40 ms at the end of the paced minute, every packet decoded, the first twenty flushes reaching at least 120 ms) and that the series equals the estimator fed every arrival directly.a_budget_following_the_delay_drops_the_flush_it_should_measure: the counter-case, max delay following the delay, drops packets and stays under 120 ms, so the first test cannot pass vacuously.The epic's README is deleted and its links updated:
audio-calibrateloses itsRequired(its wait now names this PR), the playout-library and bufferbloat quests point atdoc/concept/audio-jitter.md, and Nightly's README drops the stale note that the audio near-zero p95 row belongs to this epic (Audio quality passed on the 11-20, 11-21 and 11-22 scheduled Nightlies).Impact
None: tests and quest files only. No public API or wire change.
Validation
cargo test -p moq-audio --lib: 292 passed.just checkandjust cipass.40 ... 40, 140 ...across the onset. The counter-case matches too: 3248 of 3300 packets delivered and an onset of 80 ms on both.Decisions
playout.test.ts's subscription-budget trace, which the line names. The corpus's recordedjoin/skippedcases are already covered natively by the estimator corpus test and the join-backlog decode-path tests from feat(hang,moq-mux,moq-audio): both consumers report the join's backlog they skip #8761.Closes #2812: the quest'sClosesnamed it for when the epic finishes.Follow-ups
None.
Models
Size: M
Implementer: Claude Code, claude-opus-5-5, unknown effort
Review
Rewritten by
quest reviewafter each round.Head: be27331
Base: origin/main at 1767f6d
Risk: low,
Nothing a consumer or peer relies on changes: the Rust change adds only `#[cfg(test)]` tests in `rs/moq-audio/src/decode/consumer.rs`, the JS change adds one comment in a test file, and the rest rewrites or deletes quest plan docs, which RISK.md lists as low; if something breaks, it is a failing test or a stale doc link, and a revert undoes all of it.Classified: low by Claude Code, claude-haiku-5-5, low effort, session
9e85f34d-a612-429d-b0d9-d733142455a5Reviewer: Codex, gpt-6.1-sol, high effort
Session:
01a208cd-6de8-7e82-b8cc-bda82aaec149, round 1Score: 9/10,
No actionable defects were found by source review; builds and tests were not run as requested.Rounds: 1; first round 0; findings 0: fixed 0, refuted 0, open 0
Findings: none