The signatureEvery follow-up fails only in one Session; the same provider and workspace work in a new conversation.

Confirm the durable loop.

01Tool call streams

Its inner arguments JSON ends mid-string or before a closing delimiter.

02Provider returns 400

Unterminated string or another JSON parse diagnostic.

03Same Session repeats

Every later message rebuilds and resends the stored call.

04Fresh Session works

The account, route, and workspace are no longer the leading suspects.

Recover without rewriting history.

  1. CancelStop the active turn and prove provider usage stops.
  2. ExportChoose Session log; keep the downloaded ZIP unchanged.
  3. Restart cleanCreate a new conversation and carry over only minimal task context.
  4. Prove isolationRun one bounded read-only prompt before restoring tools.
  5. ArchiveKeep the old Session for diagnosis, not normal use.

Separate the physical and logical files.

Live persistencesession.jsonl.zstd

Checksummed Zstandard frames. One live writer. Do not edit or replace in place.

Downloaded evidencesession.jsonl

Logical decoded rows inside the export ZIP. Inspect a copy, read-only.

The outer JSON can still be valid.

{"type":"tool/call","seq":42,
 "data":{"name":"read",
 "arguments":"{\"file_path\":\"C:\\\\work\\\\file.ts"}}

Parse the event row first, then parse event.data.arguments separately. The malformed value is the JSON string inside the valid event envelope.

Do not turn diagnosis into corruption.

No live-file edits

Compression, checksums, identity, and sequence continuity are enforced.

No blind {}

The original call may already have reached scheduling. Verify external effects.

No endless Retry

The same durable value remains in reconstructed history.

Primary evidence.

Keep the full incident runbook.

The canonical guide includes the complete source chain, a read-only detector, unsafe-repair warnings, and a minimal report template.

Read and star on GitHub