googleapis / googleapis/google-api-ruby-client

google-apis-core: singular PagedResults ignores max

Aperta
#27,759 0 commenti 0 reazioni 1 assegnatario Rivendicata da @quartzmo Vedi su GitHub
Lingua principale
Ruby
Stelle
2.9k
Fork
888
Merge medio
6m
PR unite (30g)
218

Descrizione

`Google::Apis::Core::PagedResults#fetch_all` does not increment `item_count` in the singular-result branch. A sequence of singular pages therefore ignores `max` and yields every item.

A three-page model with `max: 2` currently yields all 3. Incrementing after the singular yield makes it stop after the first 2, matching the collection branch and documented limit.

The focused candidate passes 98 targeted examples and the cumulative 509-example core suite on Ruby 4.0.6. I found no open issue/PR overlap. I have a minimal patch ready and can submit it after maintainer acceptance per CONTRIBUTING. The source audit and candidate preparation used AI assistance; I reviewed and verified the result.

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.