pub async fn with_retry<F, Fut, T>(max_retries: u32, f: F) -> Result<T>where F: FnMut() -> Fut, Fut: Future<Output = Result<T>>,