pub async fn read_frame<R>(r: &mut R) -> Result<Frame, CliError>where
R: AsyncReadExt + Unpin,Expand description
Read one length-prefixed rkyv-archived Frame from r.
ยงCancel safety
This function is NOT cancel-safe. AsyncReadExt::read_exact may
partially consume bytes from the stream before the future is dropped,
leaving the connection in an undefined framing state. Callers that
race this against another future (e.g. via tokio::select! on a
shutdown signal) MUST abort the connection on cancellation rather
than re-entering read_frame on the same stream.