import requests


def get_latest_release(username: str, repo: str) -> str:
    """Get the latest release tag from a github repository."""
    response = requests.get(
        f"https://api.github.com/repos/{username}/{repo}/releases/latest",
        allow_redirects=True,
    )

    tag_name = response.json()["tag_name"]

    return tag_name