Skip to content

deps: bump moq-noq stack to 2.0.4 - #5185

Merged
kixelated merged 2 commits into
mainfrom
quest/m1/test-flakes-2/impaired-handshake
Oct 10, 2026
Merged

kixelated merged 2 commits into
mainfrom
quest/m1/test-flakes-2/impaired-handshake

Conversation

@kixelated

@kixelated kixelated commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

The impaired relay drills occasionally failed to connect a client: failed to exchange h3 settings: ... reset by peer or Noq(Connection("timed out")), in about 1 of 100 cluster runs and 1 of 480 republish runs. #5163 traced both to the drills' 2s client idle timeout meeting a backed-off PTO during the handshake, and fixed it in moq-quic. The drills still run on moq-noq, so they need a noq release carrying the same fixes.

Approach

Bump the moq-noq-proto and web-transport-moq pins in Cargo.toml from 2.0.2 to 2.0.4, and Cargo.lock with cargo update --precise 2.0.4. Only moq-noq, moq-noq-proto, moq-noq-udp, and web-transport-moq move in the lock, the same shape as #5074. 2.0.4 carries:

  • moq-dev/noq#32 (released in 2.0.3): discard_space resets pto_count, as RFC 9002 A.11 requires, so a lost Finished no longer waits on the Initial backoff.
  • moq-dev/noq#34: TransportConfig::handshake_idle_timeout, default 10s, governs the idle timer until the handshake completes. It also bounds an Initial waiting for accept, and sets the handshake's probe interval cap.

The PTO fix also reaches release as noq 1.3.5 in #5170.

moq-uring gets the same 10s handshake bound: its unanswered-dial tests no longer set a 500ms idle timeout, which stopped shortening them, and now take 10s each.

This finishes and deletes quest/m1/test-flakes-2/impaired-handshake.md and its entry in the questline README.

Impact

  • Public API: none in this repo. moq-tokio keeps noq's default handshake idle timeout.
  • Behavior: a QUIC handshake to an unreachable peer now gives up after 10s, rather than after the idle timeout (30s by default, max(2s, 3 * PTO) for the drills). A reconnecting dial is still cut at the loop's retry window, so the drills' 5s backoff.timeout still bounds it. A relay drops an Initial waiting for accept after 10s, rather than after its idle timeout. The same holds for moq-uring: Transport::idle_timeout no longer bounds a dial.
  • Wire: none.

Drills

Looped with the built drill binary on a shared machine (load average 16 to 38):

Drill Runs on 2.0.4 (local build) Runs on published 2.0.4 Failures
bursts_cross_a_cluster::impaired 300 100 0
bursts_cross_a_flapping_peer::impaired 300 100 0
interrupted_publisher_republishes_new_content::impaired 300 100 0
relay_killed_mid_group_aborts_then_resumes::impaired 300 100 0
relay_killed_mid_group_aborts_then_resumes::loopback 150 - 0

The local-build rounds ran 150 runs at 4 in parallel, then 150 at 8. The published round ran 4 in parallel, alongside just check, at a load average near 38. The crash drill (relay_killed_mid_group_aborts_then_resumes) is the reconnect-loop check the quest asked for: its slowest run took 7s. After rebasing onto #5160, which moved the crash drill's restart to a fresh port, it passed 50 more runs per lane at a load average near 45.

Checks

  • just check: passed.
  • quest check: passed.

Follow-ups

  • moq-uring has no knob for the handshake bound. If its dial tests should stay fast, or callers need a shorter bound, add a Transport handshake timeout (an API addition).
  • noq#34's review added three fixes beyond what fix(moq-quic): fix two handshake stalls under a short idle timeout #5163 ported to moq-quic: the stale-Initial check uses the handshake timeout, the probe interval cap follows it, and an unrepresentable deadline never fires. moq-quic should mirror them before the switch.

(Written by Claude Opus 5.5)

🤖 Generated with Claude Code

@kixelated
kixelated marked this pull request as ready for review October 10, 2026 12:51
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-10T13:56:16.141194Z a8a443c Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 31 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 4 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: aa31012c-115c-4ee0-9f83-2d7b55d7840c

📥 Commits

Reviewing files that changed from the base of the PR and between f7df075 and a8a443c.


⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock

📒 Files selected for processing (4)
  • Cargo.toml
  • quest/m1/test-flakes-2/README.md
  • quest/m1/test-flakes-2/impaired-handshake.md
  • rs/moq-uring/tests/endpoint.rs

  • 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

Comment @coderabbitai help to get the list of available commands.

@kixelated

Copy link
Copy Markdown
Collaborator Author

Another data point for this bump. #5000's Test job failed with bursts_cross_a_cluster::impaired and subscriber connect failed: Noq(Connection("timed out")) (run). Replaying MOQ_SHAPER_SEED=14126938834471621026 fails the same way on main (f25c50410) and passes on this PR's head (dec1be25).

(Written by Claude Opus 5.5)

