Skip to content

Fix main CI failures in preview lint and history cleanup - #28108

Merged
nwparker merged 2 commits into
mainfrom
nwparker/fix-html-preview-ci-limit
Oct 13, 2026
Merged

nwparker merged 2 commits into
mainfrom
nwparker/fix-html-preview-ci-limit

Conversation

@nwparker

@nwparker nwparker commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

CI on main is blocked by an oversized HTML-preview component and a test that sometimes reads a folder after cleanup has deleted it. These changes fix both.

What Changed

  • Moved the existing preview-notice assembly into its existing message module, preserving the conditions, message order, and translations.
  • Held background removal in the history-cleanup test while checking that teardown has returned and the history tree has moved. The test then releases removal and waits for actual disk cleanup.

Why

Notice assembly belongs with the preview messages and brings the component under the existing file limit. Controlling background removal lets the test verify that teardown returns before deletion finishes without racing the filesystem.

Linked Issue

Unblocks #28107. Both failures were in unchanged main code or tests.

Visual Proof

N/A — the preview expression moved unchanged; the cleanup change only affects a test.

Testing

  • Existing workspace-document suites: 84 tests passed across 11 files, including missing assets, blocked downloads, and unavailable previews.
  • Existing history-manager and tombstone-retry suites: 34 tests passed under both Bun and Node, with the cleanup test updated.
  • Passed full lint and the renderer typecheck for the preview refactor, the Node typecheck for the cleanup test, and the changed-code quality gate for all three files.
  • Full repository CI passed on the final repair commit, including all five test shards and both package builds.

Review

The preview expression retains its early return, ordering, filtering, and translations. The cleanup test releases its gate and restores its spy in finally; production cleanup behavior is unchanged.

Agent skill upstream boundary

  • Not applicable; no upstream skill-installer material was copied or translated.

Notes

No execution-host, path, shortcut, or wire changes. Local validation ran on macOS; preview tests use the existing simulated guest.

Checklist

  • This PR is small and focused
  • Explained the user-facing problem, mechanism, and choice of approach
  • Visual proof marked N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered
  • Full repository CI passes before merge

@coderabbitai

coderabbitai Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5bd4fe18-5132-46c3-a909-89d8566957dc
📥 Commits

Reviewing files that changed from the base of the PR and between 6e4a5a9 and eba9598.

📒 Files selected for processing (1)
  • src/main/daemon/history-manager.test.ts

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

📝 Walkthrough

Walkthrough

docPreviewNotices selects preview notices based on availability, download-blocked state, and asset failures. HtmlDocPreview calls this helper instead of constructing notices inline. The large-session cleanup test holds the reclamation worker while checking the session directory and tombstone, then releases it and waits for cleanup.

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to eba95

No actionable issue is established in the supplied changes; this review does not identify a reason to delay merging, subject to normal checks.

Pre-merge checks · Passed 4 · Failed 1

Failed Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 3 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks (4 passed)
Check name Status Explanation
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.
Title check Passed The title clearly summarizes both CI-related fixes: the preview lint issue and the history cleanup test issue.
Description check Passed The description follows the template and explains the problem, changes, rationale, testing, visual impact, and compatibility considerations. It references issue #28107 and clearly states that full rep…
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • 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

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

@nwparker nwparker changed the title Fix the HTML preview line-limit failure on main Fix main CI failures in preview lint and history cleanup Oct 13, 2026
@nwparker
nwparker merged commit 568b843 into main Oct 13, 2026
30 checks passed
brennanb2025 pushed a commit that referenced this pull request Oct 15, 2026
* refactor(browser): move preview notices into the message module

* test(daemon): hold history reclamation while checking tombstones

(cherry picked from commit 568b843)
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