Skip to content

fix(moq-net): a joining FETCH ending at a group's END_OF_GROUP status is answered - #9291

Merged
kixelated merged 4 commits into
mainfrom
quest/m0/interop-green/ietf-js-joining-fetch
Nov 21, 2026
Merged

kixelated merged 4 commits into
mainfrom
quest/m0/interop-green/ietf-js-joining-fetch

Conversation

@kixelated

@kixelated kixelated commented Nov 21, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fixes the scheduled Interop js -> js-native-node, js -> js-native-bun (and intermittently js -> js) cells on moq-transport-18, red every night since 2026-11-17 (44776434797).

Root cause: since moq-dev/moq#8918, a moq-transport publisher ends each finished group with an END_OF_GROUP status one past its last object. A relay caching that group reports the status as Largest Object, so a draft-18 subscriber's joining FETCH asks for {G, 0}..{G, last+2}. FETCH carries no status object, so the relay's prefix check in rs/moq-net/src/ietf/publisher.rs saw one object short and refused with does_not_exist: joining prefix unavailable. The subscriber falls back to the next whole group, which a catalog never sends, so it times out. It is a race: it hits only when the downstream SUBSCRIBE lands after the group's END_OF_GROUP reached the relay.

The fix: a join whose end sits right past the group's own END_OF_GROUP status, with every object before it held, is the whole prefix, since that status proves nothing follows. The narrower condition (status object at exactly stop, end exactly stop + 1) is deliberate: a_joining_fetch_through_the_last_object_id_reads_its_whole_group still refuses a finished group that holds less than an upstream report claims.

Choices made without the maintainer (user away), for review:

  • FETCH_OK's End Location stays the requested {G, last+2} (the subscription's start), rather than shrinking to the last carried object, so the two streams still meet with no gap or overlap.
  • Fixed only in the relay/publisher's answer, not by excluding the status from Largest Object: the status is an object on the wire, and every Rust and JS subscriber already handles a head that the status ends.

Validation

  • Reproduced locally before the fix: just test interop --publishers js --subscribers js,js-native-node,js-native-bun,rust,python,go,cpp,c --versions moq-transport-18 failed js -> js with joining FETCH refused: does_not_exist (code=16) joining prefix unavailable. A temporary trace at the refusal showed rend=(132, 2) end=Some(1) stop=1 last=Some(1) with the group's end object at id 1, for both a JS and a Rust (moq-cli) publisher.

  • After the fix, 5 runs of the same command: no prefix unavailable anywhere, every js -> js* cell passed. The only failures were js -> rust, js -> cpp, js -> go with audio gap after N samples, the intermittent audio gap that moq-dev/moq#8633 and moq-dev/moq#8611 own (host load around 16).

  • New unit test a_joining_fetch_ending_at_the_end_of_group_status_is_answered fails without the fix and passes with it; all 58 joining_fetch tests pass; just check passes.

  • Not covered: the moq-transport-20 js -> js browser failure in the same run (timed out waiting for rendered video) does not go through a draft-18 joining FETCH; the next scheduled Interop will show whether it recurs.

  • Merged origin/main twice to clear conflicts in quest/m0/interop-green/README.md (only quest wording conflicted): kept main's wording for the replacement join (moq-dev/moq#9293) and the audio stall moq-dev/moq#9300 fixed, and this PR's wording for the joining FETCH, since this PR deletes that quest. After the latest merge, all 848 ietf:: lib tests (including the 58 joining_fetch ones) pass with cargo test -p moq-net --all-features --lib, and just check passes.

Impact

Public API: none. Wire: none (a relay now answers a joining FETCH it used to refuse).

Caused by

  • moq-dev/moq#8918 - started ending each finished moq-transport group with END_OF_GROUP one past its last object, which the relay's joining-FETCH prefix check then counted as a missing object (found by check: scheduled Interop)

Follow-ups

None.

Models

Size: S
Implementer: Claude, claude-opus-5-5, medium effort (arm A)
Implementer: Claude Code, claude-opus-5-5, medium effort (iterate, S, arm A)

🤖 Generated with Claude Code

Review

Rewritten by quest review after each round.

  • Head: ca8fcce

  • Base: origin/main at ecf42f5

  • Risk: medium, The joining FETCH fix could affect subscribers fetching relayed groups that end with END_OF_GROUP, but preserves the API and wire format and is fully undone by reverting.

  • Classified: medium by Codex, gpt-6.1-sol, low effort, session 01a1febd-f67a-70e2-b533-2feab00ed1c4

  • Reviewer: Codex, gpt-6.1-sol, medium effort

  • Session: 01a1fcda-0eb8-7373-8ba7-4644d576ae02, round 3

  • Score: 9/10, The update only merges base changes, leaving the reviewed fix and regression coverage unchanged with no findings; builds and tests were not run as instructed.

  • Rounds: 3; first round 0; findings 0: fixed 0, refuted 0, open 0

  • Findings: none

  • Reviewer: Codex, gpt-6.1-sol, low effort, shadow

  • Session: 01a1fe3b-e6b1-7821-a6e2-76e89899e3c2

  • Rounds: 1; first round 0; findings 0: fixed 0, refuted 0, open 0

