-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEAT]: Octokit::Client::PullRequests#pull_requests should accept a block. #1508
Comments
👋 Hey Friends, this issue has been automatically marked as |
🤔
…On Fri, Apr 19, 2024, at 6:46 PM, github-actions[bot] wrote:
👋 Hey Friends, this issue has been automatically marked as `stale` because it has no recent activity. It will be closed if no further activity occurs. Please add the `Status: Pinned` label if you feel that this issue needs to remain open/active. Thank you for your contributions and help in keeping things tidy!
—
Reply to this email directly, view it on GitHub <#1508 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AABAF2U26SQXKNBCDH5L2HLY6HCGZAVCNFSM6AAAAAAR7OMVC6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANRXGUYDMNZWGA>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
👋 Hey Friends, this issue has been automatically marked as |
I can’t battle the bot. It will never become tired. |
Describe the need
It is nice to use auto_paginate, but sometimes it is nice to also interrupt pagination when I have found the results I'm looking for.
It looks like
paginate
accepts a block, butpull_requests
does not. It would be nice to be able to pass a block topull_requests
in order to process each page as it is fetched and, further, so that pagination may be interrupted with an exception if desired.The current alternatives are:
pull_requests
with auto_paginate and assume the time cost of receiving every page of resultsExample use case: I want all PRs merged after a given time. Best I can tell, the github pull_requests api doesn't allow this granularity, so one search pull requests by date and then stop paginating once we find the first pull that's older than the requested time.
SDK Version
No response
API Version
No response
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: