def format_error(self, exception: BaseException) -> str:
        """Writes errors in a readable format.

        Args:
            exception: Exception raised.

        Returns:
            Formatted error message.
        """
        error_details = str(exception) or "None"
        return f"{exception.__class__.__name__}. Details: {error_details}"
Writes errors in a readable format.

        Args:
            exception: Exception raised.

        Returns:
            Formatted error message.
        
lightly/api/retry_utils.py