-
-
Notifications
You must be signed in to change notification settings - Fork 599
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
Added params argument for Labels and Search #1008
base: master
Are you sure you want to change the base?
Conversation
Why can't you use the lazy fetch method from the paginator, and only look at the first n things? |
I only need the first 100 results. I am not interested in creating a paginator when I dont need it. |
I've fixed the CS issues. This PR will make the Search and Labels API more consistent with other APIs. |
I'd recommend using |
Using
It would also lead to that user can send any valid parameter to the API server... I think that is a good feature for the API client. |
I also do not see any harm in adding this PR You can still document the alternative of a fetchAllLazy and how it works, its pros and cons etc, separately. |
While I think @GrahamCampbell is correct that we should point users to the On the points @Nyholm raised
|
I think that would be a nice idea. Maybe just call it |
I've stumbled upon this myself when trying to access subsequent pages of some GitHub API's within specific user web requests. I would expect to be able to query for a specific page (where I am entirely not interested in first couple pages). Otherwise I am required to perform http requests and iterate over results that I do not need. |
Since we cannot use
setPerPage()
in 3.0, we need to be able to specify theper_page
parameter without using a pager.