{"record":{"id":"11985febdd3e1ee3","repo":"deepseek-ai/deepseek-harness","slug":"owner-not-live","errorCode":"OWNER_NOT_LIVE","errorMessage":"agent \"${owner.id}\" is not the registered PTY owner","messagePattern":"agent \"(.+?)\" is not the registered PTY owner","errorType":"exception","errorClass":"TerminalError","httpStatus":null,"severity":"error","filePath":"packages/terminal/terminal/src/index.ts","lineNumber":324,"sourceCode":"   * @returns owner-visible snapshots in publication order.\n   */\n  list(owner: Agent): TerminalSessionSnapshot[] {\n    return [...this.sessions.values()]\n      .filter(record => record.owner === owner)\n      .map(record => this.snapshot(record))\n  }\n\n  private assertActive(): void {\n    if (this.disposing) throw new TerminalError('PTY service is disposing', 'SERVICE_DISPOSING')\n  }\n\n  private isLiveOwner(owner: Agent): boolean {\n    return !this.disposedOwners.has(owner) && this.ctx.get('agents')?.get(owner.id) === owner\n  }\n\n  private ensureOwnerCleanup(owner: Agent): void {\n    if (!this.isLiveOwner(owner)) {\n      throw new TerminalError(`agent \"${owner.id}\" is not the registered PTY owner`, 'OWNER_NOT_LIVE')\n    }\n    if (this.ownerCleanups.has(owner)) return\n    const detach = owner.ctx.effect(() => async () => {\n      this.disposedOwners.add(owner)\n      this.ownerCleanups.delete(owner)\n      await this.disposeOwned(owner)\n    }, 'pty.ownerCleanup()')\n    this.ownerCleanups.set(owner, detach)\n  }\n\n  private reserveName(owner: Agent, name: string | undefined): () => void {\n    if (name === undefined) return () => {}\n    if ([...this.sessions.values()].some(record => record.owner === owner && record.name === name)) {\n      throw new TerminalError(`PTY session name \"${name}\" already exists for this owner`, 'DUPLICATE_NAME')\n    }\n    const reserved = this.reservedNames.get(owner) ?? new Set<string>()\n    if (reserved.has(name)) throw new TerminalError(`PTY session name \"${name}\" is already being created`, 'DUPLICATE_NAME')\n    reserved.add(name)","sourceCodeStart":306,"sourceCodeEnd":342,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/terminal/terminal/src/index.ts#L306-L342","documentation":"Error \"agent \"${owner.id}\" is not the registered PTY owner\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/terminal/terminal/src/index.ts:324 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Call PTY operations from the agent that registered as the PTY owner."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}