owned-instance-exited-error
The distinct error thrown when the harness-owned Obsidian instance is gone — it exited, and the CDP endpoint it was serving answers nothing.
It exists to replace an anonymous cascade with one named cause. Before it, every test file scheduled after a mid-run death failed in ~60–90 ms with TypeError: fetch failed wrapping connect ECONNREFUSED 127.0.0.1:<port> — measured at 156 such failures across 21 files in obsidian-patterns on 2026-09-05, not one of them a test result. The absence of an app is not a test outcome, and this error says so in the words a reader needs: the instance died, here is its exit code, and these failures are not about your code.
Exported so callers can instanceof-match it, like SilentAsarFallbackError and RendererFailedToInitializeError.
Classes
Section titled “Classes”| Class | Description |
|---|---|
| OwnedInstanceExitedError | Thrown when the harness-owned Obsidian instance has exited and its CDP endpoint is therefore unreachable. Carries whatever is known about the death — exit code, signal, when it happened, and the output tail — so the failure names its own cause instead of a refused connection. |
Interfaces
Section titled “Interfaces”| Interface | Description |
|---|---|
| OwnedInstanceExitedErrorConstructorParams | Parameters for the OwnedInstanceExitedError constructor. Everything but the URL is optional: the exit details come from the process that launched the instance, and a caller in another process has them only when the exit marker survived (see owned-instance-exit-marker.ts). |