Carries moq-dev/noq#32 (reset the PTO backoff on discarding Initial or Handshake keys) and moq-dev/noq#34 (TransportConfig::handshake_idle_timeout, default 10s), which fix the impaired drills' handshake timeouts. Deletes the impaired-handshake quest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated
kixelated force-pushed the quest/m1/test-flakes-2/impaired-handshake branch from dec1be2 to 1593b65 Compare October 10, 2026 13:17
@kixelated

Copy link
Copy Markdown
Collaborator Author

@codex review

(Written by Claude Opus 5.5)

@kixelated

Copy link
Copy Markdown
Collaborator Author

Automated review of #5185 at 1593b658

Clean pin bump: moq-noq-proto and web-transport-moq move 2.0.2 → 2.0.4 in Cargo.toml, and only the four noq-stack crates change in Cargo.lock. The quest file deletion matches the README entry removal, and the only other reference to impaired-handshake.md (the README line) is removed in this PR, so no dangling links on the head.

No blocking issues.

Non-blocking:

  • Behavior change worth keeping in mind: a QUIC handshake to an unreachable peer now gives up at noq's 10s handshake_idle_timeout in every consumer (relay, CLI, moq-tokio), not only the drills. For production configs that set a longer idle timeout on purpose (slow satellite or cellular links), the handshake is now capped at 10s unless they also set the new knob. The PR body covers this; maybe add a changelog line so downstream users notice.
  • A relay now drops an Initial waiting for accept after 10s. That's fine for DoS posture, but under heavy accept backpressure it could show up as new connect failures that weren't there before.
  • CI is still pending on this head. The drill loop numbers in the body are from local runs.
  • Follow-up already noted: moq-quic should mirror noq#34's three extra fixes before the switch.

Verdict: MERGE (once CI is green)

This is an automated review, not the maintainer's decision
(Written by Grok)

@kixelated kixelated left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Automated review by review (OpenAI)

Reviewed commit 1593b65 against base f7df075: full four-file diff, dependency consumers, and the rebased crash drill.

No actionable defects found. The coordinated 2.0.4 dependency update is a focused approach: both workspace requirements and all four lockfile packages agree, with no feature changes. The new base's fresh-port restart remains compatible with the reconnect budget: rs/moq-tokio/src/connection.rs:1044–1068 bounds each dial independently of the QUIC handshake timeout. moq-tokio and moq-uring retain the upstream handshake default. Quest removal matches its README entry.

This independently agrees with the existing review comment on dependency consistency; no additional defect to flag.

Verification limits: static review only; no tests run by me. CI is queued on this head. The reported drill runs are author-provided evidence. Upstream moq-dev/noq implementation and registry checksums were not independently audited within this repository-only review.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1593b65892

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Cargo.toml
# The MoQ fork of noq (moq-dev/noq). iroh keeps upstream noq, so a build with the
# iroh feature carries both stacks.
moq-noq-proto = { version = "2.0.2", default-features = false }
moq-noq-proto = { version = "2.0.4", default-features = false }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve the configured timeout for moq-uring handshakes

When a moq-uring caller sets Transport::idle_timeout below 10 seconds, this upgrade leaves noq 2.0.4's new handshake_idle_timeout at its 10-second default because rs/moq-uring/src/quic/noq/mod.rs::transport_config only forwards the value through max_idle_timeout. Consequently, black-holed handshakes no longer obey the public field's documented bound; for example, the existing 500 ms cases in rs/moq-uring/tests/endpoint.rs now wait about 10 seconds instead of the documented roughly three seconds. Forward an appropriate handshake timeout in the io_uring adapter, or expose and document the separate setting so callers can retain the previous bound.

AGENTS.md reference: AGENTS.md:L27-L28

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Keeping noq's 10s handshake bound for moq-uring rather than forwarding idle_timeout into it. A short idle timeout cutting the handshake to two Initial flights is the bug this bump fixes, and it applies to moq-uring dials as much as to the drills. Transport::idle_timeout documents inactivity on a connection, not a dial bound. The only stale promise was in the tests: a8a443c drops their 500ms idle timeouts, which no longer shortened anything, and the "about three seconds" comment. Those three tests now take 10s each. If they should stay fast, the follow-up is a separate Transport handshake-timeout field in moq-uring, which is an API addition for the maintainer to decide.

(Written by Claude Opus 5.5)

noq 2.0.4 bounds a handshake by handshake_idle_timeout (10s) instead of the idle timeout, so the 500ms idle timeouts no longer shortened these dials.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated

Copy link
Copy Markdown
Collaborator Author

@codex review

(Written by Claude Opus 5.5)

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Swish!

Reviewed commit: a8a443c5eb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@kixelated

Copy link
Copy Markdown
Collaborator Author

Merge summary:

(Written by Claude Opus 5.5)

@kixelated
kixelated merged commit c0c0bb3 into main Oct 10, 2026
14 checks passed
@kixelated
kixelated deleted the quest/m1/test-flakes-2/impaired-handshake branch October 10, 2026 14:16
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