Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions quest/m0/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Published API or wire breaks still land on dev; each quest's Plan says so.
## Required

- [Packaged relay starts](/quest/m0/relay-systemd-unit.md) - the `.deb` and `.rpm` relay service starts instead of crash-looping on `--file`
- [quest check everywhere](/quest/m0/quest-check-everywhere.md) - `quest check` guards `main`, `dev`, and the line branches on push and PR, not only PRs into `main`
- [Wildcard](/quest/m0/wildcard/README.md) - a relay resolves subscriptions against advertised prefixes, a service claims the prefix it could serve and refuses the rest instead of enumerating broadcasts, and the browser player treats a covering claim as availability
- [Audio quality harness](/quest/m0/audio-quality-harness/README.md) - a browser playout latency regression fails a nightly run instead of arriving as a bug report, and its recorder supplies the jitter target's replay traces
- [Audio jitter target](/quest/m0/audio-jitter-target/README.md) - the audio playout target is a measured estimate of arrival timing in both languages, not a round-trip guess
Expand Down
6 changes: 6 additions & 0 deletions quest/m0/audio-quality-harness/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ sample rate, which is more than a merge gate should carry, and `nightly.yml`
already exists for exactly this trade. Budgets are keyed by the full row, since
each of those dimensions moves the expected floor.

