Skip to content

Fix Windows Harness process startup - #39

Merged
wisdomqin merged 10 commits into
mainfrom
agent/fix-windows-harness-runtime
Aug 15, 2026
Merged

Fix Windows Harness process startup#39
wisdomqin merged 10 commits into
mainfrom
agent/fix-windows-harness-runtime

Conversation

@wisdomqin

Copy link
Copy Markdown
Contributor

What changed

  • Launch the bundled Harness through Electron's utilityProcess.fork() instead of respawning the application executable with ELECTRON_RUN_AS_NODE.
  • Preserve the existing loopback port, launch directory, DSH_HOME, stdout/stderr capture, and Node internal-loader flag.
  • Add utility-process startup diagnostics and readable Windows Crashpad exit-code reporting.
  • Add regression coverage for the Windows launch environment and 0xFFFF7003 diagnosis.

Why

On Windows Server 2022, the respawned Electron executable terminated before the DSH entrypoint produced any stdout or stderr. Windows returned 4294930435 (0xFFFF7003, Crashpad handler unavailable), leaving only the desktop launch preamble in harness.log.

Using Electron's Node utility process keeps the Harness child inside Electron's supported process lifecycle and avoids respawning the application executable as a standalone Node process.

Validation

  • npm test -- --run — 56 tests passed.
  • npm run typecheck — passed.
  • npm run build — passed.
  • macOS development runtime smoke test — utility process started, DSH logged its loopback URL, and HTTP returned 200.
  • Windows x64 package and runtime behavior still require the Windows Server 2022 test package requested for this PR.

@wisdomqin

Copy link
Copy Markdown
Contributor Author

Windows x64 Dev test package is ready.

This package is isolated from the formal installation and uses %APPDATA%\dsh-desktop-dev. If startup still fails, please attach %APPDATA%\dsh-desktop-dev\logs\harness.log.

@wisdomqin

Copy link
Copy Markdown
Contributor Author

Superseding the earlier test artifacts: Windows now launches Harness with a bundled Node.js 24.9.0 runtime instead of the Electron executable/utility process.

The packaged DSH Desktop Dev.exe was launched on Windows Server 2022, its Harness endpoint returned HTTP successfully, the process remained stable for the post-ready observation window, and no worker fatal error was logged.

@wisdomqin

Copy link
Copy Markdown
Contributor Author

A validated Windows Dev build is now available as a GitHub Pre-release for faster direct download:

https://github.com/dataelement/dsh-desktop/releases/download/windows-harness-test-20260815.1/dsh-desktop-dev-windows-x64-setup.exe

The pre-release points to 6729668 and does not change the formal Latest release (v0.1.7).

@wisdomqin

Copy link
Copy Markdown
Contributor Author

Windows diagnostic pre-release .2 is available: https://github.com/dataelement/dsh-desktop/releases/download/windows-harness-test-20260815.2/dsh-desktop-dev-windows-x64-setup.exe

Changes: 120s Windows startup allowance plus a bundled-Node diagnostic entry that logs Node version/platform/arch, executable path, cwd, DSH_HOME, DSH entry loading, timed wait progress, uncaught errors, and the real process exit code. The packaged Windows smoke test passed before the pre-release was published.

@wisdomqin

Copy link
Copy Markdown
Contributor Author

Added two desktop UX improvements:

  • show a lightweight localized splash animation while the bundled Harness starts
  • pin DSH Desktop to the native host directory picker on macOS and Windows

Verification:

  • 59 tests passed
  • typecheck and production build passed
  • Windows Server 2022 packaged EXE smoke test passed (HTTP ready, stable process, no Harness stderr)

Windows test installer: https://github.com/dataelement/dsh-desktop/releases/download/windows-harness-test-20260815.3/dsh-desktop-dev-windows-x64-setup.exe

SHA-256: a88fe050b1048ab8c0d783f82376a8def8e5aff117751daf7427606077ccfa2f

@wisdomqin

Copy link
Copy Markdown
Contributor Author

Fixed the native workspace picker regression introduced by the previous composition patch. The native interaction requires both the Host backend and the renderless Client surface; both are now pinned.

Verified locally:

  • sidebar Add workspace action is present
  • clicking the no-workspace composer opens the native macOS directory chooser
  • 59 tests and typecheck pass

Windows Server 2022 packaged EXE smoke test also passed.

Updated Windows test installer: https://github.com/dataelement/dsh-desktop/releases/download/windows-harness-test-20260815.4/dsh-desktop-dev-windows-x64-setup.exe

@wisdomqin
wisdomqin marked this pull request as ready for review August 15, 2026 13:50
@wisdomqin
wisdomqin merged commit a205c34 into main Aug 15, 2026
8 checks passed
@wisdomqin
wisdomqin deleted the agent/fix-windows-harness-runtime branch August 15, 2026 13:50
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