Skip to content

@moq/watch keyed-by-timestamp replay test times out under load - #9543

Merged
kixelated merged 3 commits into
mainfrom
quest/m0/test-flakes-3/watch-replay-keyed
Nov 24, 2026
Merged

kixelated merged 3 commits into
mainfrom
quest/m0/test-flakes-3/watch-replay-keyed

Conversation

@kixelated

@kixelated kixelated commented Nov 24, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

replay > waits out only the keys around missing media when groups are keyed by timestamp timed out at bun's 5 s default under a loaded just check. It replays a simulated 10 s trace four times, and the replay's CPU cost grows with simulated seconds.

Approach

Replay 1 s instead of 10 s (missing key at 500 ms). The property, that only the keys around missing media are owed, needs one gap, not ten seconds of audio. No timeout change. Deleted the finished quest.

Impact

Test only; no public API or wire change.

Validation

  • Reproduced: with 24 busy loops pinned to one core (taskset), the old test timed out at 5 s every run.
  • Under 7 busy loops on the same core, the test alone took 11-17 s before and 2.8-5.3 s after (process startup included), about 4-5x cheaper. Unloaded, a 1 s replay costs 8-58 ms against 120-155 ms for 10 s.
  • The 24-loop pin is so extreme that process startup and JIT warm-up alone exceed 5 s, so it still times out there; that is the load of the harness, not the test.
  • just check passes, and the whole replay.test.ts passes.

Caused by

  • moq-dev/moq#9191 - added the test with four 10 s replays, whose CPU cost outgrows 5 s under load (found by check).

Follow-ups

None.

Models

Size: S
Implementer: Claude Code, claude-sonnet-5-5, unknown effort

Review

Rewritten by quest review after each round.

  • Head: fb4e97d
  • Base: origin/main at 9b6183c
  • Risk: low, The change only edits one test in js/watch/src/audio/replay.test.ts (shorter simulated trace, adjusted thresholds) and deletes a finished quest plan file, so nothing a consumer or peer relies on changes, and a revert fully restores both.
  • Classified: low by Claude Code, claude-haiku-5-5, low effort, session e9fcb91d-3244-4aae-9292-7fb0c58bf003
  • Local review: none, since a low-risk head needs only the online reviewer

kixelated and others added 2 commits November 24, 2026 09:02
…ups test

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@kixelated
kixelated marked this pull request as ready for review November 24, 2026 17:11
@pullfrog

pullfrog Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

No configured credential can serve this run. Your Claude subscription has hit its usage limit, which resets at 2026-11-25 06:00 UTC. Re-trigger after it resets, or add an API key for this provider, which Pullfrog falls back to automatically.

The providers' responses
CLAUDE_CODE_OAUTH_TOKEN: 429: This request would exceed your account's rate limit. Please try again later.

Pick another model →

Pullfrog  | Rerun failed job ➔ | View workflow run | via Pullfrog | Using claude-sonnet-5-5

@coderabbitai

coderabbitai Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

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 25 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

  • 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: b1b7e52b-dfaa-4b74-b44e-e842e3b44637
Commits

Reviewing files that changed from the base of the PR and between fb4e97d and 93052b8.

Files selected for processing: 2

  • js/watch/src/audio/replay.test.ts
  • quest/m0/test-flakes-3/watch-replay-keyed.md

No actionable comments were generated in the recent review.

Walkthrough

The timestamp-keyed audio replay test now generates and observes a one-second trace. It updates the expected heard-audio threshold and missing-frame timestamp. The test retains its checks for packet duration and underruns. The document describing the test timeout and investigation steps was removed.

Merge Risk: Minimal · previous review fb4e9

This change shortens a replay test to reduce CPU cost and timeouts under load. It does not affect production behavior, and the merge risk is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change under test: the keyed-by-timestamp replay test that times out under load. The PR shortens that test's simulated trace from 10 s to 1 s to cut CPU cost. The title does not me…
Description check Passed The description states the problem, the approach (replay 1 s instead of 10 s with the missing key at 500 ms), the impact (test only), validation results, and the commit that introduced the test. It ma…
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 under test: the keyed-by-timestamp replay test that times out under load. The PR shortens that test's simulated trace from 10 s to 1 s to cut CPU cost. The title does not mention the shorter trace, but it refers to the real subject of the change.

Full details: Description check

Explanation

The description states the problem, the approach (replay 1 s instead of 10 s with the missing key at 500 ms), the impact (test only), validation results, and the commit that introduced the test. It matches the changeset, which edits replay.test.ts and deletes the finished quest file.

Finishing Touches

Simplify code

  • Commit to this branch
  • Create a new PR
Fix failing CI checks

  • 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: dbf1117c-35e7-4d6c-923d-f6ed1b4dacfa
Commits

Reviewing files that changed from the base of the PR and between 9b6183c and fb4e97d.

Files selected for processing: 2

  • js/watch/src/audio/replay.test.ts
  • quest/m0/test-flakes-3/watch-replay-keyed.md
Files with no reviewable changes: 1

  • quest/m0/test-flakes-3/watch-replay-keyed.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.

A new head drops the failed check Pullfrog's quota left on the old one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated
kixelated added this pull request to the merge queue Nov 24, 2026
Merged via the queue into main with commit 9aba984 Nov 24, 2026
5 checks passed
@kixelated
kixelated deleted the quest/m0/test-flakes-3/watch-replay-keyed branch November 24, 2026 19:23
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