From 37841955a7c83da9b7d585f2b4ff5b10bf74acb3 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Tue, 17 Nov 2026 12:02:47 -0800 Subject: [PATCH] quest: plan the lite-07 route hang and credential-established reconnect Co-Authored-By: Claude Opus 5.5 --- quest/m0/nightly/README.md | 16 +++++++ quest/m0/nightly/credential-established.md | 49 ++++++++++++++++++++++ quest/m0/nightly/lite07-route-hang.md | 34 +++++++++++++++ 3 files changed, 99 insertions(+) create mode 100644 quest/m0/nightly/credential-established.md create mode 100644 quest/m0/nightly/lite07-route-hang.md diff --git a/quest/m0/nightly/README.md b/quest/m0/nightly/README.md index 0465ff1856c..17d29eb6b51 100644 --- a/quest/m0/nightly/README.md +++ b/quest/m0/nightly/README.md @@ -64,3 +64,19 @@ After #8635 landed, run failed the firefox resume, now on audio arriving late rather than trailing: [moq-dev/moq#8799](https://github.com/moq-dev/moq/pull/8799) fixed that. + +Decided 2026-11-17 (maintainer, /quest-plan), from the triage of runs +[43909101837](https://github.com/moq-dev/moq/actions/runs/43909101837) and +[44127032469](https://github.com/moq-dev/moq/actions/runs/44127032469): two +more children, the lite-07 route hang and the credential-established reconnect +signal. Fixed in PRs from the same triage: fuzz path +([moq-dev/moq#9015](https://github.com/moq-dev/moq/pull/9015)), cli-export +([moq-dev/moq#9017](https://github.com/moq-dev/moq/pull/9017)), audit ignores +([moq-dev/moq#9012](https://github.com/moq-dev/moq/pull/9012)), JS coverage +([moq-dev/moq#9013](https://github.com/moq-dev/moq/pull/9013)), Gate cost +([moq-dev/moq#9014](https://github.com/moq-dev/moq/pull/9014)), Tests (gate) +disk ([moq-dev/moq#9033](https://github.com/moq-dev/moq/pull/9033)), benches +([moq-dev/moq#9020](https://github.com/moq-dev/moq/pull/9020), +[moq-dev/moq#9021](https://github.com/moq-dev/moq/pull/9021), +[moq-dev/moq#9022](https://github.com/moq-dev/moq/pull/9022)), and mutants +([moq-dev/moq#9019](https://github.com/moq-dev/moq/pull/9019)). diff --git a/quest/m0/nightly/credential-established.md b/quest/m0/nightly/credential-established.md new file mode 100644 index 00000000000..33eff2b9515 --- /dev/null +++ b/quest/m0/nightly/credential-established.md @@ -0,0 +1,49 @@ +# [M] A reconnecting client is established by the credential's answer + +## Goal + +A reconnecting client (Rust `Reconnect` and `moq_tokio::Connection`, JS +`Reload`, and every binding through `moq-ffi`) counts a session as established +once the peer accepts the connection credential, instead of after it stays up +`Backoff::healthy` (1 s). A close before that answer is a refusal and ends the +policy, as today. Versions with no acceptance message keep the uptime bar. No +wire change. + +The tests [moq-dev/moq#8817](https://github.com/moq-dev/moq/pull/8817) gave +real 1 s waits (Go, Python, moq-c), and the OBS tests in draft +[moq-dev/moq#9016](https://github.com/moq-dev/moq/pull/9016), drop the session +right after it is accepted instead. + +## Plan + +Found by the triage of Nightly run +[44127032469](https://github.com/moq-dev/moq/actions/runs/44127032469) +(2026-11-17): the OBS output and source tests drop a session the moment it goes +live, which #8817 now treats as a refusal. #9016 fixes them with real 1 s +waits; the maintainer chose this quest instead, and #9016 waits on it. + +Where acceptance already shows (researched 2026-11-17): + +- lite-05/06 and moq-transport: the server sends SETUP only from `ok()`, and + `moq-relay` judges the token before `ok()` + (`rs/moq-relay/src/connection.rs`), so a refused session never sends it. +- lite-07: also the AUTH_OK answering each side's empty-token Auth Stream, + which carries the grant for the connection credential. +- lite-01/02: the SERVER_SETUP reply. +- lite-03/04: nothing. They keep `Backoff::healthy` as the bar. +- `Tokens::credential` (`rs/moq-net/src/auth/tokens.rs`) already computes this + verdict across versions; `js/net/src/connection/tokens.ts`'s `Verdict` is its + counterpart. Reuse them rather than reading SETUP again. + +Decided 2026-11-17 (maintainer, /quest-plan): + +- Signal: ✅ the existing credential verdict (server SETUP, or AUTH_OK on + lite-07) (rejected: a new SETUP_OK message, which duplicates AUTH_OK; 1 s of + uptime for every version). +- ✅ Versions with no acceptance message keep a timeout, `Backoff::healthy`. +- Update `Handover.tla` and the verify-reconnect skill where `established` is + set, and the `Backoff` docs in every binding. + +## Related + +- [Connect policy state](/quest/m4/connect-policy-state.md) - moves the same policy into one place per language diff --git a/quest/m0/nightly/lite07-route-hang.md b/quest/m0/nightly/lite07-route-hang.md new file mode 100644 index 00000000000..33f46ec00d6 --- /dev/null +++ b/quest/m0/nightly/lite07-route-hang.md @@ -0,0 +1,34 @@ +# [M] lite-07 sessions stop hanging on a dropped token's route + +## Goal + +The lite-07 benches that hang on `main` complete: moq-net `auth/waiting/moq-lite-07-wip/1/1`, +moq-relay `session` lite-07 delivery credit, moq-relay `relay_auth_refresh/1/1`, +and the browser bench smoke ("control kept 8 broadcasts after concluding"). +The root cause is fixed, and a deterministic test (a kio simulation or a +model-checked case) fails without the fix. lite-03 to lite-06 are out of scope. + +## Plan + +Found by the triage of Nightly run +[44127032469](https://github.com/moq-dev/moq/actions/runs/44127032469) +(2026-11-17). Bisected over 7 steps and reproduced locally: caused by +[moq-dev/moq#8835](https://github.com/moq-dev/moq/pull/8835). In +`auth/waiting` under real tokio, the client adds a token, the server grants +everything, the client announces a hidden route, then drops the token. On the +13th repetition the server never hears the route. It is deterministic in the +bench, but a kio simulation of the same steps passes 60 rounds, so a lost +wakeup or a timing-dependent ordering in `rs/moq-net/src/lite/subscriber/route_stream.rs` +or `routed.rs` is likely; `Running::poll`'s permit, ask, and edit path around +the 13th grant is the first place to trace. The relay and browser hangs share +the range and the lite-07 routing and auth paths but were not bisected. + +Decided 2026-11-17 (maintainer, /quest-plan): + +- Goal: ✅ fix every bench above with one deterministic regression test + (rejected: only the bisected bench, with the others getting their own quests). +- Order: ✅ re-run the benches on + [moq-dev/moq#8987](https://github.com/moq-dev/moq/pull/8987)'s head first, + since it rewrites `route_stream.rs` and `routed.rs`. If they still hang, fix on + top of #8987 after it lands; if not, add only the regression test (rejected: + fix on `main` now, which #8987 would likely throw away).