Skip to content

feat(moq-net,net)!: lite-07 FETCH drops Start Byte - #8837

Merged
kixelated merged 5 commits into
mainfrom
quest/m2/fetch-start-byte
Nov 15, 2026
Merged

kixelated merged 5 commits into
mainfrom
quest/m2/fetch-start-byte

Conversation

@kixelated

@kixelated kixelated commented Nov 15, 2026 •

Copy link
Copy Markdown
Collaborator

Finishes quest/m2/fetch-start-byte.md and deletes it.

Summary

Backs out moq-dev/moq#8699, as the maintainer picked on moq-dev/moq#8764. lite-07-wip FETCH no longer carries Start Byte. A frame read partway when its route fails is refetched whole from the next route, and the reader skips the bytes it already read (frame::Consumer's Recover), as before #8699.

Frames are capped at 32 MiB (MAX_CACHE_BYTES), whole-frame reads asked byte 0 anyway, and only chunk readers saved at most one frame's prefix on one hop per failover. That did not pay for a Lead in the group model, the start-byte plumbing through the fill, subscriber, and publisher in Rust and JS, and a field frozen in lite-07.

Removed:

  • Draft: Start Byte in the lite draft's FETCH, its Positions sentence, and its changelog line; the ietf draft's ban on a non-zero Start Byte for a track with a Version, and its changelog line.
  • Rust (moq-net): lite::Fetch::start_byte, Version::has_byte_start, group::Bounds::byte, the Lead (create_lead, lead_at, group::Consumer::at, poll_next_frame_at), the fill's byte (Ask::byte, Pending::byte, GroupFill::byte_start), frame::Consumer::base, and the publisher's serving from a byte.
  • JS (@moq/net): Fetch.startByte, hasByteStart, sendPayloadFrom, and the publisher's serving from a byte.

The revert of the squashed #8699 commit conflicted only where later PRs renamed sequence to key or touched the same tests; those were resolved to the current names.

Merging main (2026-11-15) conflicted in rs/moq-net/src/lite/subscriber.rs's FrameIngest::header, where main let a continuation re-send frames its group holds (!records.relayed && id == self.index); the resolution keeps that clause and drops only the removed lead_at check. quest/m2/time-addressing/model.md and quest/m2/yield-relay-links.md finished on main, so their edits here are gone. After the merge: cargo test -p moq-net --all-features (3388 unit, 606 integration) and just check pass. A second merge of main (conflict-free) was followed by cargo test -p moq-net --all-features (3373 unit, 606 integration), bun test src/lite in js/net (899 pass), just check, and quest check, all passing.

Quests: Byte holes (quest/m3/unbounded-groups/byte-holes.md) and JS byte holes (quest/m3/unbounded-groups/js-byte-holes.md) are deleted (see Decisions). The unbounded groups epic keeps Rust frames capped at 32 MiB and records the decision; Compressed stream no longer waits on lifting the plain cap. Lite-07 finalize drops its link, and Yield on relay links no longer points at Start Byte as its example.

Decisions

  • Maintainer, 2026-11-15 (comment): ✅ delete quest/m3/unbounded-groups/byte-holes.md (rejected: keep it parked). No consumer sends frames over 32 MiB, so mid-frame resume is out until one does.
  • My call: ✅ delete quest/m3/unbounded-groups/js-byte-holes.md too (rejected: keep it). It only mirrored Byte holes for @moq/net and required it, so the same reason applies.
  • My call, following from the above: the unbounded-groups epic is now "Unbounded groups": its Goal keeps Rust frames under the 32 MiB cap and lists frames over 32 MiB and mid-frame resume as non-goals; its earlier byte-position decisions stay as history. Compressed stream (its other child, so the epic still has children) drops its Required link to Byte holes: in Rust it removes only the compressed-slice guard, keeps the inflated size checked against the plain cap, and tests at that cap; JS still goes past 32 MiB, since JS plain frames are already uncapped.

