pub struct SessionWritesLostMessage {
pub error_code: SessionWriteErrorCode,
pub lost: Vec<LostSessionWrite>,
pub transcript_session_ids: Option<Vec<String>>,
pub uuid: String,
pub session_id: String,
}Expand description
system/session_writes_lost — the CLI could not save lines of a session
transcript, changes to ~/.claude.json, or both, because the disk was
full or its quota was used up. Sent at most once, as the CLI exits, after
the last result if there was one. The results already received stand,
and this message does not change the exit status. Sent only with
stream-json output on stdout, never under --sdk-url or a Claude Desktop
entrypoint. Safe to ignore (CLI 2.1.317+).
Fields§
§error_code: SessionWriteErrorCodeWhy the writes failed. When both kinds of write were lost for different reasons, the transcript’s.
lost: Vec<LostSessionWrite>What was not saved. Never empty.
transcript_session_ids: Option<Vec<String>>The sessions whose transcripts lost lines, in the order each first
lost one. Present only when LostSessionWrite::Transcript is
listed; never empty. Usually session_id alone; a CLI that started a
new session after the loss (as /clear does) lists the earlier
session, and lists session_id only if that session lost lines too.
uuid: String§session_id: StringThe session the CLI is in, as on every message; see
transcript_session_ids for whose
transcript lost lines.