pub async fn connect_to_launcher(
state: Arc<AppState>,
) -> Option<LauncherIpcHandle>Expand description
If AGENTMUX_LAUNCHER_PIPE is set, connect, Register as Host,
and return a handle the caller (host main.rs) holds for the
host’s lifetime. If unset → return None and the host runs in
pre-Phase-B mode (no launcher connection).
Errors are logged but non-fatal: a launcher-IPC failure should NOT prevent the host from running, since the launcher’s authoritative state is still in environment / files for B.2. Phase B.5+ will tighten this when the host actually depends on IPC for state.