Choices made without asking

Public API and wire impact

Validation

  • half_read_frame::a_half_read_frame_refetches_whole_and_skips_what_was_read: relays P -> A, B -> E over lite-07-wip. E reads 2 MiB of a 5 MiB frame through A, A's session dies, and E reads the rest through B byte-for-byte. B's session sent between the frame's full size and 1 KiB more, so the frame was refetched whole and the read part skipped.
  • cargo test -p moq-net --all-features: all pass (3375 unit, 602 integration).
  • cargo clippy -p moq-net --all-features --all-targets -D warnings and the --no-default-features --lib build: clean.
  • just check: passes (Rust lint across the workspace, JS, drafts, markdown, quest).
  • just test interop --all: 211 passed, 0 failed.

Caused by

Follow-ups

None. Byte holes and JS byte holes are deleted rather than left parked.

Models

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

(Written by Claude Opus 5.5 with medium effort)

🤖 Generated with Claude Code

Review

Rewritten by quest review after each round.

  • Head: e5f4e26

  • Base: origin/main at f3f4cc5

  • Risk: high, The overall branch removes wire-protocol fields and public API, potentially breaking dependent implementations whose rollback would require coordination.

  • Classified: medium by default

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

  • Session: 01a1df97-1c5b-7573-8955-40c36b2ca597, round 3

  • Score: 9/10, The merge preserves upstream continuation handling while removing byte-offset support consistently, with no actionable defects found by source inspection; builds and tests were not run as instructed.

  • Raised the risk to high: The overall branch removes wire-protocol fields and public API, potentially breaking dependent implementations whose rollback would require coordination.

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

  • Findings: none

kixelated and others added 2 commits November 15, 2026 05:00
Backs out #8699. A failover mid-frame refetches the frame whole and skips
the bytes already read, as before. Frames are capped at 32 MiB, so the
byte offset saved at most one frame's prefix per failover, on one hop,
and only for chunk readers. The draft, Rust, and JS drop the field
together; lite-07 is unpublished.

The 5 MiB failover integration test stays as half_read_frame.rs and now
asserts the new route resends the whole frame.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated kixelated changed the title lite-07 freezes without FETCH Start Byte feat(moq-net,net)!: lite-07 FETCH drops Start Byte Nov 15, 2026
@kixelated
kixelated marked this pull request as ready for review November 15, 2026 14:24
@coderabbitai

coderabbitai Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

FETCH no longer includes a byte offset within its starting frame. Frame and group storage, request routing, and recovery now use frame positions. Publishers serve complete frames, and consumers skip bytes already read after recovery. The changes also update protocol drafts, quest documents, and tests.

Merge Risk: Minimal · up to abe4f

This change removes the byte-offset field from lite-07-wip FETCH and refetches whole frames on mid-frame failover, with the reader skipping bytes it already received. No concrete defect was found. Peers built with the earlier wip layout will not interoperate, but that layout was never published.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title "feat(moq-net,net)!: lite-07 FETCH drops Start Byte" matches the main change. The PR removes the Start Byte field from lite-07 FETCH in the Rust moq-net crate and the JavaScript @moq/net pac…
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.
Description check Passed The PR description is specific and directly related to the changeset. It explains that the PR backs out Start Byte support from lite-07-wip FETCH across the draft, Rust moq-net, and JS @moq/net, and i…
Full details: Title check

Explanation

The title "feat(moq-net,net)!: lite-07 FETCH drops Start Byte" matches the main change. The PR removes the Start Byte field from lite-07 FETCH in the Rust moq-net crate and the JavaScript @moq/net package, and the draft and quest documents are updated to match. The title is specific and uses the conventional-commit form with a breaking-change marker.

Full details: Description check

Explanation

