def _invalid_token(token: str) -> bool:
    """
    A token is invalid if it contains a dash or an underscore.

    Args:
        token : Token to validate

    Returns:
        True if the token is invalid (e.g. it contains a '-' or '_')
    """
    return "-" in token or "_" in token