From cbd75b83ad026644d9edea00a24df9cc98bcf9ca Mon Sep 17 00:00:00 2001 From: Maximilian Schulz Date: Mon, 28 Oct 2024 18:15:19 +0100 Subject: [PATCH] Work with non-resent whl file --- tools/pycafe/create_pycafe_links.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/pycafe/create_pycafe_links.py b/tools/pycafe/create_pycafe_links.py index e5d729363..fbd221059 100644 --- a/tools/pycafe/create_pycafe_links.py +++ b/tools/pycafe/create_pycafe_links.py @@ -10,14 +10,16 @@ from typing import Optional from urllib.parse import quote, urlencode +import vizro from github import Auth, Github +PACKAGE_VERSION = vizro.__version__ + GITHUB_TOKEN = sys.argv[1] REPO_NAME = sys.argv[2] PR_NUMBER = int(sys.argv[3]) RUN_ID = sys.argv[4] COMMIT_SHA = sys.argv[5] -WHL_FILE = next(Path("dist").glob("*.whl")).name PYCAFE_URL = "https://py.cafe" VIZRO_RAW_URL = "https://raw.githubusercontent.com/mckinsey/vizro" @@ -48,7 +50,7 @@ def generate_link(directory: str, extra_requirements: Optional[list[str]] = None filter( None, [ - f"{PYCAFE_URL}/gh/artifact/mckinsey/vizro/actions/runs/{RUN_ID}/pip/{WHL_FILE}", + f"{PYCAFE_URL}/gh/artifact/mckinsey/vizro/actions/runs/{RUN_ID}/pip/vizro-{PACKAGE_VERSION}-py3-none-any.whl", *(extra_requirements or []), ], )