Skip to content

fix(ci): bring utility-worker-host.ts back under the max-lines limit - #44378

Merged
brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-utility-worker-host-max-lines
Nov 19, 2026
Merged

brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-utility-worker-host-max-lines

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Problem

main fails static analysis and typecheck: src/main/utility-worker-host/utility-worker-host.ts has 314 counted lines (limit 300) after #44205.

Change

Moves the breadcrumb data builders for a worker's OOM and a host's exit into utility-worker-heap-report.ts, and folds the crash count into the OOM handler. Breadcrumb fields and crash counting are unchanged.

Verification

oxlint, pnpm tc:node, check:code-quality:changed, and the utility-worker-host tests (15) pass. I skipped the full check:changed run so main gets unblocked sooner; CI runs the full suite.

Files Added Deleted Net
Test 0 0 0 0
Prod 2 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​49 $\color{#cf222e}{\Huge{\mathbf{−}}}$​31 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​18

Breadcrumb data for a worker's OOM and a host's exit moves beside the other
heap report builders; behavior is unchanged.
@coderabbitai

coderabbitai Bot commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The change adds helpers that build breadcrumb data for worker out-of-memory events and utility worker host exits. UtilityWorkerHost uses these helpers when recording the corresponding breadcrumbs. Worker out-of-memory handling no longer records a separate crash-loop event.

Merge Risk: Minimal · up to 9c66d

This is a behavior-preserving refactor of failure breadcrumb construction in the utility worker host. No concrete regression has been identified, so merge risk is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: a CI fix that brings utility-worker-host.ts back under the max-lines limit. The changeset moves breadcrumb data builders out of utility-worker-host.ts into utility-worker-h…
Description check Passed The description covers the problem (static analysis failure, 314 lines against a 300-line limit), the change (moving breadcrumb builders to utility-worker-heap-report.ts and folding crash counting int…
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: a CI fix that brings utility-worker-host.ts back under the max-lines limit. The changeset moves breadcrumb data builders out of utility-worker-host.ts into utility-worker-heap-report.ts (about 31 lines removed from the host file), which addresses that limit. The title is specific and matches the main purpose, though it describes the goal rather than the file move itself.

Full details: Description check

Explanation

The description covers the problem (static analysis failure, 314 lines against a 300-line limit), the change (moving breadcrumb builders to utility-worker-heap-report.ts and folding crash counting into the OOM handler), and verification steps. It omits the template's ELI5, Linked Issue (it references #44205 but no 'Fixes #' issue), Visual Proof, Risk level, and the Testing checklist. A reviewer cannot judge risk or back-out steps from it. The description is mostly complete for a small refactor but missing several required sections.

Resolution

Add the missing template sections: a short ELI5, a Linked Issue entry (or a note that this is a maintainer PR with no new issue), a Visual Proof line stating N/A with the reason, the Risk section with a level (likely Low) and the back-out method (plain revert), and the Testing checkboxes.

  • 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: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ce53d5d3-da90-4958-ae97-cb816accf777
Commits

Reviewing files that changed from the base of the PR and between cdf90d9 and 9c66d06.

Files selected for processing: 2

  • src/main/utility-worker-host/utility-worker-heap-report.ts
  • src/main/utility-worker-host/utility-worker-host.ts

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

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