deepseek-ai/deepseek-harness · error
terminal process has exited
Error message
terminal process has exited
What it means
Error "terminal process has exited" thrown in deepseek-ai/deepseek-harness.
Source
Thrown at packages/subprocess/subprocess-local/src/terminal.ts:79
this.pid = terminal.pid
this.rootIdentity = inspector.processTree(this.pid).find(member => member.pid === this.pid)
this.done = this.outcome.promise
this.dataDisposable = terminal.onData((data) => { this.output.write(Buffer.from(data, 'utf8')) })
this.exitDisposable = terminal.onExit(({ exitCode, signal: exitSignal }) => {
if (this.exited) return
this.exited = true
this.output.end()
this.outcome.resolve({
exitCode: exitSignal === undefined || exitSignal === 0 ? exitCode : null,
signal: signalName(exitSignal),
})
})
}
// node-pty writes synchronously; the seam returns a promise for remote transports.
// oxlint-disable-next-line typescript/require-await -- Preserve promise rejection semantics at the async provider contract.
async write(data: string): Promise<void> {
if (this.exited) throw new Error('terminal process has exited')
this.terminal.write(data)
}
// Local inspection is synchronous; the seam returns a promise for remote transports.
// oxlint-disable-next-line typescript/require-await -- Preserve promise rejection semantics at the async provider contract.
async inspectForeground(): Promise<SubprocessTerminalForeground | undefined> {
this.descendants()
const processGroupId = this.inspector.foregroundPgid(this.pid)
if (processGroupId === undefined) return undefined
return {
processGroupId,
inputWaiting: this.inspector.isStdinWaiting(processGroupId),
}
}
async signalForeground(signal: SubprocessTerminalSignal): Promise<number> {
const foreground = await this.inspectForeground()
if (foreground === undefined) {View on GitHub (pinned to b150a551b8)
Solutions
- Open a new terminal session; an exited terminal process cannot be reused.
When it happens
Trigger: Thrown at packages/subprocess/subprocess-local/src/terminal.ts:79 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of deepseek-ai/deepseek-harness@b150a551b8 (2026-08-24).
Data as JSON: /api/errors/845bd0bd265aa7d4.
Report an issue: GitHub.