def read_text(file_location, not_exists_ok=False):
    """Read text from a file

    Args:
        file_location (str): Location of file
        not_exists_ok (bool, optional): If True and file does not exist, will return "" instead of throw an exception. Defaults to False.

    Returns:
        str: The text in the file, stripped of whitepace at the end
    """
    try:
        with open(file_location, "r") as f:
            return f.read().strip()
    except FileNotFoundError:
        if not not_exists_ok:
            raise
        else:
            return ""