import six


def _annotator_error_msg(ex):
    """
    Formats a human readable error message.

    :param ex:
    :return:
    """
    if isinstance(ex, six.string_types):
        return ex

    return '\n' + ex.__class__.__name__ + ': ' + str(ex) + '\n\n'