def check_prerelease(repo, latest_tag, github_account, force):
    """Returns true if the repo is in a valid state for release.

    Checks that:
        1. there has been at least one commit since the last tag.
        2. all authors since the last tag were `github_account`, unless `force`
            is true.

    Args:
        repo (Repository): the repo to validate.
        github_account (GitHubAccount, optional): the GitHub account to
            validate author emails against.
        latest_tag (str): the latest tag.
        force (bool, optional): if true, the check that all authors since the
            last tag were `github_account` is ignored.

    Returns:
        bool: whether or not to proceed with a release.
    """
    authors = repo.authors_since(latest_tag)
    if not authors:
        return False
    if force:
        return True
    if not all([x == github_account.email for x in authors]):
        return False
    return True