server: map generic one-shot exit to done/failed (#10)

set_exited always forced lifecycle=exited and ignored the exit code, so
a fast process that finished before `wait --until done` armed hung until
timeout. Product intent (and docs/03, docs/07) is that done/failed persist
after PTY exit: Generic/None panes map exit 0→done and nonzero→failed;
known agents keep Exited unless hooks already recorded Done/Failed.

Co-authored-by: Lucenx9 <185146821+Lucenx9@users.noreply.github.com>
1faa0b1485Simone committed on 10/4/2026, 2:02:24 PM· committed by GitHubparent802c150
2 files changedLine totals unavailable