From 08ce6649c84dd66d354ccaa5f4db4e8e5c69308a Mon Sep 17 00:00:00 2001 From: poikilos <7557867+poikilos@users.noreply.github.com> Date: Tue, 3 May 2022 20:47:30 -0400 Subject: [PATCH] Clarify output when page 1 has no issues when listing by label (Fix #570). --- utilities/enissue.py | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/utilities/enissue.py b/utilities/enissue.py index 223c76b..e2cc503 100755 --- a/utilities/enissue.py +++ b/utilities/enissue.py @@ -2307,6 +2307,9 @@ def main(): else: sys.exit(1) total_count = 0 + print() + # ^ This blank line goes after "@ Cache" messages and before + # the issues list. if mode == "labels": if repo.labels is None: print("There were no labels.") @@ -2404,13 +2407,10 @@ def main(): elif mode == "list": print() if len(match_all_labels) > 0: - print("{} issue(s) matched {}".format( - match['count'], - " + ".join("'{}'".format(s) for s in match_all_labels) - )) if total_count >= repo.page_size: - print("{} searched, which is the maximum number" - " per page.".format(total_count)) + print("{} found but only {} searched, which is the" + " maximum number per page." + "".format(match['count'], total_count)) next_page = 2 if repo.page is not None: next_page = repo.page + 1 @@ -2418,6 +2418,12 @@ def main(): + " page " + str(next_page)) print("to see additional pages.") + else: + print("{} issue(s) matched {}".format( + match['count'], + " + ".join("'{}'".format(s) for s in match_all_labels) + )) + else: if repo.page is not None: print("{} issue(s) are showing for page"