Skip to content

Roll back Windows hang watchdog activation - #26804

Merged
nwparker merged 1 commit into
mainfrom
watchdog-revert
Oct 9, 2026
Merged

nwparker merged 1 commit into
mainfrom
watchdog-revert

Conversation

@nwparker

@nwparker nwparker commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​28 $\color{#cf222e}{\Huge{\mathbf{−}}}$​29 $\color{#cf222e}{\Huge{\mathbf{−}}}$​1
Prod 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1 $\color{#cf222e}{\Huge{\mathbf{−}}}$​1 0

ELI5

Roll back the Windows hang watchdog activation from #26763. Orca on Windows no longer starts this extra diagnostic worker; the existing Mac diagnostic stays enabled.

What Changed

Restore the Mac-only platform check before consent resolution, worker creation, and heartbeat setup. Keep the consent check, worker-error cleanup, marker validation, and restart-evidence startup fixes from #26763.

Why

The extra Windows diagnostic worker is not justified by the marginal performance measurements available. Those measurements do not demonstrate a Windows slowdown. The watchdog measures hangs; it does not fix freezes. A Windows-only rollback preserves unrelated Mac consent and startup correctness that a full revert would remove.

Linked Issue

Refs #26763 and #26719. This does not claim to fix the freeze issue.

Visual Proof

N/A — background diagnostic worker only; no visual or interaction change.

Testing

  • I manually tested these changes locally
  • Automated tests added/updated, or explained why not below

On macOS, with ORCA_BACKGROUND_LAUNCH=1 and no app launch:

  • pnpm test src/main/hang-watchdog src/main/startup/main-process-ready-identity-write.test.ts src/main/startup/main-process-observers-hang-breadcrumb.test.ts src/main/startup/main-process-ready-phase-ordering.test.ts: 10 files, 48 tests passed.
  • Updated mocked Windows/Linux tests prove zero worker construction, timers, and quit listeners in packaged/unpackaged builds with FORCE on/off; existing Mac positive and consent tests remain.
  • pnpm tc: passed.
  • pnpm run check:code-quality:changed: passed.

Windows/Linux platform branches were mocked, not tested on native hosts. Full build and full lint were not run locally; CI is pending.

AI Disclosure

Review

The runtime change is one platform guard. Consent, startup evidence, telemetry schema/wire, remote execution, and folder workspaces keep their existing behavior.

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

The existing Mac diagnostic remains enabled. No new configuration or benchmark is added. Original contribution credit remains in merged history.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

@coderabbitai

coderabbitai Bot commented Oct 9, 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: adc593cb-4225-486e-8919-477dde95ff0f

📥 Commits

Reviewing files that changed from the base of the PR and between 6ef42ad and 7efe3ff.


📒 Files selected for processing (2)
  • src/main/hang-watchdog/main-thread-hang-watchdog.test.ts
  • src/main/hang-watchdog/main-thread-hang-watchdog.ts

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



📝 Walkthrough

Walkthrough

installMainThreadHangWatchdog now returns null on every platform except macOS. Tests verify that Windows and Linux do not create workers, timers, or app listeners across packaged and forced configurations. The development and diagnostics-gate test now covers macOS only.


Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to 7efe3

Windows no longer starts the diagnostic watchdog, as intended, while macOS coverage remains. No concrete merge-blocking regression is established by the supplied change context.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 2 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main change: removing Windows hang watchdog activation while retaining the Mac behavior.
Description check Passed The description is complete and relevant. It explains the user-facing change, mechanism, rationale, retained behavior, testing results, platform limitations, and checklist status. The linked issue sec…
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.


  • 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 merged commit e43997c into main Oct 9, 2026
30 checks passed
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