Function async_anyhow_logger::catch_with_context[][src]

pub async fn catch_with_context<O, C, F>(context: C, future: F) where
    O: Display + Send + Sync + 'static,
    C: FnOnce() -> O,
    F: Future<Output = Result<()>>, 

Catch an error from an asynchronous function, passing it to the error logger with a context lazily evaluated from a closure.

See anyhow::Context::with_context