The PR description is specific and directly related to the changeset. It explains that the PR backs out Start Byte support from lite-07-wip FETCH across the draft, Rust moq-net, and JS @moq/net, and it lists the removed items. It also describes the quest document deletions, the validation performed, and the wire and public API impact. The description matches the raw summary, which covers the same draft, Rust, JS, and quest file changes.

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: 46202753-afd7-424f-8c57-0c18065c6261
Commits

Reviewing files that changed from the base of the PR and between 250a13a and abe4fb7.

Files selected for processing: 28

  • drafts/draft-lcurley-moq-ietf.md
  • drafts/draft-lcurley-moq-lite.md
  • js/net/src/lite/fetch.test.ts
  • js/net/src/lite/fetch.ts
  • js/net/src/lite/publisher.ts
  • js/net/src/lite/version.ts
  • js/net/src/payload.ts
  • quest/m2/fetch-start-byte.md
  • quest/m2/lite07-finalize.md
  • quest/m2/time-addressing/model.md
  • quest/m2/yield-relay-links.md
  • quest/m3/unbounded-groups/README.md
  • quest/m3/unbounded-groups/byte-holes.md
  • quest/m3/unbounded-groups/compressed-stream.md
  • quest/m3/unbounded-groups/js-byte-holes.md
  • rs/moq-net/src/lite/fetch.rs
  • rs/moq-net/src/lite/publisher.rs
  • rs/moq-net/src/lite/subscriber.rs
  • rs/moq-net/src/lite/version.rs
  • rs/moq-net/src/model/frame.rs
  • rs/moq-net/src/model/group.rs
  • rs/moq-net/src/model/resume.rs
  • rs/moq-net/src/model/track.rs
  • rs/moq-net/src/model/track/fill.rs
  • rs/moq-net/src/model/track/miss.rs
  • rs/moq-net/src/recv.rs
  • rs/moq-net/tests/integration/half_read_frame.rs
  • rs/moq-net/tests/integration/main.rs
Files with no reviewable changes: 11

  • drafts/draft-lcurley-moq-ietf.md
  • drafts/draft-lcurley-moq-lite.md
  • js/net/src/lite/fetch.test.ts
  • js/net/src/lite/version.ts
  • quest/m2/fetch-start-byte.md
  • quest/m2/lite07-finalize.md
  • quest/m3/unbounded-groups/byte-holes.md
  • quest/m3/unbounded-groups/js-byte-holes.md
  • rs/moq-net/src/lite/version.rs
  • rs/moq-net/src/model/track/miss.rs
  • rs/moq-net/src/recv.rs

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

pullfrog[bot]
pullfrog Bot previously approved these changes Nov 15, 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

