Skip to content

MM-46: Pagination improvements and logging - #2577

Merged
craiglurey merged 1 commit into
releasefrom
fix/delinea-pagination-bug
Nov 26, 2026
Merged

craiglurey merged 1 commit into
releasefrom
fix/delinea-pagination-bug

Conversation

@stripathi-ks

Copy link
Copy Markdown
Contributor
  • Pagination improvements and logging

The loop also had no page log, and two exits were unsafe. A short page, including a last page of 1 record, was kept but not logged. hasNext: true with a nextSkip that does not advance skipped forever. A body with no records list stopped with no log. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A nextSkip that does not move, or a missing records list, logs a warning and stops with the records already collected.

thycotic_search already paged. It did not log each page, and a hasNext value of true with a nextSkip that did not advance would request the same page forever. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A page shorter than 1000, including a last page of 1 record, is kept and logged. A missing records list, a non-object body, or a nextSkip that does not move forward logs a warning and stops with the records already collected.

  • Move per-page pagination logs to debug level, refine short page condition to count < take, add edge case test

  • Pagination: fix duplicate param check, refactor for clarity, fix test logging

  • Address reviewer feedback: JSON error handling, query deduplication, truncated status

  • update names, and valueError


* Pagination improvements and logging

The loop also had no page log, and two exits were unsafe. A short page, including a last page of 1 record, was kept but not logged. hasNext: true with a nextSkip that does not advance skipped forever. A body with no records list stopped with no log. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A nextSkip that does not move, or a missing records list, logs a warning and stops with the records already collected.

thycotic_search already paged. It did not log each page, and a hasNext value of true with a nextSkip that did not advance would request the same page forever. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A page shorter than 1000, including a last page of 1 record, is kept and logged. A missing records list, a non-object body, or a nextSkip that does not move forward logs a warning and stops with the records already collected.

* Move per-page pagination logs to debug level, refine short page condition to count < take, add edge case test

* Pagination: fix duplicate param check, refactor for clarity, fix test logging

* Address reviewer feedback: JSON error handling, query deduplication, truncated status

* update names, and valueError

---------

Co-authored-by: Aditya J. <ajaiswal@keepersecurity.com>
@stripathi-ks stripathi-ks changed the title Pagination improvements and logging (#2568) Pagination improvements and logging Nov 26, 2026
@stripathi-ks stripathi-ks changed the title Pagination improvements and logging MM-46: Pagination improvements and logging Nov 26, 2026
@craiglurey
craiglurey merged commit 3515d26 into release Nov 26, 2026
4 checks passed
@sk-keeper
sk-keeper deleted the fix/delinea-pagination-bug branch November 26, 2026 17:47
ajaiswal-ks added a commit that referenced this pull request Nov 27, 2026
* Pagination improvements and logging

The loop also had no page log, and two exits were unsafe. A short page, including a last page of 1 record, was kept but not logged. hasNext: true with a nextSkip that does not advance skipped forever. A body with no records list stopped with no log. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A nextSkip that does not move, or a missing records list, logs a warning and stops with the records already collected.

thycotic_search already paged. It did not log each page, and a hasNext value of true with a nextSkip that did not advance would request the same page forever. Each page now logs skip, take, records, total, hasNext, nextSkip, and the running total. A page shorter than 1000, including a last page of 1 record, is kept and logged. A missing records list, a non-object body, or a nextSkip that does not move forward logs a warning and stops with the records already collected.

* Move per-page pagination logs to debug level, refine short page condition to count < take, add edge case test

* Pagination: fix duplicate param check, refactor for clarity, fix test logging

* Address reviewer feedback: JSON error handling, query deduplication, truncated status

* update names, and valueError

---------

Co-authored-by: Aditya J. <ajaiswal@keepersecurity.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants