pub fn format_error(
    fmt: &mut Formatter<'_>,
    title: &str,
    message: Option<&str>,
    source: Option<&dyn Error>
) -> Result