This review covers the full backout of #8699's FETCH Start Byte across the drafts, moq-net, @moq/net, and the quest files.

  • Wire and drafts: lite-07-wip FETCH drops Start Byte in both the encoder and decoder, in Rust and JS. The lite draft loses the field, its Positions sentence, and its changelog line. The ietf draft loses its non-zero Start Byte ban.
  • Group model: group::Bounds::byte and the whole Lead path are gone (create_lead, lead_at, Consumer::at, poll_next_frame_at, the lead's billing and shedding in tail/trim). bound goes back to a plain start_at.
  • Failover read: frame::Consumer's Recover asks for the frame by index alone, reads the replacement with poll_next_frame, and keeps its own read_idx against the new whole-frame source. Without base, the offset logic in poll_read_chunk/poll_read_all goes back to plain read_idx.
  • Fill and fetch plumbing: the byte is removed from Ask, Pending, Inner, GroupFill, Fetching, and group::Fetch. Fill merging compares frames only.
  • Publisher and subscriber serving: the Rust fetch serve goes back to with_range(start_frame..) with the index() != start_frame → Lagged guard, and buffer_frame_info always announces size. FrameIngest::dispatch no longer routes to a lead. JS #runFetchGroup writes whole frames through sendPayload.
  • Regression test: half_read_frame.rs (formerly byte_holes.rs) now checks that the reader gets the 5 MiB frame byte-for-byte and that B resends the whole frame.
  • Quests: fetch-start-byte.md is deleted, byte-holes.md records the backout and a maintainer Waiting item, and the links in lite07-finalize.md and yield-relay-links.md are updated.

A repo-wide search found no leftover start-byte or Lead references in the code, drafts, doc/, or the TLA+ models.

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

@kixelated

Copy link
Copy Markdown
Collaborator Author

Maintainer decision (2026-11-15, /quest-complete):

(Written by Opus 5.5)

Maintainer decision on #8837: no consumer sends frames over 32 MiB, so
mid-frame resume is out until one does. JS byte holes only mirrored it.
The unbounded-groups epic keeps the Rust frame cap, and compressed-stream
no longer waits on lifting it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pullfrog[bot]
pullfrog Bot previously approved these changes Nov 15, 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

This review covers the delta since the prior Pullfrog review (853a4a1 → abe4fb7), which is quest documentation only.

  • Deleted byte-hole quests: byte-holes.md and js-byte-holes.md are removed, and no links to them remain.
  • Epic rescoped: quest/m3/unbounded-groups/README.md becomes "Unbounded groups", keeps Rust frames capped at 32 MiB, and records the maintainer decision.
  • Compressed stream: compressed-stream.md drops its Required link to Byte holes and tests at the plain cap in Rust.
  • Wording: time-addressing/model.md no longer names byte-holes as the reason for #[non_exhaustive] on Position.

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

# Conflicts:
#	quest/m2/time-addressing/model.md
#	quest/m2/yield-relay-links.md
#	rs/moq-net/src/lite/subscriber.rs
@kixelated

Copy link
Copy Markdown
Collaborator Author

Applies the maintainer decision as of e5f4e26: quest rm deleted quest/m3/unbounded-groups/byte-holes.md, and js-byte-holes.md with it (it only mirrored Byte holes). The unbounded-groups epic keeps Rust frames under the 32 MiB cap and records the decision; compressed-stream no longer requires Byte holes. Recorded under ## Decisions in the PR body.

(Written by Claude Opus 5.5 with medium effort)

pullfrog[bot]
pullfrog Bot previously approved these changes Nov 15, 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

This review covers the delta since the prior Pullfrog review (abe4fb7 → e5f4e26): a merge of origin/main (f3f4cc5) and how it was resolved.

  • Merge resolution in FrameIngest::header: kept main's continuation clause (!records.relayed && id == self.index) and dropped only group.lead_at(id). A continuation that re-sends plain frames its group already holds is still accepted.
  • FrameIngest::dispatch: dropped main's lead_at/create_lead early return, so a frame below the held count goes straight to the Resume/Skip path. This matches the refetch-and-skip model.
  • Quest files: dropped this PR's edits to time-addressing/model.md and yield-relay-links.md, since main finished and deleted both. After the merge, no links to fetch-start-byte, byte-holes, or yield-relay-links remain.

A repo-wide search after the merge found no leftover lead_at, create_lead, start_byte, startByte, hasByteStart, sendPayloadFrom, or poll_next_frame_at references.

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

@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

This review covers the delta since the prior Pullfrog review (e5f4e26 → b61d02d): one merge of origin/main with no conflicts.

  • Merged origin/main: the merge changes only nearby context lines in quest/m2/lite07-finalize.md, where main added a lite-07 time-addressing link and removed the ROUTE's RTT line. This PR still only removes the fetch-start-byte line there.

After the merge, a search of the whole repo found no lead_at, create_lead, start_byte, startByte, hasByteStart, has_byte_start, sendPayloadFrom, or poll_next_frame_at references. It also found no links to fetch-start-byte or byte-holes.

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

@kixelated
kixelated added this pull request to the merge queue Nov 15, 2026
Merged via the queue into main with commit 813f7a0 Nov 15, 2026
8 checks passed
@kixelated
kixelated deleted the quest/m2/fetch-start-byte branch November 15, 2026 21:03
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