Skip to content

chore(quest): plan the transcode ladder and audio gap quests - #3347

Merged
kixelated merged 2 commits into
mainfrom
quest/replan-video
Sep 2, 2026
Merged

chore(quest): plan the transcode ladder and audio gap quests#3347
kixelated merged 2 commits into
mainfrom
quest/replan-video

Conversation

@kixelated

Copy link
Copy Markdown
Collaborator

Replans the capture/transcode/audio quests in m0 and retires one.

Part of a per-cluster replan of quest/m0: every issue-imported quest had the boilerplate "implement what the issue says" goal with the issue body pasted as the plan. Each quest now states its observable outcome and the decisions taken, and drops the pasted body.

🤖 Generated with Claude Code

(written by Claude Fable 5.1)

@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 9 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 4 included reviews currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 889a398c-d293-46ea-8d90-1e50764725af

📥 Commits

Reviewing files that changed from the base of the PR and between 43f4eec and c28f63c.

📒 Files selected for processing (4)
  • quest/m0/2788-moq-transcode-run-cant-bootstrap-from-a-demand-gated.md
  • quest/m0/2799-moq-video-capture-negotiates-twice-so-a-window-resize.md
  • quest/m0/2981-moq-audio-nothing-in-the-decode-or-playback-path-models-a.md
  • quest/m0/README.md

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 2, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-02T20:43:05.864736Z c28f63c New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ce062b0b18

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +29 to +30
the new ones, keep the rest. A subscriber on a retired rung sees its track
end and picks another rendition, the same as any rendition change.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve native playback when retiring a rung

When the retired rung is being consumed by native moq play, the subscriber does not pick another rendition: rs/moq-cli/src/play.rs:248 stops polling catalog updates after video and audio have started, and video_started is never cleared when play_video exits. Ending the rung therefore ends playback or leaves an audio-only session instead of switching, so the plan must include consumer reselection or use a retirement mechanism that preserves the subscribed track.

AGENTS.md reference: quest/AGENTS.md:L39-L45

Useful? React with 👍 / 👎.

Comment on lines +34 to +36
- One stated policy in `decode::Consumer`: a jump counts as a gap when it
exceeds one codec frame duration at the track timescale, derived from the
frame size and timescale rather than a constant.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Detect a gap of exactly one codec frame

Because the preceding text proposes comparing an incoming timestamp with the tracked tail, one missing 1024-sample AAC packet produces a discrepancy of exactly one codec-frame duration, not more than one. The stated exceeds threshold would therefore splice the planned 0 then 2048 regression case instead of detecting its hole, directly contradicting the test at lines 44-45; define the rounding tolerance separately so a one-frame loss still counts as a gap.

AGENTS.md reference: quest/AGENTS.md:L39-L45

Useful? React with 👍 / 👎.

kixelated and others added 2 commits September 2, 2026 13:35
…the bootstrap one

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@kixelated
kixelated enabled auto-merge (squash) September 2, 2026 20:37
@kixelated
kixelated merged commit 40ddb7e into main Sep 2, 2026
2 checks passed
@kixelated
kixelated deleted the quest/replan-video branch September 2, 2026 20:41

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c28f63ca46

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +45 to +46
- `encode::Producer` subtracts the resampler's skipped frames from its epoch
so the first published frame is stamped where its input was.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep the producer epoch at the first input timestamp

Resampler::process already removes the artificial startup silence, and flush restores the delayed tail, while encode::Producer anchors once to the first input timestamp and advances by emitted sample count. There is therefore no fixed delay to subtract from the producer epoch; skipped() is needed by decode::Consumer only because it reconstructs each output batch's time from a later packet timestamp. Implementing this step would shift every nonzero epoch early, and the proposed first-PTS test already passes without the change.

AGENTS.md reference: quest/AGENTS.md:L43-L45

Useful? React with 👍 / 👎.

Comment on lines +34 to +36
- One stated policy in `decode::Consumer`: a packet counts as discontinuous
when its timestamp differs from the tracked tail by more than half a codec
frame at the track timescale, derived from the frame size and timescale

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Detect gaps shorter than adjacent codec frames

The fresh half-frame correction still misses valid variable-duration audio: after a 20 ms packet, losing a 2.5 ms Opus packet puts the next timestamp only 2.5 ms past the tracked tail, below a 10 ms tolerance derived from either neighboring 20 ms packet, so the resampler still splices across the loss. Opus permits multiple packet durations and PCM packets can also vary, with no fixed frame duration in the catalog, so base the tolerance on timestamp quantization or otherwise ensure the shortest supported missing packet is detected.

AGENTS.md reference: quest/AGENTS.md:L43-L45

Useful? React with 👍 / 👎.

Comment on lines +35 to +37
- Test: a source that republishes its rendition at a new size; assert the
ladder changes, passthrough follows, and a subscriber on a retired rung is
ended cleanly.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Add a regression test for native rung reselection

Fresh evidence in this revision is the new requirement to re-arm moq play, but this test still verifies only ladder mutation, passthrough, and termination of the retired subscription. Those assertions would pass while video_started remains set and native playback never subscribes to the replacement rung, so the quest needs a test that completes the active native video task and confirms a later catalog snapshot starts the replacement track.

AGENTS.md reference: AGENTS.md:L152-L152

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

moq-transcode: run() can't bootstrap from a demand-gated source that doesn't advertise its geometry

1 participant