From 51620488512ab115d8e4237dfbdfdc9af629a804 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Thu, 9 Nov 2023 11:30:53 -0600 Subject: [PATCH] Fix get_cirun_installation_id --- conda_smithy/cirun_utils.py | 4 ++-- news/cirun_id.rst | 23 +++++++++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 news/cirun_id.rst diff --git a/conda_smithy/cirun_utils.py b/conda_smithy/cirun_utils.py index d6c6fd245..4d36e65b3 100644 --- a/conda_smithy/cirun_utils.py +++ b/conda_smithy/cirun_utils.py @@ -16,13 +16,13 @@ def get_cirun_installation_id(owner: str) -> int: if owner == "conda-forge": return 18453316 else: - gh = Github(gh_token) + gh = Github(gh_token()) user = gh.get_user() if user.login == owner: user_or_org = user else: user_or_org = gh.get_organization(owner) - for inst in user_or_org.get_installations: + for inst in user_or_org.get_installations(): if inst.raw_data["app_slug"] == "cirun-application": return inst.app_id raise ValueError(f"cirun not found for owner {owner}") diff --git a/news/cirun_id.rst b/news/cirun_id.rst new file mode 100644 index 000000000..787a68d0e --- /dev/null +++ b/news/cirun_id.rst @@ -0,0 +1,23 @@ +**Added:** + +* + +**Changed:** + +* + +**Deprecated:** + +* + +**Removed:** + +* + +**Fixed:** + +* Fixed getting cirun installation id for non conda-forge orgs (#1795). + +**Security:** + +*