pub fn to_string_pretty<T>(value: &T) -> Result<String, Error> where
    T: ?Sized + Serialize