add assert message to get_repo_token

This commit is contained in:
Jörg Thalheim 2024-06-07 16:50:03 +02:00
parent 8664657737
commit 4357604463

View file

@ -390,7 +390,7 @@ class GithubAppAuthBackend(GithubAuthBackend):
return self.jwt_token return self.jwt_token
def get_repo_token(self, repo: dict[str, Any]) -> RepoToken: def get_repo_token(self, repo: dict[str, Any]) -> RepoToken:
assert "installation_id" in repo assert "installation_id" in repo, f"Missing installation_id in {repo}"
return self.installation_tokens[repo["installation_id"]] return self.installation_tokens[repo["installation_id"]]
def create_secret_providers(self) -> list[SecretProviderBase]: def create_secret_providers(self) -> list[SecretProviderBase]: