diff --git a/.github/workflows/interop.yml b/.github/workflows/interop.yml index b9f1be51c48..ad8b003e847 100644 --- a/.github/workflows/interop.yml +++ b/.github/workflows/interop.yml @@ -65,11 +65,8 @@ jobs: run: nix develop --command just test max-age shell: bash -leo pipefail {0} - - name: Datagram tracks - id: datagram-tracks - if: ${{ !cancelled() && steps.setup.outcome == 'success' }} - run: nix develop --command just test datagram-tracks - shell: bash -leo pipefail {0} + # Datagram tracks awaits the JS lite-07 route wire in + # quest/m2/cluster-routing/routes/js.md; recorded as skipped below. - name: Stream limits over WebSocket id: stream-limits @@ -225,7 +222,7 @@ jobs: "Rust cache": "${{ steps.rust-cache.outcome }}", "Playwright Chromium": "${{ steps.setup.outcome }}", "Optional publisher retention": "${{ steps.max-age.outcome }}", - "Datagram tracks": "${{ steps.datagram-tracks.outcome }}", + "Datagram tracks": "skipped", "Stream limits over WebSocket": "${{ steps.stream-limits.outcome }}", "Relay fills": "${{ steps.relay-fill.outcome }}", "Receive credit recovery": "${{ steps.receive-credit.outcome }}", diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 9f91ae94495..deed1aaa945 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -335,9 +335,8 @@ jobs: # `rs uring` is a separate feature compile (off the default set), and # CI_STRICT fails it below the 6.12 kernel floor. The embedding tests for # io_uring live there; uring.yml also runs it on affected release PRs. - # `test drain` stands up two relays and drains one under a live JS - # viewer: diff-independent, since a break can arrive through the relay, - # js/net, or the wire between them. + # `test drain` awaits the JS lite-07 route wire in + # quest/m2/cluster-routing/routes/js.md; keep its local recipe usable. # `rs quic-sim` sweeps moq-quic's simulated workloads from a fresh seed; PRs run a fixed 64. # `rs rung-disable` proves FFI simulcast disable and recovery on a shaped BBR3 uplink. # `test resume-model` sweeps resume against its model from a fresh seed; PRs run a fixed 64. @@ -356,7 +355,7 @@ jobs: # `rs v4l2` streams moq-video's V4L2 capture from the kernel's vivid # virtual camera, a module load no pull request job should make. # `js worklet-matrix` loads `?worklet` output through the bundlers pinned in test/worklet. - recipe: ["gate", "gh test-integration", "rs doctest --workspace", "rs send-depth", "test drill-sensitivity", "rs uring", "test drain", "test json-properties", "test resume-model", "rs quic-sim", "rs rung-disable", "test drill impaired", "rs cli-export", "rs hls-conformance", "rs quic-stress", "rs audio-devices", "rs multicast", "rs render-sw", "test qmux", "rs v4l2", "js worklet-matrix"] + recipe: ["gate", "gh test-integration", "rs doctest --workspace", "rs send-depth", "test drill-sensitivity", "rs uring", "test json-properties", "test resume-model", "rs quic-sim", "rs rung-disable", "test drill impaired", "rs cli-export", "rs hls-conformance", "rs quic-stress", "rs audio-devices", "rs multicast", "rs render-sw", "test qmux", "rs v4l2", "js worklet-matrix"] include: # Miri interprets kio's and moq-net's in-memory unsafe; too slow for the merge gate. - recipe: rs miri diff --git a/infra/nix/justfile b/infra/nix/justfile index 842716680dd..fc7edf374f6 100644 --- a/infra/nix/justfile +++ b/infra/nix/justfile @@ -47,7 +47,7 @@ roots bucket rev name +paths: set -euo pipefail : "${AWS_ACCESS_KEY_ID:?not set}" : "${AWS_SECRET_ACCESS_KEY:?not set}" - PATH="$(nix build --no-link --print-out-paths --inputs-from {{ quote(justfile_directory() / "../..") }} nixpkgs#rclone)/bin:$PATH" + PATH="$(nix build --no-link --print-out-paths --inputs-from {{ quote(justfile_directory() / "../..") }} nixpkgs#rclone^out)/bin:$PATH" readlink -f {{ paths }} | rclone rcat "r2:{{ bucket }}/roots/{{ rev }}/{{ name }}" # Restart the upload age of every object in a commit's recorded closures older than a week. @@ -60,7 +60,7 @@ refresh bucket rev: set -euo pipefail : "${AWS_ACCESS_KEY_ID:?not set}" : "${AWS_SECRET_ACCESS_KEY:?not set}" - PATH="$(nix build --no-link --print-out-paths --inputs-from ../.. nixpkgs#rclone)/bin:$PATH" + PATH="$(nix build --no-link --print-out-paths --inputs-from ../.. nixpkgs#rclone^out)/bin:$PATH" remote="r2:{{ bucket }}/" store="s3://{{ bucket }}?endpoint={{ endpoint }}®ion=auto" work=$(mktemp -d) diff --git a/js/qmux/bench/datagrams.ts b/js/qmux/bench/datagrams.ts index 527736ade55..035d2de3ed7 100644 --- a/js/qmux/bench/datagrams.ts +++ b/js/qmux/bench/datagrams.ts @@ -31,6 +31,9 @@ async function measure(backlog: number): Promise { }, { config: { idleTimeout: null } }, ); + incoming.enqueue( + Frame.encode({ type: "transport_parameters", params: Frame.RECOMMENDED_TRANSPORT_PARAMS }, "qmux-01"), + ); await session.ready; session.datagrams.incomingHighWaterMark = backlog; for (let index = 0; index < backlog; index++) incoming.enqueue(packet); diff --git a/nix/overlay.nix b/nix/overlay.nix index 70d94c7d543..3af48a81255 100644 --- a/nix/overlay.nix +++ b/nix/overlay.nix @@ -13,10 +13,16 @@ let # Helper function to get crate info from Cargo.toml crateInfo = cargoTomlPath: craneLib.crateNameFromCargoToml { cargoToml = cargoTomlPath; }; - # moq-video embeds a vendored PTX kernel at compile time, so every package - # source that may pull it in must preserve PTX alongside Cargo's sources. + # moq-video embeds PTX and moq-webrtc embeds crypto validation data at compile + # time, so packages must preserve these alongside Cargo's sources. filterCargoSources = - path: type: (final.lib.hasSuffix ".ptx" path) || (craneLib.filterCargoSources path type); + path: type: + (final.lib.hasSuffix ".ptx" path) + || ( + (final.lib.hasInfix "/rs/moq-webrtc/src/vendor/dimpl/crypto/validation/" path) + && ((final.lib.hasSuffix ".der" path) || (final.lib.hasSuffix ".bin" path)) + ) + || (craneLib.filterCargoSources path type); cleanCargoSource = final.lib.cleanSourceWith { src = ../.; name = "source"; diff --git a/quest/m2/cluster-routing/routes/js.md b/quest/m2/cluster-routing/routes/js.md index 2c5126b740e..badca96576f 100644 --- a/quest/m2/cluster-routing/routes/js.md +++ b/quest/m2/cluster-routing/routes/js.md @@ -23,13 +23,21 @@ the cheapest one; fix it with the route-selection rework here. asked how to handle the in-tree lanes running JS on lite-07-wip once the Rust side moved to the route wire: ✅ **skip them until this quest lands**, so the nightly report stays meaningful. Rejected: leave them red; hold - #8023 for this quest. Every skip names this quest (`grep -rn routes/js.md - test rs`): `JS_LITE07_SKIP` in `test/interop/interop.sh` and `socket.sh` + #8023 for this quest. Every skip names this quest (`rg routes/js.md + test rs .github sh/gh`): `JS_LITE07_SKIP` in `test/interop/interop.sh` and `socket.sh` (native JS grant printing, claims, track replacement, sockets, the browser route key proof, the lite-07 compress and drop legs, the compressed catalog's lite-07 reader, and `--versions moq-lite-07-wip` with JS clients), `lite_tracks_interop` in `test/justfile`, and the lite-07 legs of `max_age_relay_javascript` and - `relay_fill_javascript`. + `relay_fill_javascript`. Also restore `test drain` in the nightly matrix, + restore the `Datagram tracks` interop workflow step and its report outcome, reset + `datagram_tracks_javascript`'s ignore reason, remove its test-inventory entries, + and remove the default media `replacement` + route-wire quarantine (every replacement publisher pins lite-07 even for + older readers). Keep the separate Firefox audio-tone quarantine until + [moq-dev/moq#8058](https://github.com/moq-dev/moq/pull/8058) resolves it. + The local drain/datagram recipes and explicit `--cases replacement` remain + available to validate the port. ## Required diff --git a/rs/moq-relay/src/internal.rs b/rs/moq-relay/src/internal.rs index bd34b344076..194943cb956 100644 --- a/rs/moq-relay/src/internal.rs +++ b/rs/moq-relay/src/internal.rs @@ -1571,6 +1571,7 @@ mod tests { /// and forking both the socket options and the disabled-listener contract. #[tokio::test] async fn serve_hosts_merged_routes_alongside_the_defaults() { + moq_tokio::crypto::install_default().unwrap(); let listen = Some("127.0.0.1:0".parse().unwrap()); let internal = Internal::new(Config { listen }, moq_net::stats::Registry::disabled()) .bind() diff --git a/rs/moq-tokio/src/abort.rs b/rs/moq-tokio/src/abort.rs index ac8e7dd209e..6e9ae1dd8f2 100644 --- a/rs/moq-tokio/src/abort.rs +++ b/rs/moq-tokio/src/abort.rs @@ -6,8 +6,10 @@ /// with nothing left able to reach it. Derefs to the handle, so an owner can still /// await the task's output or abort it early. #[derive(Debug)] +#[cfg(any(feature = "quic", all(feature = "watch", feature = "_certs")))] pub(crate) struct AbortOnDrop(tokio::task::JoinHandle); +#[cfg(any(feature = "quic", all(feature = "watch", feature = "_certs")))] impl AbortOnDrop { /// Take ownership of a spawned task. pub(crate) fn new(handle: tokio::task::JoinHandle) -> Self { @@ -15,6 +17,7 @@ impl AbortOnDrop { } } +#[cfg(any(feature = "quic", all(feature = "watch", feature = "_certs")))] impl std::ops::Deref for AbortOnDrop { type Target = tokio::task::JoinHandle; @@ -23,12 +26,14 @@ impl std::ops::Deref for AbortOnDrop { } } +#[cfg(any(feature = "quic", all(feature = "watch", feature = "_certs")))] impl std::ops::DerefMut for AbortOnDrop { fn deref_mut(&mut self) -> &mut Self::Target { &mut self.0 } } +#[cfg(any(feature = "quic", all(feature = "watch", feature = "_certs")))] impl Drop for AbortOnDrop { fn drop(&mut self) { self.0.abort(); diff --git a/rs/moq-tokio/src/listen.rs b/rs/moq-tokio/src/listen.rs index 99513bc7df8..e958c3c7201 100644 --- a/rs/moq-tokio/src/listen.rs +++ b/rs/moq-tokio/src/listen.rs @@ -1036,6 +1036,7 @@ pub struct Forward { impl Forward { /// Whether any forwarding setting is present. + #[cfg(feature = "_transport")] pub(crate) fn configured(&self) -> bool { self.bind.is_some() || self.key.is_some() || self.peers.is_some() } diff --git a/rs/moq-tokio/src/server.rs b/rs/moq-tokio/src/server.rs index 914f0df6e8c..5446383b268 100644 --- a/rs/moq-tokio/src/server.rs +++ b/rs/moq-tokio/src/server.rs @@ -297,6 +297,7 @@ impl Server { // gets the released spellings folded in too. config.validate()?; + #[cfg(any(feature = "quic", feature = "websocket", feature = "tcp", all(feature = "uds", unix)))] let versions = config.versions(); // Build a QUIC backend when `--listen` is set, or when nothing else diff --git a/rs/moq-tokio/tests/integration/datagram_tracks.rs b/rs/moq-tokio/tests/integration/datagram_tracks.rs index 5d23061814c..cf97d7236a5 100644 --- a/rs/moq-tokio/tests/integration/datagram_tracks.rs +++ b/rs/moq-tokio/tests/integration/datagram_tracks.rs @@ -241,7 +241,7 @@ async fn run(relay: bool, js_publishes: bool) { } #[tokio::test] -#[ignore = "requires Bun; run by just test datagram-tracks in the interop workflow"] +#[ignore = "JS lite-07 route wire awaits quest/m2/cluster-routing/routes/js.md"] async fn datagram_tracks_javascript() { for relay in [false, true] { for js_publishes in [false, true] { diff --git a/sh/gh/test-inventory.allow b/sh/gh/test-inventory.allow index 89e5c2de4ab..259777a025a 100644 --- a/sh/gh/test-inventory.allow +++ b/sh/gh/test-inventory.allow @@ -40,3 +40,5 @@ ignore moq-ffi::media::read_tests::raw_media_catalog_warmup_reaches_the_subscrip # Need another implementation to speak the route wire; the quest ports it. ignore moq-net::test_interop::lite_tracks_interop /quest/m2/cluster-routing/routes/js.md +ignore moq-tokio::datagram_tracks::datagram_tracks_javascript /quest/m2/cluster-routing/routes/js.md +recipe test::datagram-tracks /quest/m2/cluster-routing/routes/js.md diff --git a/test/interop/README.md b/test/interop/README.md index e91c5817136..4441ccf33f6 100644 --- a/test/interop/README.md +++ b/test/interop/README.md @@ -555,11 +555,14 @@ at QUIC's 1 ms timer granularity, the 500 ms GOP, one frame to decode, the 50 ms playback delay, and one page sample plus one driver poll. Publisher preparation is not part of it. -Firefox's replacement case is quarantined from the default run after intermittent -audio-tone failures. Investigate the missing tone samples alongside -[the audio playout work](https://github.com/moq-dev/moq/pull/8058), then restore it. -Run it explicitly with `just test media --media-engines firefox --media-cases replacement`; -its content, sync, switch, and fallback assertions remain active. +The replacement case is quarantined from the default run on every engine until +[the JS route-layer port](../../quest/m2/cluster-routing/routes/js.md) lands, +because both publishers use lite-07. Firefox also has a separate quarantine for +intermittent audio-tone failures; investigate those alongside +[the audio playout work](https://github.com/moq-dev/moq/pull/8058) before restoring +Firefox's default case. Run replacement explicitly with +`just test media --media-cases replacement` (add `--media-engines firefox` for +Firefox); its content, sync, switch, and fallback assertions remain active. The CLI integration suite's `instances` cases exercise the real QUIC relay with lite-07, lite-06, and IETF draft 22. Held catalog snapshots and media diff --git a/test/interop/clients/js/media.ts b/test/interop/clients/js/media.ts index 6109c1d73ac..926b5fd2115 100644 --- a/test/interop/clients/js/media.ts +++ b/test/interop/clients/js/media.ts @@ -166,6 +166,11 @@ if (!native && values.cases === undefined && playerEngine === "firefox") { "QUARANTINE\treplacement\tintermittent audio tone; investigate with https://github.com/moq-dev/moq/pull/8058", ); } +// Every replacement publisher pins lite-07, including the lite-06 and IETF reader legs. +// An explicit --cases replacement remains available while porting the route wire. +if (values.cases === undefined && selected.delete("replacement")) { + console.error("QUARANTINE\treplacement\tJS lite-07 route wire awaits quest/m2/cluster-routing/routes/js.md"); +} // process.exit narrows `url` above, but not inside the function declarations below. const relay: string = url;