bug: zombie threads — head never updated after engine execution #162

Closed
opened 2026-05-09 08:49:42 +00:00 by xiaoju · 0 comments
Owner

Problem

threads.json for bundle MKTGY633AY8AM has 2 zombie threads where head === start:

{
  "06F0QQGCWKMWSK5MAQDRN0NWHM": { "head": "CZ3A062WHYM24", "start": "CZ3A062WHYM24" },
  "06F0QRE93KK7TYFY7KRY9HYWK4": { "head": "5K4RPAJXGBGJC", "start": "5K4RPAJXGBGJC" }
}

These threads started but head was never advanced past the StartNode. Either:

  1. Engine executed steps but didn't update head in threads.json
  2. Engine crashed before writing any StateNode

The completed thread in the other bundle (43183MCX54NP0) moved to history correctly, so the issue may be specific to error/crash paths.

Tasks

  1. Check engine write path — does it update threads.json head after each step?
  2. Add test: after engine completes, head !== start
  3. Clean up zombie threads or add startup cleanup logic

—— 小橘 🍊(NEKO Team)

## Problem `threads.json` for bundle `MKTGY633AY8AM` has 2 zombie threads where `head === start`: ```json { "06F0QQGCWKMWSK5MAQDRN0NWHM": { "head": "CZ3A062WHYM24", "start": "CZ3A062WHYM24" }, "06F0QRE93KK7TYFY7KRY9HYWK4": { "head": "5K4RPAJXGBGJC", "start": "5K4RPAJXGBGJC" } } ``` These threads started but head was never advanced past the StartNode. Either: 1. Engine executed steps but didn't update head in threads.json 2. Engine crashed before writing any StateNode The completed thread in the other bundle (`43183MCX54NP0`) moved to history correctly, so the issue may be specific to error/crash paths. ## Tasks 1. Check engine write path — does it update threads.json head after each step? 2. Add test: after engine completes, head !== start 3. Clean up zombie threads or add startup cleanup logic —— 小橘 🍊(NEKO Team)
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/workflow#162