pub async fn encode_response<B, F, E>( resp: Response<B>, stream_id: u64, emit: F, ) -> Result<(), StreamEncodeError<E>>where B: Body + Unpin, B::Data: Buf, B::Error: Error + Send + Sync + 'static, F: FnMut(HttpPackStreamMessage) -> Result<(), E>,