moq-ffi!: report the idle timeout as unset in the binding defaults (before the 0.22 cut)

Aperta
#10,297 1 commento 1 reazione 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
rust
Ambito
api, backend

Direzione di ricerca

Start with rs/moq-ffi/src/session.rs:296-316 and the matching C defaults path in rs/libmoq/src/api.rs; trace how defaults flow through the bindings and wrappers. The plan calls for unset idle-timeout defaults, per-transport default fields, and removal of the OBS comparison workaround in PR #10174. Done means updating all listed APIs and wrappers together with the breaking change and migration note.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Found by the retroactive Codex review of https://github.com/moq-dev/moq/pull/10130 in https://github.com/moq-dev/moq/pull/10288, verified against main at a62650a98f.

Size: S. Milestone: must land before the 0.22.0 cut (m2): it is a breaking FFI change, and 0.22.0 is the first release that ships #10130's one-value-for-all behavior, so landing it after the cut needs another breaking release.

Problem

A binding UI that reads moq_client_defaults() (UniFFI and the C API) and saves them back now sets QUIC's 10 s idle timeout on the WebSocket fallback, whose own default is 30 s. moq_client_defaults() reports quic.idle_timeout = 10s (rs/moq-ffi/src/session.rs:316, with the matching C path in rs/libmoq/src/api.rs), and since #10130 a set value applies to every transport. The doc comment (session.rs:296-299) admits that passing the defaults back changes behavior.

Decision

Decided 2026-12-02 (maintainer, /quest-run on https://github.com/moq-dev/moq/pull/10288): ✅ the binding defaults report the idle timeout as unset (rejected: keep reporting QUIC's 10 s and document it, leaving each UI to compare by value as OBS does).

Plan

  • UniFFI's defaults return idle_timeout: None, and C's moq_client_defaults() leaves has_quic_idle_timeout = false (a zero value with the flag set would disable the timeout), so saving them back keeps each transport's own default.
  • A UI that wants to show the effective values reads new per-transport default fields on the UniFFI record and the C moq_client_config struct.
  • Update moq-ffi, libmoq, and every binding and wrapper together, and remove the OBS compare-by-value workaround from https://github.com/moq-dev/moq/pull/10174.

Public API: breaking (what moq_client_defaults() returns, plus per-transport default fields on the UniFFI record and C struct) in moq-ffi, libmoq, and every wrapper; the PR title takes ! and its Impact section carries the migration note. Wire: none.

The fixing PR lists - [moq-dev/moq#10130](https://github.com/moq-dev/moq/pull/10130) - made a reported default apply to every transport, so a UI saving the defaults back shortens the WebSocket idle timeout (found by reviewer) under ## Caused by.

(Written by Claude Opus 5.5)

Lingua principale
Rust
Stelle
1.6k
Fork
251
Merge medio
10h 10m
PR unite (30g)
832

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di moq-dev/moq

Tutte le issue di moq-dev/moq

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.