The budgets checked in with the browser lane (#4426) were recorded locally.
Once the line lands, re-record `test/audio-quality/budgets.json` from the
nightly runner's first runs, since nightly only runs `main`'s code. Tightening
the auto rows belongs to the [jitter target's watch
quest](/quest/m0/audio-jitter-target/watch.md).

## Required

- [Browser](/quest/m0/audio-quality-harness/browser.md) - upstream the fork's harness, grade it against a budget, run it nightly
Expand Down
27 changes: 27 additions & 0 deletions quest/m0/quest-check-everywhere.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# [XS] quest check runs on every branch that carries quests

## Goal

`quest check` fails any push or PR that breaks quest structure on `main`,
`dev`, and the questline branches, not only PRs into `main`.

## Plan

- `dev` has no `quest` flake input and no `quest check` in its justfile;
#4428's main-into-dev sync brings both. After it lands, convert the
old-format quests on `dev` until `quest check` passes there.
- Line branches pin their own `quest` revision (the wildcard line pinned
46d7fe8 against main's 8590d2a), so an old pin passes an old format.
Merging `main` into each active line bumps the pin; do that for the lines
that fail today and fix what the new check reports.
- `just ci check` runs `quest check` on pull requests only. Also run it on
push to `main`, `dev`, and `quest/**`, so a direct merge commit (such as
`main` merged into a line) can't land a broken tree. Use a dedicated job
that runs `quest check` unconditionally: `check.yml`'s scope steps diff
against `origin/$GITHUB_BASE_REF`, which is empty on a push.

Public API: none. Wire: none.

## Required

- #4428 merged to `dev`
7 changes: 7 additions & 0 deletions quest/m1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ transport, benchmark tooling); worktrees isolate commits, not semantics.

- [Late joiner history](/quest/m1/relay-late-joiner-history.md) - a subscriber joining a relay's track from group 0 later still receives the cached finished group below the live one
- [Cluster routing](/quest/m1/cluster-routing.md) - an announcement says where a broadcast originates, not how to reach it, and a relay hears only the prefixes its clients asked for
- [Exact scope](/quest/m1/exact-scope.md) - a reader never sees an exact broadcast outside its scope, in Rust or JS; prefix routes above it still present as the empty path
- [Track tail interop](/quest/m1/track-tail-interop.md) - a Rust publisher ending a track with a group in flight is read to its end by the JS subscriber, and the reverse, in `just test interop`
- [Worker socket count](/quest/m1/worker-socket-count.md) - the moq-tokio worker test counts only its own listener's sockets
- [Binding audio delay](/quest/m1/binding-surface.md) - moq-ffi and every wrapper configure and observe audio playout delay
Expand All @@ -37,6 +38,7 @@ transport, benchmark tooling); worktrees isolate commits, not semantics.
- [Splice edge cases](/quest/m1/splice-edges.md) - an unstamped successor, a pruned segment's boundary group, and a warm head during a takeover are each handled correctly
- [Resumed groups](/quest/m1/resume-latest.md) - a half-delivered group ends once the new copy is past it, so a group-only reader never parks after a mid-group failover
- [Track tail hardening](/quest/m1/track-tail-hardening.md) - Rust and JS wait out a track's tail by the same rules, with the known hang, count, truncation, grace, and memory holes closed
- [JS close end](/quest/m1/js-track-close-end.md) - a JS track's clean close ends at its own last group, not a sibling producer's
- [SUBSCRIBE_DROP](/quest/m1/subscribe-drop.md) - every stream group in a lite subscription arrives or is dropped by name, and lite-07 drops its stream count for it
- [FIN wait expiry](/quest/m1/fin-wait-expiry.md) - a group awaiting its FIN ack still expires and follows priority updates on lite and IETF
- [Cross-relay bursts](/quest/m1/cross-relay-bursts.md) - bursty small-group tracks cross two relays without lost groups, unanswered FETCHes, or stalls
Expand All @@ -46,11 +48,13 @@ transport, benchmark tooling); worktrees isolate commits, not semantics.
- [Watch audio under CSP](/quest/m1/watch-worklet-file.md) - production builds ship the audio worklet as a file, so `script-src 'self'` pages play audio
- [moqsrc stop](/quest/m1/moqsrc-stop.md) - moqsrc's stop blocks until its session ends, without deadlocking on a blocked pad push
- [More tests under load](/quest/m1/test-flakes-2.md) - the second round of load-only failures, fixed at the cause
- [Interop audio cold start](/quest/m1/interop-audio-cold-start.md) - the interop audio tone check stops failing on cold start, fixed at its cause
- [Auth outage clock](/quest/m1/auth-outage-clock.md) - the relay and moq-auth outage tests run on a paused clock again and assert both bounds of `expires`
- [Legacy end overshoot](/quest/m1/legacy-end-overshoot.md) - browser playback survives a group that starts inside the previous group's estimated end
- [Slow group log](/quest/m1/slow-group-log.md) - a starved viewer reports skipped groups once per catch-up, not once per group
- [UnknownSession log flood](/quest/m1/unknown-session-logs.md) - streams reset before their WebTransport header stop being reported as UnknownSession at WARN
- [Merge queue](/quest/m1/merge-queue.md) - the required checks run on `merge_group`, so a stale green check can no longer break main
- [CI hygiene](/quest/m1/ci-hygiene.md) - a push to one PR never cancels another's run, and a failed run never saves the Rust cache
- [Wire compatibility](/quest/m1/wire-compat.md) - a nightly run tests this checkout against the last published release for tokens, session wire, and catalog/container
- [#2075](/quest/m1/2075-mirror-catalog-reservation-gating-in-moq-hang-js-hang.md) - @moq/publish gates the first catalog snapshot until every reserved track is described
- [Full codec string](/quest/m1/publish-codec-string.md) - browser-published video carries the encoder's full RFC 6381 codec string, so native players decode it
Expand All @@ -76,6 +80,7 @@ transport, benchmark tooling); worktrees isolate commits, not semantics.
- [JS IETF datagrams](/quest/m1/js-ietf-datagram.md) - `@moq/net` sends and receives datagram groups over moq-transport, like Rust
- [#2991](/quest/m1/2991-net-coalesce-dynamic-tracks-and-preserve-sequences-across.md) - one dynamic producer per track name in both languages, with the sequence namespace surviving a replacement
- [JavaScript FETCH](/quest/m1/js-fetch.md) - generic on-demand group serving and IETF FETCH for browser publishers
- [JS fetch cancel](/quest/m1/js-fetch-cancel.md) - `FetchGroupOptions.signal` abandons one pending fetch without closing the track
- [Archive](/quest/m1/archive/README.md) - record selected tracks to any object_store and replay them over FETCH or derived HLS; the catalog entry and format may break in place, since no archives exist
- [Tooling](/quest/m1/tooling/README.md) - justfiles become a one-line menu over `sh/`, one impact map scopes CI, and every workflow step runs a recipe
- [Path patterns](/quest/m1/path-patterns.md) - one matcher for every predicate over broadcast paths: tokens, origins, interest
Expand Down Expand Up @@ -131,10 +136,12 @@ transport, benchmark tooling); worktrees isolate commits, not semantics.
- [Plan: cache age-out](/quest/m1/cache-wall-eviction.md) - a swept benchmark decides whether the track cache ages groups out on wall time without a write
- [Frame slot charge](/quest/m1/frame-slot-charge.md) - a group's frame slots past the first four count against the cache pool, including capacity a released group keeps
- [Relay memory](/quest/m1/relay-memory.md) - remeasure what an announcement costs after prefix routes
- [Front deadlines](/quest/m1/front-deadline-index.md) - a front's per-event cost stops growing with its track count: an expiry index and per-track wakes, proven by a churn benchmark
- [Front parking](/quest/m1/origin-front-parks.md) - an unroutable request waits on a front instead of re-asking on every route-table move
- [Publish channel count](/quest/m1/publish-audio-channel-count.md) - forcing a channel count on an Audio.Capture stops costing the subscriber gaps of silence
- [JS abandonment](/quest/m1/js-subscribe-abandonment.md) - a viewer returning during IETF subscribe setup keeps its track across microtasks
- [IETF stream types](/quest/m1/ietf-uni-stream-types.md) - padding streams are discarded stream-only and an unknown uni type closes the session, per draft-21
- [Rust decode caps](/quest/m1/coding-reader-cap.md) - every Rust decode that allocates from a peer-supplied length is bounded
- [Epoch primitive](/quest/m1/epoch.md) - one `Epoch` type in moq-net and @moq/net, carried as a trailing `@<uuidv7>` path segment, shared by e2ee and broadcast epochs
- [E2EE](/quest/m1/e2ee/README.md) - TypeScript and Rust peers interoperate over encrypted broadcasts no relay can decrypt
- [Broadcast epochs](/quest/m1/broadcast-epoch/README.md) - each publish of a name gets a fresh `@<uuidv7>` epoch, viewers follow the newest live one at once, and bare names still resolve on every version
Expand Down
25 changes: 25 additions & 0 deletions quest/m1/ci-hygiene.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# [XS] CI runs don't cancel each other or cache a broken build

