From fa76b2a899b99a4d077e69c664a2dfd899426d3e Mon Sep 17 00:00:00 2001 From: Gabriel Freitas Date: Mon, 7 Jul 2025 11:18:51 -0300 Subject: [PATCH] Enhance update_mod_versions.py with detailed print statements for checking release tags and assets during processing --- .github/scripts/update_mod_versions.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/scripts/update_mod_versions.py b/.github/scripts/update_mod_versions.py index 819a0cf8..acd60fa0 100755 --- a/.github/scripts/update_mod_versions.py +++ b/.github/scripts/update_mod_versions.py @@ -197,16 +197,21 @@ def process_mod(start_timestamp, name, meta_file): source = VersionSource.HEAD new_version = get_version_string(VersionSource.HEAD, owner, repo, start_timestamp) elif (meta.get('fixed-release-tag-updates') == True): - print("Download URL links to specific tag, checking that tag...") source = VersionSource.SPECIFIC_TAG tag_data = {} if "/releases/download/" in download_url: # Pattern: /releases/download/{tag}/{file} - tag is second-to-last - tag_data['name'] = download_url.split('/')[-2] + print("Download URL links to specific release asset, checking that asset's tag...") + tag_name = download_url.split('/')[-2] + print(f"Checking release tag: {tag_name}") + tag_data['name'] = tag_name else: # Pattern: /releases/tag/{tag} - tag is last - tag_data['name'] = download_url.split('/')[-1] + print("Download URL links to specific release tag, checking that tag...") + tag_name = download_url.split('/')[-1] + print(f"Checking release tag: {tag_name}") + tag_data['name'] = tag_name new_version = get_version_string( source, owner, repo, start_timestamp, tag_data=tag_data