def exc_message(e):
    """
    In python 3.x, when an exception is reraised it saves original
    exception in its args, therefore in order to find the actual
    message, we need to unpack arguments recursively.
    """
    msg = e.args[0]
    if isinstance(msg, Exception):
        return exc_message(msg)
    return msg