diff --git a/quest/m1/cpp/README.md b/quest/m1/cpp/README.md index 40f9e798698..81112b0f8c2 100644 --- a/quest/m1/cpp/README.md +++ b/quest/m1/cpp/README.md @@ -66,8 +66,12 @@ Confirmed in [#4100](https://github.com/moq-dev/moq/pull/4100): ## Required +- [OBS builds on case-insensitive filesystems](/quest/m1/cpp/obs-version-header.md) - `cpp/moq/VERSION` stops shadowing ``, so the macOS and Windows OBS jobs build again +- [MSVC pkg-config probe](/quest/m1/cpp/msvc-pkg-config.md) - the `C++ (MSVC)` job stops tripping on Strawberry Perl's broken `pkg-config` - [Client settings parity](/quest/m1/cpp/client-config.md) - moq-ffi offers libmoq's client knobs, and the OBS advanced settings get back the ones the migration dropped - [Session report parity](/quest/m1/cpp/session-report.md) - a session reports its negotiated draft and reconnect failures, so the OBS dock shows them again +- [Catalog switch](/quest/m1/cpp/catalog-switch.md) - a catalog update keeps OBS playback running until the replacement track is decoding +- [OBS stats race test](/quest/m1/cpp/stats-race.md) - a test against the generated bindings proves a retired session's stats are refused - [Cancel](/quest/m1/cpp/cancel.md) - a cancelled or consumed future reports `valid() == false`, like `std::future`, and a read of it aborts with a message naming the misuse ## Related diff --git a/quest/m1/cpp/catalog-switch.md b/quest/m1/cpp/catalog-switch.md new file mode 100644 index 00000000000..31a9e175157 --- /dev/null +++ b/quest/m1/cpp/catalog-switch.md @@ -0,0 +1,40 @@ +# [S] Catalog switch without a freeze + +## Goal + +A catalog update during OBS playback keeps the current video and audio +playing until the replacement rendition is subscribed and decoding. A +replacement that fails to resolve or subscribe leaves the old track playing +instead of freezing the source until the next catalog update. + +## Plan + +`moq_source_subscribe_video` and `moq_source_subscribe_audio` in +`cpp/obs/src/moq-source.cpp` install the new decoder and replace +`conn->video` / `conn->audio` as soon as the catalog arrives, which cancels +the old track before the asynchronous `resolve()` and `subscribe_media()` +calls have succeeded. An unavailable sibling broadcast or a rejected +subscribe freezes playback, and even a successful update costs a gap and a +fresh keyframe wait. + +Codex flagged it on [#4281](https://github.com/moq-dev/moq/pull/4281) +([finding](https://github.com/moq-dev/moq/pull/4281#discussion_r4113081104), +[reply](https://github.com/moq-dev/moq/pull/4281#discussion_r4114013943)). +The migration kept the libmoq behavior and said it would go to the maintainer +as a follow-up, but nothing was filed. The maintainer decided in the 09-28 +merged-PR audit that it blocks the line. + +- Hold the old track and decoder until the replacement yields, then swap. + Keep "dropping the pending call cancels it" intact, so a second update + racing the first still leaves exactly one live track. +- An update that leaves the chosen rendition unchanged should not + resubscribe at all. +- A catalog that removes video or audio still clears it, as today. + +Cover the swap, the failed replacement, and the unchanged rendition in the +real-relay source tests (`cpp/obs/test/moq-source-test.cpp`). + +## Related + +- [C++ through moq-ffi](/quest/m1/cpp/README.md) - the line this blocks +- [Video source replacement](/quest/m1/obs-moq-video/source.md) - later replaces the source's decoder, and should keep this switch behavior diff --git a/quest/m1/cpp/msvc-pkg-config.md b/quest/m1/cpp/msvc-pkg-config.md new file mode 100644 index 00000000000..dc8d3352259 --- /dev/null +++ b/quest/m1/cpp/msvc-pkg-config.md @@ -0,0 +1,26 @@ +# [XS] MSVC pkg-config probe + +## Goal + +The `C++ (MSVC)` job in `platform.yml` passes `just cpp check`. The line's +CI is green before it lands. + +## Plan + +The CMake probes build and run, then the pkg-config probe fails. On the +Windows runner, `command -v pkg-config` in Git Bash finds Strawberry Perl's +`pkg-config` script, which dies under the MSYS perl with +`Can't locate Pod/Usage.pm`. The empty flags leave `c++` without the include +path, so `probe.cpp` can't find ``. + +The probe also compiles with `c++`, not MSVC, so it never covered MSVC +anyway. Decide between skipping the pkg-config probe on Windows (the CMake +package is the supported MSVC route) and installing a working `pkgconf` in +the job. Prefer the skip unless a Windows pkg-config consumer is expected. +Either way, a pkg-config that fails must fail the check loudly instead of +producing a misleading missing-header error. + +## Related + +- [C++ through moq-ffi](/quest/m1/cpp/README.md) - the line this blocks +- [OBS builds on case-insensitive filesystems](/quest/m1/cpp/obs-version-header.md) - the other inherited `platform.yml` failure diff --git a/quest/m1/cpp/obs-version-header.md b/quest/m1/cpp/obs-version-header.md new file mode 100644 index 00000000000..6689b3d0407 --- /dev/null +++ b/quest/m1/cpp/obs-version-header.md @@ -0,0 +1,25 @@ +# [XS] OBS builds on case-insensitive filesystems + +## Goal + +The `OBS (macOS)` and `OBS (Windows)` jobs in `platform.yml` build the plugin +against the in-tree `cpp/moq` again. The line's CI is green before it lands. + +## Plan + +Both jobs fail compiling `cpp/moq/src/moq.cpp` with errors pointing at +`cpp/moq/version` line 1. `cpp/obs/cmake/common/bootstrap.cmake` sets +`CMAKE_INCLUDE_CURRENT_DIR` globally, so the `add_subdirectory` of `cpp/moq` +puts its source directory on the include path. On a case-insensitive +filesystem `cpp/moq/VERSION` then answers the standard library's +`#include `. + +Fix it at the source rather than renaming the file: keep the source +directory off `moq-cpp`'s include path (unset `CMAKE_INCLUDE_CURRENT_DIR` for +the subdirectory, or scope it to the plugin target). `cpp/obs/VERSION` has +the same shape if the plugin's own directory is ever on a C++ include path. + +## Related + +- [C++ through moq-ffi](/quest/m1/cpp/README.md) - the line this blocks +- [MSVC pkg-config probe](/quest/m1/cpp/msvc-pkg-config.md) - the other inherited `platform.yml` failure diff --git a/quest/m1/cpp/stats-race.md b/quest/m1/cpp/stats-race.md new file mode 100644 index 00000000000..4323a6702c1 --- /dev/null +++ b/quest/m1/cpp/stats-race.md @@ -0,0 +1,35 @@ +# [S] OBS stats race test + +## Goal + +A regression test proves that `MoQOutput::TryGetConnectionStats` refuses a +snapshot when a `Stop()`, restart, or disconnect retires the session while +`stats()` runs, and leaves the caller's last accepted sample untouched. It +runs against the generated C++ bindings, in `just obs test`. + +## Plan + +[#4281](https://github.com/moq-dev/moq/pull/4281) replaced about 2k lines of +libmoq-stubbed OBS tests with suites that drive the real moq-ffi over an +in-process relay. The old "restart rejects uncommitted stats" case in +`cpp/obs/test/moq-output-test.cpp` (see `2ae9f9a5d^`) used a stubbed +`moq_session_snapshot` hook to restart the output inside the stats call. +Codex caught that the fix it guarded was lost +([r4113081126](https://github.com/moq-dev/moq/pull/4281#discussion_r4113081126)). +The fix was restored (the post-`stats()` recheck under `mutex`), but not the +test: the window sits inside a synchronous moq-ffi call, and the real-relay +suites have no seam to hold it open. The maintainer decided in the 09-28 +merged-PR audit that the test comes back before the line lands. + +The work is finding an honest seam. Options include a narrow hook in the +plugin between reading stats and committing them, or a way to make the +generated `Session::stats()` observable from the test. Prefer whatever +keeps production code free of test-only branches, and ask the maintainer if +every option needs one. The test must fail with the recheck removed. + +If other scenarios the stubbed suites covered are clearly lost, list them as +follow-up quests rather than restoring them here. + +## Related + +- [C++ through moq-ffi](/quest/m1/cpp/README.md) - the line this blocks