def exit_with_log(message, severity=logging.warning, exit_return_code=1):
    """
    Ends the whole script with a warning.
    :param message:
    :param exit_return_code:
    :return:
    """
    severity(f"{project_code};{current_proc_hash};{exit_return_code};;{message}")
    exit()