posit-dev / posit-dev/connectapi
Allow setting page size separately from limit in `page_cursor()`
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 54
- Forks
- 27
- Avg merge
- 1d 3m
- Merged PRs (30d)
- 1
Description
page_cursor() currently has strange behavior where the limit argument controls both the total number of results and the page size, but in different ways.
- If
limit = Inf, page size is 500 and you get all results - If
limit > 500 & limit < Inf, page size is 500 and you getlimitresults - If
limit > 0 & limit <= 500, page size islimitand you getlimitresults
There is no way to, say, set the page size and limit to different values unless limit > 500. We should expose more flexibility here.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in R/connect.R around line 725, where page_cursor() currently derives page size and total results from limit. Determine an interface that permits those values to differ, then verify that the existing limit behaviors remain intact and that separate page-size and total-result values work as intended.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100