kixelated and others added 2 commits November 20, 2026 21:41
… is answered

Since #8918 a moq-transport publisher ends each finished group with an
END_OF_GROUP status one past its last object, and a relay reports that
status as the join's Largest Object. FETCH carries no status, so the
prefix check saw one object short and refused the join with
'joining prefix unavailable'. A JS subscriber's catalog then never got
another group, which kept scheduled Interop's js -> js-native cells red.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated kixelated changed the title moq-transport JS subscribers get the catalog's joining FETCH fix(moq-net): a joining FETCH ending at a group's END_OF_GROUP status is answered Nov 21, 2026
@kixelated
kixelated marked this pull request as ready for review November 21, 2026 06:46
pullfrog[bot]
pullfrog Bot previously approved these changes Nov 21, 2026

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Approach: sound — the relay's joining-FETCH prefix check now accepts a join that ends one past the group's own END_OF_GROUP status. The fix lives where the answer is built, and the condition is deliberately narrow.

Reviewed changes

  • Prefix check in FetchOpen::answer (rs/moq-net/src/ietf/publisher.rs): adds ends_at_status, which requires the group to be finished (end == Some(stop)), the status object to sit at stop, and the requested end to be exactly stop + 1. checked_add avoids overflow. Any other mismatch still returns joining prefix unavailable.
  • Regression test a_joining_fetch_ending_at_the_end_of_group_status_is_answered: runs across JOINING_DRAFTS. It checks that FETCH_OK keeps {5, 2} as its end location, that the object is carried once, and that no resets are logged.
  • Quest notes under quest/m0/interop-green/: bookkeeping only.

I did not build the code or run the tests.

Pullfrog  | View workflow run | Using claude-sonnet-5-5 | 𝕏

@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The joining-prefix validation now accepts a boundary at an End of Group status when that status ends the group and the requested object is one past it. A test covers a relayed group with this status and checks the FETCH_OK location, payload, and absence of stream resets. The interop plan now records the issue and fix, and the standalone planning document has been removed.

Merge Risk: Minimal · up to ca8fc

This change lets a relay answer a joining FETCH whose requested end falls just after a group's End of Group status, instead of refusing it. It adds a regression test, and the narrow condition keeps refusal for other incomplete prefixes. No merge-blocking risk was identified.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: a joining FETCH that ends at a group's END_OF_GROUP status is now answered by the moq-net relay. The PR's publisher.rs change and new test match this. It follows the conven…
Description check Passed The description states the problem (scheduled Interop failures after #8918), the root cause in the joining FETCH prefix check in rs/moq-net/src/ietf/publisher.rs, the fix, validation runs, …
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change: a joining FETCH that ends at a group's END_OF_GROUP status is now answered by the moq-net relay. The PR's publisher.rs change and new test match this. It follows the conventional fix(scope) format and is specific enough for a reader scanning history. It is 81 characters, which is long but within a reasonable range.

Full details: Description check

Explanation

The description states the problem (scheduled Interop failures after #8918), the root cause in the joining FETCH prefix check in rs/moq-net/src/ietf/publisher.rs, the fix, validation runs, and the caused-by PR. It relates directly to the changeset, which also removes the quest document and updates the README link.

Finishing Touches

Simplify code

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 36e43282-0bb9-426e-87c7-ced28e033ef4
Commits

Reviewing files that changed from the base of the PR and between 85de239 and ca8fcce.

Files selected for processing: 1

  • quest/m0/interop-green/README.md
Files skipped from review as they are similar to previous changes: 1

  • quest/m0/interop-green/README.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.

# Conflicts:
#	quest/m0/interop-green/README.md
pullfrog[bot]
pullfrog Bot previously approved these changes Nov 21, 2026

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Reviewed what changed since the prior Pullfrog review (41648b9).

  • Merged main (85de239): resolved a conflict in quest/m0/interop-green/README.md, docs only. rs/moq-net/src/ietf/publisher.rs is unchanged since the last review.

I did not build the code or run the tests.

Pullfrog  | View workflow run | Using claude-sonnet-5-5 | 𝕏

# Conflicts:
#	quest/m0/interop-green/README.md

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Reviewed what changed since the prior Pullfrog review (85de239).

  • Merged main (ca8fcce): resolved a wording conflict in quest/m0/interop-green/README.md, docs only. rs/moq-net/src/ietf/publisher.rs is unchanged.

I did not build the code or run the tests.

Pullfrog  | View workflow run | Using claude-sonnet-5-5 | 𝕏

@kixelated
kixelated added this pull request to the merge queue Nov 21, 2026
Merged via the queue into main with commit f5f8fed Nov 21, 2026
6 checks passed
@kixelated
kixelated deleted the quest/m0/interop-green/ietf-js-joining-fetch branch November 21, 2026 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant