deepseek-ai/deepseek-harness · error · SessionTitleInvalidError

title-invalid

title-invalid

Error message

error.message

What it means

Catch-and-wrap in the api-proxy rename handler: the session-title service's rename threw (invalid title, persistence failure), and the error's message is relayed into a structured err() response. Generic guard — the meaning is the inner rename failure.

Solutions

  1. Read the forwarded error message in the response or logs and fix the underlying failure it names.
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at packages/host/apiproxy/src/api-proxy.ts:2249 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/3d03479dbc599821. Report an issue: GitHub.

Appendix: source

Thrown at packages/host/apiproxy/src/api-proxy.ts:2249

      },

      async rename(request) {
        const { sessionId, title } = request.payload
        const found = await agentFor(sessionId)
        if ('error' in found) return err(request, found.error)
        const titles = ctx.get('sessionTitle')
        if (titles === undefined) {
          return err(request, { code: 'internal', message: 'renaming is unavailable: this deployment mounts no session-title service', details: {} })
        }
        try {
          const accepted = titles.rename(found.agent.session, title)
          return ok(request, { title: accepted.title, seq: accepted.eventSeq })
        } catch (error: unknown) {
          // Only the input's fault maps to title-invalid (the message is
          // product-user-visible in the rename dialog); liveness and disposal
          // races are deployment trouble, not a bad title.
          if (error instanceof SessionTitleInvalidError) {
            return err(request, {
              code: 'title-invalid',
              message: error.message,
              details: { sessionId },
            })
          }
          return err(request, {
            code: 'internal',
            message: `failed to rename session "${sessionId}": ${String(error)}`,
            details: {},
          })
        }
      },

      async fork(request) {
        const { sessionId, atSeq } = request.payload
        let source: SessionReadState
        try {
          source = await readSessionState(sessionId)

View on GitHub (pinned to b150a551b8)