pub(crate) fn spawn_reader_task(
subprocess: Subprocess,
dispatch: ControlDispatchHandle,
pending_controls: Arc<Mutex<HashMap<String, Sender<Result<Value, Error>>>>>,
events_tx: UnboundedSender<Result<Message, Error>>,
pre_init_messages: Vec<Message>,
shutdown_rx: Receiver<()>,
) -> JoinHandle<()> ⓘExpand description
Spawn the post-init reader task.
Pre-pumps pre_init_messages into events_tx first, then runs the
main read loop. On shutdown signal (or EOF / I/O error / closed
events channel), closes the transport and drains pending controls
with an EOF error so blocked send_control callers wake up.