Skip to content

Fix redundant API call in gh issue view --comments (#12606)#12652

Open
VishnuVV27 wants to merge 1 commit intocli:trunkfrom
VishnuVV27:fix-issue-view-comments-redundancy
Open

Fix redundant API call in gh issue view --comments (#12606)#12652
VishnuVV27 wants to merge 1 commit intocli:trunkfrom
VishnuVV27:fix-issue-view-comments-redundancy

Conversation

@VishnuVV27
Copy link

This PR fixes a redundant API call in 'gh issue view --comments' by returning early if no more pages are available

Changes

  • Added early return in 'preloadIssueComments' if 'HasNextPage' is false.
  • Removed stale FIXME comment.
  • Updated test fixtures to maintain pagination coverage.

Verification

@VishnuVV27 VishnuVV27 requested a review from a team as a code owner February 9, 2026 10:12
@VishnuVV27 VishnuVV27 requested a review from BagToad February 9, 2026 10:12
@cliAutomation cliAutomation added the external pull request originating outside of the CLI core team label Feb 9, 2026
@github-actions
Copy link

github-actions bot commented Feb 9, 2026

Thank you for your pull request! 🎉

This PR appears to fix the following issues that are not labeled with help wanted Contributions welcome :

As outlined in our Contributing Guidelines, we expect that PRs are only created for issues that have been labeled help wanted.

While we appreciate your initiative, please note that:

  • PRs for non-help wanted issues may not be reviewed immediately as they might not align with our current priorities
  • The issue might already be assigned to a team member or planned for a specific release
  • We may need to close this PR. For example, if it conflicts with ongoing work or architectural decisions

What happens next:

  • Our team will review this PR and the associated issues
  • We may add the help wanted label to the issues, if appropriate, and review this pull request
  • In some cases, we may need to close the PR. For example, if it doesn't fit our current roadmap

Thank you for your understanding and contribution to the project! 🙏

This comment was automatically generated by cliAutomation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external pull request originating outside of the CLI core team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

'gh issue view --comments' re-fetches first page of comments unnecessarily

2 participants