pub fn reap_finished(registry: &Arc<Mutex<SubagentRegistry>>)Expand description
Engine-owned housekeeping seam: reap finished subagent handles at end of each turn. Acquires the lock poison-safely — a panicked subagent thread must not prevent the turn from completing.
Intended to be called from the tokio::spawn wrapper in runtime/mod.rs
after run_stream_internal returns and BEFORE sending SessionEvent::Done.