Skip to content

[2.1] Fixes #38295: keep Data Models and Stored Procedures pagination in sync - #38504

Merged
sweta1308 merged 1 commit into
2.1from
backport/2.1/pr-38309
Nov 23, 2026
Merged

sweta1308 merged 1 commit into
2.1from
backport/2.1/pr-38309

Conversation

@gh-bot-collate

@gh-bot-collate gh-bot-collate Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Automated backport of #38309 to 2.1.

Source PR #38309
Author @Kefia-02
Merge commit 6c8c3d89349c8592f7b709d34e36359d6b6b25be
Method Conflicts resolved by Claude — worth a read of the diff.

Resolution notes

Backport notes — PR #38309 → 2.1

Source: 6c8c3d89349c8592f7b709d34e36359d6b6b25be ("Fixes #38295: keep Data Models and Stored
Procedures pagination in sync").

Clean picks (no conflict)

  • NextPrevious.tsx / NextPrevious.test.tsx — the actual pagination fix: stop counting a
    phantom page past the known total (cursorTotalPages no longer adds 1 for paging.after once
    totalPages is already known), plus its regression test.
  • DataModelsTable.tsx / StoredProcedureTab.tsx — removed the URL→page sync useEffect that
    fought with usePaging's own state and caused the page to reset/stick.
  • DataModelsTable.integration.test.tsx / StoredProcedureTab.integration.test.tsx (new files) —
    regression tests asserting the page stays put after paging forward, mounted with a real
    MemoryRouter. Both applied cleanly against 2.1's existing component props/signatures.

Conflicted files — resolved by deletion (kept absent)

  • pages/ServiceDetailsPage/ServiceDataModels.browser.test.tsx
  • pages/StoredProcedure/StoredProcedureTab.browser.test.tsx

These conflicted as "deleted by us / modified by them": the source PR only edits these files (drops
the knownIssues.failing entries that used to mark the pagination bug as a known/expected failure,
now that it's fixed), but 2.1 does not have these files at all. They depend on a Vitest
browser-mode test helper, describePaginatedList/paginationContract (under
src/test/browser/), that was introduced on main in PR #36198 and was never backported to 2.1 —
there is no equivalent browser-test harness on this branch.

Since the files and their supporting infrastructure don't exist on 2.1, there's nothing for this
PR's edit to apply to. I left them deleted (matching 2.1's pre-cherry-pick state) rather than
recreating the file plus its missing dependency, which would add an unrelated, un-backported test
harness as a side effect of this fix.

What a reviewer should check: the actual bug fix (NextPrevious.tsx,
DataModelsTable.tsx, StoredProcedureTab.tsx) and its regression coverage
(*.integration.test.tsx, NextPrevious.test.tsx) are fully present and unaffected by this —
only the two *.browser.test.tsx files (which never existed on 2.1) are excluded.


Opened from openmetadata-collate, which holds the credentials needed to open a PR here. It merges itself once this branch's required checks pass — no review needed. If a check fails it stays open and the author of #38309 is asked to look.

resolver run

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no actionable issues were found.

Summary

Keeps Data Models and Stored Procedures pagination under usePaging and stops the page indicator from counting past a known total.

  • Data Models and Stored Procedures tables stay on the page selected.
  • The pager shows only known pages when it has a total.

Reviews (1) · Last reviewed commit: "Fixes #38295: keep Data Models and Store..." · Reviewed by Greptile

…nc (#38309)

* fix(pagination): let usePaging own URL-to-page synchronization (#38295)

* fix(pagination): let usePaging own URL-to-page synchronization (#38295)

* test: regression tests for Data Models and Stored Procedures paging sync (#38295)

* fix(pagination): don't count a phantom page past the known total

* test(pagination): unpin Data Models and Stored Procedures browser tests now that URL sync is fixed

---------

Co-authored-by: Sweta Agarwalla <swetaagarwalla13@gmail.com>
Co-authored-by: Sweta Agarwalla <105535990+sweta1308@users.noreply.github.com>
(cherry picked from commit 6c8c3d8)
@gh-bot-collate
gh-bot-collate Bot requested a review from a team as a code owner November 23, 2026 14:43
@gh-bot-collate
gh-bot-collate Bot requested review from shrabantipaul-collate and removed request for a team November 23, 2026 14:43
@gh-bot-collate gh-bot-collate Bot added the safe to test Add this label to run secure Github workflows on PRs label Nov 23, 2026
@gh-bot-collate

Copy link
Copy Markdown
Author

🤖 This backport will not merge itself: 2.1 has no required status checks, so there is nothing for auto-merge to wait on. Merge it by hand once CI is green.

@sweta1308
sweta1308 merged commit 8ab4602 into 2.1 Nov 23, 2026
46 checks passed
@sweta1308
sweta1308 deleted the backport/2.1/pr-38309 branch November 23, 2026 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants