nit: clarify truncation detection comment in ListReviews
PR Ready Gate / clear-labels (pull_request) Successful in 2s
CI / test (pull_request) Successful in 19s
CI / review (gpt-5, security, ., rodin/security-patterns, SECURITY_REVIEW.md, SECURITY_REVIEW_TOKEN) (pull_request) Successful in 39s
CI / review (anthropic--claude-4.6-sonnet, sonnet, SONNET_REVIEW_TOKEN) (pull_request) Successful in 39s
CI / review (gpt-5, gpt, GPT_REVIEW_TOKEN) (pull_request) Successful in 59s
PR Ready Gate / clear-labels (pull_request) Successful in 2s
CI / test (pull_request) Successful in 19s
CI / review (gpt-5, security, ., rodin/security-patterns, SECURITY_REVIEW.md, SECURITY_REVIEW_TOKEN) (pull_request) Successful in 39s
CI / review (anthropic--claude-4.6-sonnet, sonnet, SONNET_REVIEW_TOKEN) (pull_request) Successful in 39s
CI / review (gpt-5, gpt, GPT_REVIEW_TOKEN) (pull_request) Successful in 59s
Expand the inline comment at the page==maxPages check to more explicitly explain why a full final page implies truncation.
This commit is contained in:
+4
-2
@@ -197,8 +197,10 @@ func (c *Client) ListReviews(ctx context.Context, owner, repo string, number int
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
// If we just fetched page maxPages and it was full (the short-page break
|
// Truncation detection: this runs on the final allowed iteration
|
||||||
// above didn't fire), more reviews likely exist beyond our limit.
|
// (page == maxPages) only when the page was full (the len < perPage
|
||||||
|
// early-break above didn't fire). A full final page means additional
|
||||||
|
// reviews likely exist beyond our pagination limit.
|
||||||
if page == maxPages {
|
if page == maxPages {
|
||||||
truncated = true
|
truncated = true
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user