langgraph checkpoint left a 1.8gb sqlite in /tmp
weekend eval loop on my M1. 40-node graph, checkpoint every node "just in case".
woke up to mac screaming about disk. /tmp/lg_ckpt.sqlite was 1.8gb. Activity Monitor still had three python workers holding the file open so Finder wouldn't delete it.
claude code's fix was rm -rf /tmp/lg* — which would've also eaten a half-finished export I actually needed. i killed the workers first, then pruned with a 50-checkpoint cap.
anyone else hard-cap checkpoints, or am i the only one learning this the expensive way?

5 comments
Join the discussion
Log in to comment.
same energy as ollama dumping model blobs into ~/.ollama until the SSD cries. i put checkpoints on a 4gb ramdisk now — fills up, loop dies, mac lives. also never let the agent invent cleanup paths. it will invent the wrong one.
hard cap yes. i keep max 20 checkpoints and a wall-clock timeout on the graph. without both, the loop just writes forever and you pay in disk not tokens. also: never accept
rm -rffrom the agent. read it twice.lol this is my tuesday. MemorySaver writing to
/tmpon a DO droplet — 900mb overnight, then the agent couldn't even start because no space left for pip cache.moved checkpoints to a dedicated volume with
max_count=10and sqlite WAL. still grows but at least it dies polite instead of eating the root disk.also never accept
rm -rf /tmp/*from the agent. i almost lost a half-written eval dump the same way last week.Activity Monitor lying about open file handles again. classic.
on the Mac Studio i bind LangGraph checkpoints to
~/ckpton the external SSD and setcheckpoint_nsper run so one bad loop can't fill the boot volume. alsodu -sh ~/ckpt/*in a cron every 15m — crosses 500mb, kill the graph.the agent suggesting
rm -rf /tmp/lg*is the part that gets me. it always picks the wrong glob.sorry english not perfect — same thing on my eval box last month. SqliteSaver with checkpoint every node on a 60-step graph ≈ 28mb per run × overnight = disk full.
i use MemorySaver for local smoke tests now, SqliteSaver only when i need resume, always with TTL. hard cap is good idea.
did you measure how many checkpoints before it hit 1.8gb? curious about bytes-per-node on M1.