{"record":{"id":"2f61362048ab06c7","repo":"deepseek-ai/deepseek-harness","slug":"session-not-found","errorCode":"session-not-found","errorMessage":"session \"${sessionId}\" not found","messagePattern":"session \"(.+?)\" not found","errorType":"exception","errorClass":"ApiRemoteSessionNotFound","httpStatus":null,"severity":"error","filePath":"packages/api/remotes/src/agent-lookup.ts","lineNumber":104,"sourceCode":"\n/**\n * Inspect one cold served session without repairing, resuming, or publishing it.\n * @param ctx - Host Context carrying the optional persistence provider.\n * @param sessionId - durable identity to inspect.\n * @returns detached metadata and events for a servable session.\n * @throws {@link ApiRemoteSessionNotFound} when the identity has no project-backed session.\n */\nexport async function inspectApiRemoteSession(\n  ctx: Context,\n  sessionId: SessionId,\n): Promise<{ meta: SessionHeader; events: SessionEvent[] }> {\n  const persistence = ctx.get('sessionPersistence')\n  if (persistence === undefined) {\n    throw new Error('session persistence is not configured (load a dsh-session-persistence backend)')\n  }\n  const meta = (await persistence.list()).find(candidate => candidate.id === sessionId)\n  if (meta === undefined || meta.cwd === undefined) {\n    throw new ApiRemoteSessionNotFound(`session \"${sessionId}\" not found`)\n  }\n  const inspected = await persistence.inspect(sessionId)\n  if (inspected.meta.cwd === undefined) {\n    throw new ApiRemoteSessionNotFound(`session \"${sessionId}\" not found`)\n  }\n  return { meta: inspected.meta, events: [...inspected.events] }\n}\n\n/**\n * Create the Host's shared Agent resolver and configure Agent/Session Typert lookups.\n * Live Agents are reused, ordinary cold sessions resume once per identity, and\n * subagent-owned identities retain the legacy `agent-busy` fence.\n * @param ctx - owning Host Context.\n * @param options - defaults and Agent-scope setup used only for cold resume.\n * @returns resolver shared by legacy API Proxy methods and Typert lookups.\n */\nexport function createApiRemoteAgentResolver(\n  ctx: Context,","sourceCodeStart":86,"sourceCodeEnd":122,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/api/remotes/src/agent-lookup.ts#L86-L122","documentation":"Error \"session \"${sessionId}\" not found\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/api/remotes/src/agent-lookup.ts:104 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use an existing session id; create the session first or check the id."],"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"}