Skip to content

Commit

Permalink
Add debug output for PR release matching
Browse files Browse the repository at this point in the history
  • Loading branch information
rvermeulen committed Sep 20, 2023
1 parent 51890d1 commit 3aaab17
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/release/update-release-assets.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,11 @@ def main(args: 'argparse.Namespace') -> int:
print(f"Error: invalid version {release_version} use by release branch. Reason {e}", file=sys.stderr)
return 1

releases = [release for release in repo.get_releases() if release.tag_name == f"v{release_version}"]
print(f"Looking for release with tag v{release_version} associated with the PR's base ref {pull_request.base.ref}")
all_releases = repo.get_releases()
for release in all_releases:
print(f"Found release {release.title} with tag {release.tag_name}")
releases = [release for release in all_releases if release.tag_name == f"v{release_version}"]
if len(releases) != 1:
print(f"Error: expected exactly one release for {release_version}, but found {len(releases)}", file=sys.stderr)
return 1
Expand Down

0 comments on commit 3aaab17

Please sign in to comment.