pub async fn wait_for<F, Fut>(f: F)where F: FnMut() -> Fut, Fut: Future<Output = bool> + Send + 'static,