Skip to content

Commit b5be64e

Browse files
committed
wip
1 parent 3f2e5d8 commit b5be64e

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

src/release_tool/commands/push.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1331,7 +1331,18 @@ def _find_existing_issue_auto(config: Config, github_client: GitHubClient, versi
13311331
console.print(f"[dim]Searching for open issues matching version {version}...[/dim]")
13321332

13331333
# Search for open issues matching the version
1334-
issues = list(github_client.gh.search_issues(query)[:5])
1334+
# Safely iterate and collect up to 5 results
1335+
issues = []
1336+
try:
1337+
search_results = github_client.gh.search_issues(query)
1338+
for i, issue in enumerate(search_results):
1339+
if i >= 5:
1340+
break
1341+
issues.append(issue)
1342+
except Exception as e:
1343+
if debug:
1344+
console.print(f"[dim]Error searching for issues: {e}[/dim]")
1345+
return None
13351346

13361347
if not issues:
13371348
if debug:

0 commit comments

Comments
 (0)