## Goal

A push to one PR never cancels another PR's run, and a failed run never
saves the Rust cache later runs restore.

## Plan

- Concurrency: `check.yml`, `obs.yml`, `android.yml`, `wasm.yml`, and
`interop.yml` group by `${{ github.ref }}` only. Key them by event and PR
number the way `platform.yml` does (#4370). A `pull_request` run's
`github.ref` is already `refs/pull/<n>/merge`, so first find which runs
actually shared a group, and confirm the new key separates them.
- Cache: `interop.yml` and `swift.yml` set Swatinem's
`cache-on-failure: true`; #4384's interop cache got saved broken that way
(`failed to run custom build command for aws-lc-rs`). Drop it. Check
whether the shared `.github/actions/rust-cache` saves on failure, and make
it save only on success.

Public API: none. Wire: none.

## Related

- [Merge queue](/quest/m1/merge-queue.md) - also touches the concurrency groups for queue refs
21 changes: 21 additions & 0 deletions quest/m1/coding-reader-cap.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# [XS] Rust decoders cap a bare byte or string read

## Goal

Every Rust decode path that allocates from a peer-supplied length has an
upper bound. #4373 fixed a JS size-cap bypass; the lite and IETF message
decoders in Rust already check every length prefix, but `coding/reader.rs`
has no overall cap for a bare `Vec<u8>` or `String` decode.

## Plan

- Audit `rs/moq-net/src/coding/` for decodes that allocate from a length
prefix without a bound, and list which call sites reach them from the
wire.
- Where one is reachable, bound it by the message's size limit and refuse
anything larger with a decode error. If none is reachable, add the bound
anyway only if it's one line; otherwise delete this quest with the audit
in the PR.

Public API: none. Wire: oversized fields are refused, which they already
should be.
24 changes: 24 additions & 0 deletions quest/m1/exact-scope.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# [S] An exact broadcast outside a reader's scope stays hidden

## Goal

A reader scoped to `/a/b` never sees an exact broadcast at `/a`, in Rust or
JS. A prefix advertisement at or above the scope still presents as the empty
path, because it may serve paths under the scope; an exact broadcast cannot.

## Plan

Decided 2026-09-28: exact match everywhere, aligning on the JS local view.

- Rust: `sync_cursor` in `rs/moq-net/src/model/origin.rs` admits an exact
entry by prefix overlap. Match exact entries against the reader's patterns
instead. `cursor_keeps_an_overlapping_prefix_above_its_scope` covers a
prefix route and stays.
- JS wire view: `Scope.projectRoutes` in `js/net/src/origin.ts` treats every
entry above the root as covering. Skip exact entries there, as `#listed`
already does with `candidate.exact ? pattern.matches(path)`.
- Add the same case to both languages' tests: an exact broadcast at `/a` and
a prefix route at `/a`, read through a `/a/b` scope, yield only the prefix.

Public API: none. Wire: a narrower reader receives fewer announcements; no
message changes.
34 changes: 34 additions & 0 deletions quest/m1/front-deadline-index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# [M] Front deadlines scale with the touched track

## Goal

A relay front's per-event cost no longer grows with the number of tracks it
holds. Today `front.rs` `next_deadline` scans every track to find the next
linger expiry, and `run_front`'s per-wake poll in `origin.rs` scans every
track too, so each event on one track costs O(tracks) and a broadcast that
churns track names pays O(tracks²). After this, finding the next expiry and
reacting to one track's event touch only that track.

## Plan

- Benchmark first, in `rs/moq-net/benches/origin.rs`: churn tracks through one
front, swept over tracks per front and readers per track, so today's slope
shows before the fix and the fix's flatness after.
- Keep parked tracks in an expiry index ordered by `since + linger` (a
`BTreeMap` or a heap with lazy deletion), updated on every
`Parked`/unparked transition, so `next_deadline` is its first entry and the
deadline sweep pops only what expired.
- Replace the driver's scan-every-track poll with per-track wakes, so an
event on one track polls that track.
- Keep the front's exhaustive walk test passing, and add a unit test that the
index agrees with a full scan across random transitions.
- Not in scope: kio's level-only demand, which lets a reader that comes and
goes between polls skip restarting the linger. It costs one extra source
request, so it doesn't justify a kio generation counter (decided
2026-09-28).

