deepseek-ai/deepseek-harness · error
session projection cache: ${what} for "${id}" failed (cache
Error message
session projection cache: ${what} for "${id}" failed (cache stays stale): ${String(error)} What it means
Error "session projection cache: ${what} for "${id}" failed (cache stays stale): ${String(error)}" thrown in deepseek-ai/deepseek-harness.
Source
Thrown at packages/session/session-projection-cache/src/index.ts:278
state.timer = undefined
}
}
/** Replace one session's stored record with its log identity and a detached snapshot of `rows`. */
private async put(id: SessionId, identity: CheckpointIdentity, rows: ProjectionCheckpoint): Promise<void> {
const detached = snapshotJsonValue(rows)
if (detached === undefined) {
throw new TypeError('projection checkpoint is not losslessly JSON-serializable (a unit state violates the plain-JSON contract)')
}
await this.requireTable().put(id, { identity, rows: detached as CheckpointRecord['rows'] })
}
/** Fail-soft {@link put}: cache writes must never fail their caller's read or event path. */
private async putSoft(id: SessionId, identity: CheckpointIdentity, rows: ProjectionCheckpoint, what: string): Promise<void> {
try {
await this.put(id, identity, rows)
} catch (error) {
this.ctx.logger.warn(`session projection cache: ${what} for "${id}" failed (cache stays stale): ${String(error)}`)
}
}
private requireTable(): KvTable<SessionId, CheckpointRecord> {
/* v8 ignore next -- Service.init assigns the table before the service becomes injectable */
if (this.table === undefined) throw new Error('session projection cache is not initialized')
return this.table
}
}
/** Project a header onto the identity fields a record is bound to. */
function identityOf(header: SessionHeader): CheckpointIdentity {
return { createdAt: header.createdAt, ...header.cwd === undefined ? {} : { cwd: header.cwd } }
}
/** Whether a stored record's bound identity names the caller's lifecycle. */
function identityMatches(stored: CheckpointIdentity, expected: CheckpointIdentity): boolean {
return stored.createdAt === expected.createdAt && stored.cwd === expected.cwdView on GitHub (pinned to b150a551b8)
Solutions
- Check the projection cache storage (path, permissions, disk); the cache stays stale until the operation succeeds.
When it happens
Trigger: Thrown at packages/session/session-projection-cache/src/index.ts:278 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/9cd72e088ed9d19b.
Report an issue: GitHub.