fix(pagination): handle out-of-bounds slicing in pagination #12

Merged
argoyle merged 1 commits from fix-pagination-out-of-bounds-slicing into main 2025-06-15 18:00:16 +00:00
argoyle commented 2025-06-15 17:56:59 +00:00 (Migrated from gitlab.com)

Ensure the pagination function correctly handles out-of-bounds indices
when slicing items. Update the slice logic to prevent slice bounds
errors and add a test case for better coverage of edge cases.

Ensure the pagination function correctly handles out-of-bounds indices when slicing items. Update the slice logic to prevent slice bounds errors and add a test case for better coverage of edge cases.
argoyle (Migrated from gitlab.com) scheduled this pull request to auto merge when all checks succeed 2025-06-15 17:57:06 +00:00
argoyle (Migrated from gitlab.com) merged commit into main 2025-06-15 18:00:17 +00:00
argoyle commented 2025-06-15 18:00:28 +00:00 (Migrated from gitlab.com)

Codecov Report

All modified and coverable lines are covered by tests

Project coverage is 64.19%. Comparing base (0e8ba09) to head (bb3f732).

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #11   +/-   ##
=======================================
  Coverage   64.19%   64.19%           
=======================================
  Files           1        1           
  Lines          81       81           
=======================================
  Hits           52       52           
  Misses         28       28           
  Partials        1        1           

View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
## [Codecov](https://app.codecov.io/gl/unboundsoftware/pagination/pull/11?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=gitlab&utm_content=comment&utm_campaign=pr+comments&utm_term=unboundsoftware) Report All modified and coverable lines are covered by tests :white_check_mark: > Project coverage is 64.19%. Comparing base [(`0e8ba09`)](https://app.codecov.io/gl/unboundsoftware/pagination/commit/0e8ba09d6239157abaf535161b35379371ee354a?dropdown=coverage&el=desc&utm_medium=referral&utm_source=gitlab&utm_content=comment&utm_campaign=pr+comments&utm_term=unboundsoftware) to head [(`bb3f732`)](https://app.codecov.io/gl/unboundsoftware/pagination/commit/bb3f7327cdf7bb2372e240940b3cabd0930fedb4?dropdown=coverage&el=desc&utm_medium=referral&utm_source=gitlab&utm_content=comment&utm_campaign=pr+comments&utm_term=unboundsoftware). <details><summary>Additional details and impacted files</summary> ```diff @@ Coverage Diff @@ ## main #11 +/- ## ======================================= Coverage 64.19% 64.19% ======================================= Files 1 1 Lines 81 81 ======================================= Hits 52 52 Misses 28 28 Partials 1 1 ``` </details> [:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gl/unboundsoftware/pagination/pull/11?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=gitlab&utm_content=comment&utm_campaign=pr+comments&utm_term=unboundsoftware). :loudspeaker: Have feedback on the report? [Share it here](https://gitlab.com/codecov-open-source/codecov-user-feedback/-/issues/4). <details><summary> :rocket: New features to boost your workflow: </summary> - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems. </details>
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: unboundsoftware/pagination#12