You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test(browser): wait for file-viewer's long preview to be drawn, with a 30 s ceiling (part of #4185) - #4199
Part of #4185: file-viewer-regression timed out in CI waiting for the last heading (3,121) of the long Markdown
preview. The preview draws its first chunk at once and each later chunk on its own setTimeout(0) task
(src/components/Markdown.tsx); under CI load the whole draw can take longer than the 10 s default wait.
On the maintainer's word (option B): the drawing stays exactly as on main, whose longest task (~60 ms) is fine. The
preview root now says data-drawn="partial" while chunks remain and "complete" once the last one is committed, and
both long-preview steps of the script wait for that exact signal with a 30 s ceiling (the wait returns as soon as the
signal comes; the ceiling only matters on a loaded runner), then assert the exact heading count.
The entry stays in the browser quarantine (#4185): the 10x run also hit a separate timeout, 1 of 10 on a loaded host,
where the side pane's side notes link never appeared within 10 s. Its cause is not known yet, so instead of a guessed
wait, both transcript-link activations now log one line on a timeout (current and expected pane, chat readiness, row
count, conversation source, where side notes is, URL) and rethrow, so the next failure names the cause.
Measured alternatives (not taken)
CI runner image, 3,121-heading long.md, 3 passes each, same load; longest main-thread task and click-to-last-heading
time:
Drawing
Longest task
Total draw
main (one 2,000-element chunk per task)
56-63 ms
1,109-1,223 ms
several 2,000-element chunks per task, 32 ms budget
113-126 ms
800-880 ms
650-element chunks, 40 ms budget
0-55 ms
1,275-1,652 ms
1,000 / 1,300-element chunks, 45 ms budget
0-52 ms
1,314-1,814 ms
650-element chunks, MessageChannel yield, one commit per task
0-53 ms
1,350-1,480 ms
Batching draws faster but holds the page for ~120 ms; smaller tasks keep typing and scrolling smooth but draw ~17%
slower (the cost is the React commit and layout per task, not the timer clamp). Neither beats main on both, and a
slower draw would make this timeout more likely.
Validation
Unit test: a long document is partial before its last chunk and complete after, with all headings (fails on
main: no marker).
CI runner image (herdr-ci-runner:local, BROWSER_WORKERS=6, BROWSER_RETRY=0), 10 passes on the final head:
file-viewer-regression 10/10 with the long-preview fix (one earlier 10x run: 9/10, the side-pane timeout above).
bun test scripts/ci-browser-parallel.test.ts -t quarantine: 4/4.
Auto incremental reviews are disabled on this repository.
Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
Trigger review
No actionable comments were generated in the recent review.
Summary
Summary by CodeRabbit
Tests
Improved regression checks for pane switching and Markdown previews by waiting for content to finish rendering before verifying results.
Added coverage for progressively rendered Markdown documents with more than 1,000 headings.
The progressive Markdown renderer now exposes whether drawing is partial or complete. The browser regression tests wait for transcript rows or completed Markdown drawing before proceeding. The file-viewer regression is removed from the browser quarantine list.
Changes: Markdown browser regressions
Layer / File(s)
Summary
Expose and test Markdown draw completion src/components/Markdown.tsx, src/components/Markdown.test.tsx
ProgressiveMarkdown marks its root as partial or complete. A component test checks the initial partial state and verifies all 1,001 headings after completion.
Synchronize file-viewer tests and remove quarantine scripts/file-viewer-regression.ts, scripts/ci-browser-quarantine.ts
The pane-switch test waits for the transcript’s first chat row before dispatching a file-link click. Preview tests wait for complete drawing before checking heading counts. The quarantine entry is removed.
Issue 4026 reports a timeout in scripts/file-viewer-regression.ts; this change updates that script’s waits for transcript attachment and Markdown completion.
Possibly related PRs
devswha/ovis#4183: It removes the same browser quarantine entry, which this PR also removes while updating the associated regression test.
Suggested reviewers:cheol-95
Merge Risk: Minimal · previous review 18196
This change makes the Markdown preview report whether drawing is partial or complete. It also makes the file-viewer regression test wait for that signal, so it should be less flaky. No merge-blocking risk was identified.
Pre-merge checks: 3 · 1
Failed checks: 1 inconclusive
Check name
Status
Explanation
Resolution
Linked Issues check
[#4185] asks to find what the progressive renderer does under CI load, fix the cause, and remove the quarantine entry. Verified at head: src/components/Markdown.tsx adds only a data-drawn attribute to…
Make the scripts/file-viewer-regression.ts diff readable at head (or confirm its blob is available) so the wait logic and new side-pane wait can be verified. Confirm with the issue owner or maintainer whether a test-side wait with a 30 s ce…
Passed checks: 3 passed
Check name
Status
Explanation
Out of Scope Changes check
Changes map to the PR objectives. The data-drawn attribute in src/components/Markdown.tsx is the signal that the new unit test and the long-preview waits use. The scripts/file-viewer-regression.ts cha…
Title check
The title names the test scope (browser file-viewer long preview), the wait-for-drawn change, and the 30 s ceiling, with the issue reference. It matches the main change in the changeset. The title is …
Description check
The description follows the template. It has a Change section that describes the problem, the resulting behavior, and the rejected alternatives. It has a Validation section listing the unit test, the …
Full details: Out of Scope Changes check
Explanation
Changes map to the PR objectives. The data-drawn attribute in src/components/Markdown.tsx is the signal that the new unit test and the long-preview waits use. The scripts/file-viewer-regression.ts changes (long-preview waits and side-pane transcript wait) sit in the regression script named by #4185. The quarantine removal in scripts/ci-browser-quarantine.ts is the step #4185 requests. The side-pane wait addresses a separate race that #4185 says #4178 did not prove resolved. No change was found that lacks a connection to #4185. The script and test diffs were not directly readable, so this rests on the summary for those files.
Full details: Title check
Explanation
The title names the test scope (browser file-viewer long preview), the wait-for-drawn change, and the 30 s ceiling, with the issue reference. It matches the main change in the changeset. The title is long (99 characters) but clear and specific.
Full details: Description check
Explanation
The description follows the template. It has a Change section that describes the problem, the resulting behavior, and the rejected alternatives. It has a Validation section listing the unit test, the 10x CI runner runs, the quarantine test, and the fast check. It does not mention the full check or contract-test coverage, and it does not link a maintainer-agreed issue for a feature. Those items are not required for this bug fix. The HTML comment from the template is absent, which is minor.
Full details: Linked Issues check
Explanation
[#4185] asks to find what the progressive renderer does under CI load, fix the cause, and remove the quarantine entry. Verified at head: src/components/Markdown.tsx adds only a data-drawn attribute to ProgressiveMarkdown ("complete" when count >= chunks.length, else "partial"). Chunk scheduling (setTimeout(0), one chunk per task) is unchanged. The PR states this is a deliberate choice (maintainer option B). The 'fix at the cause' requirement is therefore not met in the renderer. The PR instead changes the test waits in scripts/file-viewer-regression.ts to a 30 s ceiling on the data-drawn signal. Per the PR summary, the quarantine entry is removed in scripts/ci-browser-quarantine.ts. The diff for scripts/file-viewer-regression.ts and the new unit test could not be read (changed blobs missing from checkout), so the wait logic, the side-pane wait, and the test assertions rest on the PR description and raw summary only. The 10/10 result is reported by the author and not independently verified. Whether a test-side wait satisfies the issue's cause-fixing requirement is a scoping decision the evidence cannot settle.
Resolution
Make the scripts/file-viewer-regression.ts diff readable at head (or confirm its blob is available) so the wait logic and new side-pane wait can be verified. Confirm with the issue owner or maintainer whether a test-side wait with a 30 s ceiling satisfies 'fix at the cause', or whether the renderer must change. Confirm the Markdown.test.tsx test runs and fails on the base commit.
Finishing Touches
Generate unit tests (beta)
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.
Reviewing files that changed from the base of the PR and between 7de4a00 and 18196a8.
Files selected for processing: 4
scripts/ci-browser-quarantine.ts
scripts/file-viewer-regression.ts
src/components/Markdown.test.tsx
src/components/Markdown.tsx
Files with no reviewable changes: 1
scripts/ci-browser-quarantine.ts
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 6 remain after this review.
devswha
changed the title
test(browser): wait for file-viewer's long preview to be drawn, with a 30 s ceiling (#4185)
test(browser): wait for file-viewer's long preview to be drawn, with a 30 s ceiling (part of #4185)
Nov 19, 2026
Review findings addressed in 3799d43: the side-pane wait is reverted (dispatchEvent already auto-waits, so it explained nothing, and its selector missed the non-virtual chat path); both transcript-link activations now log one line on a timeout (current and expected pane, chat readiness, rows, conversation source, where the link text is, URL) and rethrow, so the next failure names the cause; file-viewer stays quarantined until 2026-12-18 under #4185; the Markdown unit test sizes its input from PREVIEW_CHUNK_ELEMENTS and asserts partial before complete. CI runner image on this head: file-viewer-regression 10/10; check fast green. This head changes only the test and the script, so no new CodeRabbit review is requested.
Code review standing in for CodeRabbit, which did not review this head (3799d43, a limit or a skip): the dori review agent (gpt-6.2-sol) read the whole diff at this head and returned CLEAR with no findings. Earlier round at 18196a8: BLOCK on three findings (a side-pane wait that explained nothing, a selector missing the non-virtual chat path, a unit test tied to the chunk size), all resolved in 3799d43 as described above. The src/ change (the data-drawn marker in Markdown.tsx) is unchanged since 0b60e64.
Merged through pr-merge at head 3799d434b. Seen before the merge was asked for: required checks green, no unresolved thread, no conflict, no hold, main not red, no release in progress. CodeRabbit said it did not review (a limit or a skip) since this head.
Lead's option B for #4185: main's Markdown drawing kept, data-drawn marker added, file-viewer's long-preview steps wait on it with a 30 s ceiling (lead-approved), measured alternatives in the body; plus a one-line diagnostic for the unexplained side-pane link timeout; file-viewer stays quarantined. Reviews: dori review BLOCK then CLEAR at 3799d43 (stand-in for CodeRabbit posted on the PR). Evidence: unit test fails on main; file-viewer 10/10 and 20/20 in the CI runner image on this head; check fast green.
…full 30 days (#4202)
## Summary
Closes out the browser quarantine entries due 2026-12-18, on the lead's
word (t10k). Test-only (the quarantine list
alone).
- `file-viewer-regression` leaves the quarantine: with #4199 (the long
preview's drawn signal, 30 s ceiling for that
step) it passed 10/10 in the CI runner image on today's main (6bbe673,
including the CommonMark parser change), and
30/30 earlier on #4199's head. Its side-pane timeout seen once in about
50 runs keeps its diagnostic (#4185).
- `gjc-status-browser-regression` (#4184): cause not shown yet; its
timeout diagnostic (#4196) names the stage on the
next CI failure. Moved to 2026-12-19.
- `pane-mute-demo-regression` (#4131): waits on #4131's design change in
another lane. Moved to 2026-12-19.
2026-12-19 is the latest date the 30-day cap allows
(`QUARANTINE_MAX_DAYS`); the cap stays as is, and the lead reviews
both entries before 12-15.
## Validation
- `bun test scripts/ci-browser-parallel.test.ts -t quarantine`: 4/4.
`bun run check fast`: green.
- CI runner image: file-viewer-regression 10/10 on main 6bbe673.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Part of #4185:
file-viewer-regressiontimed out in CI waiting for the last heading (3,121) of the long Markdownpreview. The preview draws its first chunk at once and each later chunk on its own
setTimeout(0)task(
src/components/Markdown.tsx); under CI load the whole draw can take longer than the 10 s default wait.On the maintainer's word (option B): the drawing stays exactly as on main, whose longest task (~60 ms) is fine. The
preview root now says
data-drawn="partial"while chunks remain and"complete"once the last one is committed, andboth long-preview steps of the script wait for that exact signal with a 30 s ceiling (the wait returns as soon as the
signal comes; the ceiling only matters on a loaded runner), then assert the exact heading count.
The entry stays in the browser quarantine (#4185): the 10x run also hit a separate timeout, 1 of 10 on a loaded host,
where the side pane's
side noteslink never appeared within 10 s. Its cause is not known yet, so instead of a guessedwait, both transcript-link activations now log one line on a timeout (current and expected pane, chat readiness, row
count, conversation source, where
side notesis, URL) and rethrow, so the next failure names the cause.Measured alternatives (not taken)
CI runner image, 3,121-heading
long.md, 3 passes each, same load; longest main-thread task and click-to-last-headingtime:
Batching draws faster but holds the page for ~120 ms; smaller tasks keep typing and scrolling smooth but draw ~17%
slower (the cost is the React commit and layout per task, not the timer clamp). Neither beats main on both, and a
slower draw would make this timeout more likely.
Validation
partialbefore its last chunk andcompleteafter, with all headings (fails onmain: no marker).
herdr-ci-runner:local,BROWSER_WORKERS=6,BROWSER_RETRY=0), 10 passes on the final head:file-viewer-regression 10/10 with the long-preview fix (one earlier 10x run: 9/10, the side-pane timeout above).
bun test scripts/ci-browser-parallel.test.ts -t quarantine: 4/4.bun run check fast: green.