def get_log_file_from_item(history):
    """
    Return the log file based on provided history item.

    Description is optional.
    """
    try:
        log_file, description = shlex.split(history)
    except ValueError:
        log_file = history.strip()

    return log_file