Since #4717, loadGraph() skips lines that fail to parse or validate. The mutations still call saveGraph() with the filtered graph, which rewrites the whole file, so the next unrelated write deletes those lines for good. The tool call reports success.
Reproduction on main (f46d957), starting from this memory.jsonl:
{"type":"entity","name":"Alice","entityType":"person","observations":["Works at Acme","Prefers email"]}
{"type":"entity","name":"Bob","entityType":"person","observations":["Allergic to penicillin","Lives in Haifa",null]}
{"type":"entity","name":"Project X","observations":["Deadline 2026-10-01","Budget 40k"]}
{"type":"relation","from":"Alice","to":"Bob","relationType":"manages"}
After create_entities for an unrelated entity (Carol), the file is:
{"type":"entity","name":"Alice","entityType":"person","observations":["Works at Acme","Prefers email"]}
{"type":"entity","name":"Carol","entityType":"person","observations":["New hire"]}
{"type":"relation","from":"Alice","to":"Bob","relationType":"manages"}
Bob loses both valid observations because of one null, Project X is gone, and the Alice-Bob relation now points to a deleted entity.
The other kinds of line from earlier reports behave the same way on main: a truncated line (#1481), two objects on one line (#1819, #3173), and a relation without relationType. The published 2026.8.31 predates #4717 and fails on these files instead of deleting them, so this is not released yet. Lines with an unknown type were already dropped before #4717.
I'll open a PR that keeps skipping these lines in memory but writes them back unchanged on save.
Recorded runs for main, 2026.8.31 and the fix (tool calls, responses, file before and after), with a script to reproduce them: https://github.com/yotambraun/agent-eval-flow/tree/f184978b4224aaff39e125fd0b25075e4af00532/examples/data/mcp-memory
Since #4717,
loadGraph()skips lines that fail to parse or validate. The mutations still callsaveGraph()with the filtered graph, which rewrites the whole file, so the next unrelated write deletes those lines for good. The tool call reports success.Reproduction on main (f46d957), starting from this
memory.jsonl:After
create_entitiesfor an unrelated entity (Carol), the file is:Bob loses both valid observations because of one
null, Project X is gone, and the Alice-Bob relation now points to a deleted entity.The other kinds of line from earlier reports behave the same way on main: a truncated line (#1481), two objects on one line (#1819, #3173), and a relation without
relationType. The published 2026.8.31 predates #4717 and fails on these files instead of deleting them, so this is not released yet. Lines with an unknowntypewere already dropped before #4717.I'll open a PR that keeps skipping these lines in memory but writes them back unchanged on save.
Recorded runs for main, 2026.8.31 and the fix (tool calls, responses, file before and after), with a script to reproduce them: https://github.com/yotambraun/agent-eval-flow/tree/f184978b4224aaff39e125fd0b25075e4af00532/examples/data/mcp-memory