deepseek-ai/deepseek-harness · error · WorkspaceMoveInvalidError
cannot move session '${sessionId}' in workspace '${record.pa
Error message
cannot move session '${sessionId}' in workspace '${record.path}': the session is not accounted What it means
Error "cannot move session '${sessionId}' in workspace '${record.path}': the session is not accounted" thrown in deepseek-ai/deepseek-harness.
Source
Thrown at packages/workspace/workspace/src/entity.ts:154
)
}
if (cwd !== this.record.path) {
throw new Error(
`cannot attach session '${sessionId}' to workspace '${this.record.path}': `
+ `its cwd resolves to '${cwd}'`,
)
}
this.host.rememberSessionPath(sessionId, cwd)
}
await this.mutate(record => record.sessionIds.includes(sessionId)
? record
: { ...record, sessionIds: [sessionId, ...record.sessionIds] })
}
async insertSessionBefore(sessionId: SessionId, beforeSessionId?: SessionId): Promise<void> {
await this.mutate((record) => {
if (!record.sessionIds.includes(sessionId)) {
throw new WorkspaceMoveInvalidError(
`cannot move session '${sessionId}' in workspace '${record.path}': the session is not accounted`,
)
}
if (beforeSessionId !== undefined && !record.sessionIds.includes(beforeSessionId)) {
throw new WorkspaceMoveInvalidError(
`cannot move session '${sessionId}' before '${beforeSessionId}' in workspace '${record.path}': `
+ 'the anchor session is not accounted',
)
}
if (beforeSessionId === sessionId) return record
const without = record.sessionIds.filter(id => id !== sessionId)
const at = beforeSessionId === undefined ? without.length : without.indexOf(beforeSessionId)
const sessionIds = [...without.slice(0, at), sessionId, ...without.slice(at)]
return sessionIds.every((id, index) => id === record.sessionIds[index])
? record
: { ...record, sessionIds }
})
}View on GitHub (pinned to b150a551b8)
Solutions
- Attach the session to the workspace before trying to move it within the workspace order.
When it happens
Trigger: Thrown at packages/workspace/workspace/src/entity.ts:154 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/8a418d410e95e263.
Report an issue: GitHub.