Public API: none. Wire: none.

## Related

- [Front parking](/quest/m1/origin-front-parks.md) - also changes what a front holds, and wants a churn benchmark over requesters
29 changes: 29 additions & 0 deletions quest/m1/interop-audio-cold-start.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# [S] Interop audio tone survives a cold start

## Goal

The interop "Media output and lifecycle" step stops failing the audio tone
check on cold start. The 2026-09-28 nightly on `main` failed with
`FAIL audio tone: cold start: 55/64 samples carried the fixture tone above the
noise floor`, against a 90% agreement floor.

## Plan

- Reproduce it: run the interop media step in a loop on a loaded machine
until the cold-start row fails, and capture which samples miss (the first
ones, or scattered).
- Find the cause before touching the check: the likely suspects are decoder
or playout warm-up after the context resumes. [Publish channel count](/quest/m1/publish-audio-channel-count.md)
saw the same symptom, but `test/interop/clients/js/src/fixture.ts` already
dropped the `channelCount` override, so that's not it.
- Fix it at the source. The cold-start window deliberately starts once the
context runs, without waiting for a tone, so a slow start has to fail
there. Keep that window: if the misses are the first samples, find what
delays the first audible output instead of moving the window. Don't lower
`AGREEMENT` (`test/interop/clients/js/media.ts`) without a measured reason.

Public API: none. Wire: none.

## Related

- [More tests under load](/quest/m1/test-flakes-2.md) - the other load-only failures
25 changes: 25 additions & 0 deletions quest/m1/js-fetch-cancel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# [S] A JS fetch can be cancelled

## Goal

A `@moq/net` caller can abandon one pending group fetch without closing the
track or session, the follow-up #4357 left.

## Plan

Decided 2026-09-28: `FetchGroupOptions` (`js/net/src/track.ts`) gains
`signal?: AbortSignal`, the standard JS idiom, and additive.

- Thread it through `js/net/src/broadcast.ts` and `lite/subscriber.ts`.
`ietf/subscriber.ts` rejects `fetchGroup` today (moq-transport has no
one-shot group fetch), so it stays unchanged.
- Fetches for the same group share one stream (`lite/subscriber.ts`), so an
abort releases this caller's share and rejects its promise with the
signal's reason. The stream is cancelled only when the last sharer leaves.
- An already-aborted signal rejects before anything is sent.
- Tests: one of two sharers aborts and the other still receives the group;
the last sharer aborting cancels the stream.
- Document the option where fetch is documented under `doc/`.

Public API: additive `FetchGroupOptions.signal`. Wire: none new; the
existing cancel path.
20 changes: 20 additions & 0 deletions quest/m1/js-track-close-end.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# [XS] A JS track's clean close ends at its own last group

## Goal

`close()` on a JS track producer declares the final sequence from the groups
that track actually produced, like Rust's `finish()` uses its own
`max_sequence`. A sibling producer on the same broadcast and name can no
longer push the end past groups this track will ever send.

## Plan

- `close()` in `js/net/src/track.ts` calls `#declareFinal(this.#sequence.next)`,
and `#sequence` is shared per broadcast and track name (`bindProducer`).
Use the track's own `#received` high-water mark instead, which #4385 added
and only `#settled` reads today.
- Re-check `finishAt` for the same shared-counter assumption.
- Regression test: two producers on one name, the sibling creates later
groups, and the closed track's final sequence is its own last group + 1.

Public API: none. Wire: none.
4 changes: 4 additions & 0 deletions quest/m1/relay-auth-client-ca.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ config instead of quietly refusing every session.
auth configured, which `MoqSide::validate` permits and whose peers admit
through the cluster. Make that case explicit and let any other error stop
startup.
- A listener TLS client CA on a stream-only relay (no QUIC owner at all,
the `NoBackend` case in `rs/moq-relay/src/relay.rs`) is never checked, so
refuse that config at load instead of silently ignoring the CA. Worker-owned
QUIC (`quic_owned_elsewhere`) still enforces the CA, so keep accepting it.
- Update every caller, the tests #4364 added in both `moq-cli` and
`moq-relay`, and `doc/bin/relay/auth.md` or `doc/lib/rs` wherever they name
the methods.
Expand Down