Skip to content

Fixes 35468: Standardize UI pagination: 15/25/50 for lists, 12/24/48 for card grids - #35288

Merged
sweta1308 merged 58 commits into
mainfrom
ui-standardize-pagination-page-sizes
Nov 5, 2026
Merged

sweta1308 merged 58 commits into
mainfrom
ui-standardize-pagination-page-sizes

Conversation

@sweta1308

@sweta1308 sweta1308 commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Describe your changes:

Fixes #35468

Companion Collate PR: open-metadata/openmetadata-collate#7487 (aligns Collate's Pipeline Observability and AI Automations pagination with this scale).

Paged views had drifted to their own sizes (10, 9, 20, 5, and grids on 15/25/50 or lists on 12/24/48). This PR makes every paged view in the UI use one of two scales:

  • Lists / tables: default 15, picker 15 / 25 / 50
  • Card grids: default 12, picker 12 / 24 / 48 (rows of 2, 3 or 4 cards fill evenly)

The size a user picks is saved per scale (globalPageSize for lists, new globalGridPageSize for grids), and every paged view starts from the saved size for its scale, including views without a picker (Metrics, KPIs, Domains, Data Products, Reindex Failures, Context Center memories, Workflow execution history). Pages with a table/card toggle take the scale of the current view and go back to page 1 when the view changes. A size in the URL or settings hash still wins for the view it was opened in; a size the view does not offer is ignored together with the page and cursor counted at it. Every paged view shows its pager whenever the page has items, even a single page, so the size picker stays reachable, and hides it on an empty page. The rules are recorded in ADR:2026-10-13-ui-page-sizes-lists-15-25-50-grids-12-24-48 and ADR:2026-11-03-paged-views-show-pagination-whenever-they-have-items.

Page Before After
Connections — list view 12/24/48 15/25/50
Connections — grid view 12/24/48 12/24/48 (unchanged)
App Live Indexing (Search Indexing app) 10/15/25/50 15/25/50
Reindex failures drawer 20 15
Glossary update conflict table 5 15, with 15/25/50 picker
Context Center memories 10 15
Service version history server default (10), display hard-coded 10 saved page size, sent to the API
Settings → Applications, Applications marketplace, Profile → Applications / Marketplace 15/25/50 12/24/48
Settings → Services (card/table toggle) 15/25/50 in both views table 15/25/50, cards 12/24/48
Settings → Governance → Workflow Definitions 15/25/50 (default 25) 12/24/48
Profile → Personas 15/25/50 (12 start) 12/24/48
Profile → Members → team sub-teams 10, picker 15/25/50 15/25/50
Profile → Audit Log 15/25/50 (default 25) 15/25/50 (saved size)
Profile → Learning Resources, Learning Resources page (card/table toggle) 15/25/50 in both views table 15/25/50, cards 12/24/48
Domains / Sub-domains / Data Products 9 in both views table 15, cards 12
Metrics 20 in both views table 15, cards 12
Workflow execution history 15 fixed saved page size
Settings → Announcements 10/25/50 15/25/50 (saved size)
Data contract schema table 5 saved page size
Table → Schema tab (columns) 50, picker 15/25/50 15/25/50 (saved size)
Table → Lineage table 50, picker 15/25/50 15/25/50 (saved size)
Table → Profiler column table 50, picker 15/25/50 15/25/50 (saved size)
Dashboard data model → Model tab (columns) 50, picker 15/25/50 15/25/50 (saved size)
Glossary → Terms tab 50, no picker 15/25/50 (saved size)
Core PaginationCardWithControls, TableV2 client paging, atoms listing hooks (defaults) 10 15

Out of scope (not paged views): typeahead/suggestion searches, tree-select batches, count-only queries, bulk fetches, "load more" and "show more" previews.

Type of change:

  • Improvement

High-level design:

  • Constants (src/constants/constants.ts): LIST_PAGE_SIZE_OPTIONS (15/25/50), GRID_PAGE_SIZE_OPTIONS (12/24/48), GRID_PAGE_SIZE_BASE. Every picker uses these; the hand-written 15/25/50 arrays and local copies (EXPLORE_PAGE_SIZE_OPTIONS, INCIDENT_GROUPS_PAGE_SIZE_OPTIONS, …) are gone. Removed TABLE_CARD_PAGE_SIZE (9), INCIDENT_GROUPS_PAGE_SIZE and the Connections page's own option constants.
  • Saved size (hooks/paging/):
    • useSavedPageSize(scale) reads and saves the per-scale preference and resolves a URL/hash size against the scale.
    • usePageSizeState(scale) is page-size state that starts from the saved size and saves each pick.
    • usePageForSize(size) ties a page number to the size it was picked at, so a change to the saved size reads as page 1 before the next request.
  • usePaging defaults to the list scale. A URL size the caller does not offer, or a saved-size change with no URL size, opens page 1 without the cursor and clears the URL paging, only from the visible route (app mode keeps hidden routes mounted on the same URL). It hands out page and size in the same render as pagingCursor.
  • useListingData (atoms listings) applies the same rules to its page/size params; a valid URL size keeps its page (browser Back).
  • useHashPagingParams (settings panels) drops an off-scale hash size with its page and cursor, and returns resolvedPageSize and savePageSize so each panel takes its size from one place.
  • getViewPageSizeOptions(view) (utils/PaginationUtils.ts) picks the scale for a table/card view.
  • Pager visibility (ADR:2026-11-03-paged-views-show-pagination-whenever-they-have-items, superseding ADR:2026-10-31-paged-settings-lists-keep-pagination-at-non-default-page-size): shouldShowPager(items) for views that hold their items; usePaging shows it for a total above 0 or a cursor. TableV2 client paging needs rows, and PaginationComponent shows a single page by default (hideOnSinglePage stays as an opt-out).
  • Team sub-teams (Profile → Members) keep their page locally but use the saved list size, so a size picked there also resizes the Users tab on the same page, as on every other page.
  • Non-paging fixes in touched files (Sonar findings flagged because the PR touches the file): the schema constraint Select moves from the deprecated selectedKey/onSelectionChange to value/onChange; floating promises get void (SchemaTable, useIncidentGroups, WorkflowExecutionHistory, GlossaryTermTab, useSystemAnnouncements); the audit-log export promise gets a catch; MembersTeamsTab reads data-row-key through dataset. No behaviour change.
  • Alternatives considered: one scale for everything (grids then leave half-empty rows); per-page sizes (what drifted in the first place).
  • Compatibility: UI-only; no API, schema or migration changes.

Tests:

Use cases covered

  • Each listed page opens at its scale's saved size and its picker offers only that scale.
  • Switching table/card view changes the scale and returns to page 1.
  • An old link with an off-scale size opens page 1 and drops its paging from the URL/hash; a hidden route leaves the URL alone.
  • A saved-size change on a mounted page returns it to page 1 without requesting the old page; a URL with its own size keeps its page.
  • Service version history requests and displays the same page size.
  • A single page of items shows the pager at the default size; an empty page hides it.

Unit tests

  • Hooks: useSavedPageSize.test.ts, usePageSizeState.test.ts, usePageForSize.test.ts, usePaging.integration.test.tsx, useCursorPagedList.test.ts, useSettingsHash.test.tsx (useHashPagingParams).
  • Listings: useListingData.url.test.tsx (real URL, fetch and pagination hooks; old links, hidden route, saved-size change, browser Back, empty size).
  • Pages: Services.paging.test.tsx (real paging hooks, ListView and router), ContextCenterMemoriesPage.test.tsx, KPIList.test.tsx, AuditLogsPage.test.tsx, MetricListPage.test.tsx, WorkflowsPage.test.tsx, PersonasLanding.test.tsx, LearningResourcesSettings.test.tsx, MembersTeamDetail.test.tsx, and the settings panel tests.
  • Each new behaviour test fails with its fix reverted.
  • Full UI suite (yarn jest src): 2,224 suites, 26,215 tests, all passing (after updating the tests that asserted the old visibility rule).
  • tsc --noEmit: no new errors in changed lines. ESLint: no errors. yarn ui-checkstyle:changed: pass.

Backend integration tests

  • Not applicable (no backend API changes).

NOT NEEDED — UI-only change.

Ingestion integration tests

  • Not applicable (no ingestion changes).

Playwright (UI) tests

  • Specs whose waits use the new sizes:
    • Pages/Domains.spec.ts, Pages/SubDomainPagination.spec.ts: domain listing size=9 → 15
    • Pages/AppStopRunModal.spec.ts, Pages/DataInsightSettings.spec.ts, Pages/DataInsightReportApplication.spec.ts: apps?limit=15 → 12
    • Pages/SearchIndexApplication.spec.ts: apps/marketplace?limit=15 → 12
    • Features/ColumnSorting.spec.ts: schema tab columns?limit=50 → 15
  • Visual regression baselines: pages whose sample data fits on one page now show a pager, so their baselines are refreshed from the CI render.

Manual testing performed

  1. Local OSS stack (docker/development/docker-compose.yml) on :8585, UI via yarn start on :3000, logged in as admin.
  2. Pages spot-checked: Domains, Metrics, Settings → Services and Applications (+ Add Apps), Connections, Data Quality, Glossary terms. Default size and picker steps match the table above; toggling table/card changes the scale and returns to page 1.

UI screen recording:

Screen-Recording.57.mp4

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • My PR is linked to a GitHub issue via Fixes #<issue-number> above.
  • I have commented on my code, particularly in hard-to-understand areas.
  • For JSON Schema changes: not applicable (no schema changes).
  • For a UI feature or feature task: not applicable (standardization, explained above).
  • I have added tests (unit / integration / Playwright as applicable) and listed them above.
  • Decision check: adds docs/decisions/2026-10-13-ui-page-sizes-lists-15-25-50-grids-12-24-48.md and docs/decisions/2026-11-03-paged-views-show-pagination-whenever-they-have-items.md, which supersedes docs/decisions/2026-10-31-paged-settings-lists-keep-pagination-at-non-default-page-size.md.
  • I have added tests around the new logic.

🤖 Generated with Claude Code

Paged lists and tables default to 15 with a 15/25/50 picker; paged card
grids default to 12 with 12/24/48. Pages with a table/card toggle take
the scale of the current view and return to page 1 when it changes.

- Add LIST/GRID page-size option constants and view helpers in
  PaginationUtils.
- Core PaginationCardWithControls, TableV2 client paging and the atoms
  listing hooks default to 15 instead of 10.
- Lists: Connections list view, App Live Indexing, Reindex failures,
  glossary update conflict table, Context Center memories, service
  version history (now sends its page size to the API).
- Grids: Personas, installed Applications, Applications marketplace.
- Table/card: Domains, Sub-domains, Data Products, Metrics, Learning
  Resources.
- Fix pre-existing type errors in the touched files (AppLiveIndexing
  unsupported TableV2 props, useDataFetching default transform,
  Domains.spec.ts).
- Update Playwright waits to the new sizes and record the rule in
  ADR:2026-10-13-ui-page-sizes-lists-15-25-50-grids-12-24-48.
@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

✅ PR checks passed

The linked issue has a description and all required Shipping project fields set. Thanks!

@github-actions github-actions Bot added safe to test Add this label to run secure Github workflows on PRs UI UI specific issues labels Oct 13, 2026
@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 81%
81.38% (138416/170073) 68.43% (49877/72884) 71.47% (28026/39212)

sweta1308 and others added 5 commits October 13, 2026 11:00
…tyle

- Connections grid (12/24/48) and list (15/25/50) now page at different
  sizes, so switching layout resets to page 1 instead of keeping a page
  number that can fall past the last row. Add a regression test.
- ServiceVersionPage: add pageSize to the pagingHandler and tabs
  dependency lists so a size change reaches the table.
- Apply organize-imports ordering flagged by UI checkstyle.
Resolve conflicts in AppLiveIndexing and ReindexFailures by keeping
main's rework (SlideoutMenu drawer with entity-type filter, appData
prop, refetch on page-size change) and applying the 15/25/50 sizes.

Move the new profile Applications and Marketplace card grids from
15/25/50 to 12/24/48: useCursorPagedList takes an initial page size.
Add the now-required pageSize prop to the ServiceVersionMainTabContent
test.
- MetricListPage: card and table views page at different sizes, and
  useMetricHierarchy clears expansion when the size changes. Include the
  page size in the default-expansion scope so groups re-expand after a
  view switch (the desktop visual-regression test found "Gross Margin"
  hidden inside a collapsed group).
- ContextCenter.constants: re-export PAGE_SIZE_BASE with export...from
  (S7763).
- LearningResourcesPage: name the setter after its state value (S6754).
- TableV2: `customPaginationProps?: never` instead of the redundant
  `?: undefined` (S4782).
@github-actions

Copy link
Copy Markdown
Contributor

🔄 Playwright impact map auto-refreshed

This PR touched specs or UI source that changed the source→spec routing map. I regenerated .github/playwright/impact-map.generated.json and pushed the diff to this branch.

- source entries: 922 → 923
- 1 added, 0 removed, 1 changed spec-list

New source→spec entries:
  openmetadata-ui/src/main/resources/ui/src/components/DataQuality/AddDataQualityTest/components/TestCaseFormDrawer.tsx

Entries whose spec list changed:
  openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx

What is this file? It is the auto-generated half of Playwright's PR planner. It routes "if source X changes, run specs Y" by walking spec imports and cross-referencing getByTestId strings. Hand-authored routing in impact-map.json always wins on conflict.

What if I want to regenerate locally instead? Run this before pushing your next change to skip the bot commit:

python3 .github/scripts/generate_playwright_impact_map.py
git add .github/playwright/impact-map.generated.json
git commit --amend --no-edit  # or a separate commit

…Paging

- Services: ListView's card/table view is now owned by Services, which
  pages cards at 12/24/48 and the table at 15/25/50 and returns to page
  1 (clearing the cursor) when the view changes.
- usePaging: a caller that declares no options is on the list scale, so
  a grid size left in the shared pageSize param or an off-scale size an
  older build stored in the preference never reaches a 15/25/50 picker.
- usePaging: hand out the resolved size in the render where the options
  change. The stored size caught up a render late, so switching to cards
  fetched 25 under a picker reading 12.
- Record the usePaging default in the page-size ADR.
Restore the behavior before this PR: the pager always shows. The
hideOnSinglePage option added here replaced an ignored prop and hid it.
- Save the size picked on each scale: lists in globalPageSize, card
  grids in the new globalGridPageSize (useSavedPageSize). usePaging,
  useCursorPagedList and the pages with their own picker read and save
  through it, so switching a page between table and cards comes back to
  the size last picked in each view.
- Page on the grid scale: Workflow Definitions, profile Personas and
  profile Learning Resources (card view), which still offered 15/25/50.
- Settings Services: always show the pager, and on a view switch drop
  the page, cursor and page size the other view left in the URL.
- Remove resolveViewPageSize, now unused; update the page-size ADR.
Resolve AlertRecentEventsTab.desync.real-hook.test.tsx: keep main's
pagination-sync fixture (mockSetPreference, URL-restored page fetches its
own offset) at a list-scale preference of 25, so 100 events are 4 pages
and page 3 starts at offset 50.

Also hoist the empty useTableFilters argument in Services to a module
constant so its parsed filters stay memoized.
@sweta1308 sweta1308 changed the title Standardize UI pagination: 15/25/50 for lists, 12/24/48 for card grids Fixes 35468: Standardize UI pagination: 15/25/50 for lists, 12/24/48 for card grids Oct 14, 2026
Settings Services and App Live Indexing show their pager whenever there
is data, even a single page, and hide it when there is none, so an empty
list shows only its empty state.
sweta1308 and others added 4 commits October 15, 2026 14:26
No page sets a fixed starting size any more; each starts from the size
last picked on its scale (useSavedPageSize), and a size in the URL or
settings hash still wins.

- Local-state pickers now read and save it: Audit Logs, profile Audit
  Logs, Roles, Policies, Notification Alerts and Recent Events, Bots,
  Governance glossaries, Search preview, Glossary Term Relations,
  Column Bulk Operations, Incident Groups (useIncidentPaging).
- usePaging callers drop their fixed defaults: schema, column profiler,
  data model, glossary terms and lineage tables (50), table queries,
  data product ports, test definitions, Context Center archive, AI
  alert events (15), data contract schema (25).
- Views with no picker follow it too: Domains, Data Products,
  Sub-domains and Metrics (per view scale), KPIs, Reindex failures,
  Context Center memories.
- Remove getViewPageSize, INCIDENT_GROUPS_PAGE_SIZE, ARCHIVE_PAGE_SIZE
  and MEMORIES_PER_PAGE, now unused; record the rule in the ADR.
- Settings Services and App Live Indexing hide the pager only on an
  empty first page. A later page that comes back empty (a drained
  retry queue, a stale link) keeps it so the user can page back.
- Sonar: name state setters as value/setter pairs (usePaging,
  useIncidentPaging); NonNullable for TableV2's optional pagination;
  core Select value/onChange instead of the deprecated
  selectedKey/onSelectionChange (SchemaTable); drop the redundant
  click handler and presentation role around TableQueries' date picker,
  which already opens itself; mark fire-and-forget promises with void
  (Context Center memories).
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

🔄 Playwright impact map auto-refreshed

This PR touched specs or UI source that changed the source→spec routing map. I regenerated .github/playwright/impact-map.generated.json and pushed the diff to this branch.

- source entries: 1024 → 1028
- 4 added, 0 removed, 37 changed spec-list

New source→spec entries:
  openmetadata-ui/src/main/resources/ui/src/components/Database/SchemaTable/ColumnCustomPropertyCell.tsx
  openmetadata-ui/src/main/resources/ui/src/components/common/Form/JSONSchema/JsonSchemaWidgets/LdapRoleMappingWidget/LdapRoleMappingWidget.tsx
  openmetadata-ui/src/main/resources/ui/src/components/discovery/personal-space/Profile/components/AccessTokenRow.tsx
  openmetadata-ui/src/main/resources/ui/src/components/discovery/personal-space/Profile/tabs/access-control/AccessControlRulesTable.tsx

Entries whose spec list changed:
  openmetadata-ui/src/main/resources/ui/playwright/e2e/fixtures/pages.ts
  openmetadata-ui/src/main/resources/ui/playwright/support/entity/Entity.interface.ts
  openmetadata-ui/src/main/resources/ui/playwright/support/entity/TableClass.ts
  openmetadata-ui/src/main/resources/ui/playwright/support/fixtures/isolatedUser.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/aiProfile.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/apiResponse.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/common.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/customProperty.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/dragDrop.ts
  openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts
  … and 27 more

What is this file? It is the auto-generated half of Playwright's PR planner. It routes "if source X changes, run specs Y" by walking spec imports and cross-referencing getByTestId strings. Hand-authored routing in impact-map.json always wins on conflict.

What if I want to regenerate locally instead? Run this before pushing your next change to skip the bot commit:

python3 .github/scripts/generate_playwright_impact_map.py
git add .github/playwright/impact-map.generated.json
git commit --amend --no-edit  # or a separate commit

@sweta1308 sweta1308 added safe to test Add this label to run secure Github workflows on PRs and removed safe to test Add this label to run secure Github workflows on PRs labels Nov 3, 2026
sweta1308 and others added 2 commits November 3, 2026 17:26
Mark fire-and-forget fetches, navigations and cache invalidations with
void, settle the export confirm promise if the export rejects, and read
the row key through dataset.
…hash default

- usePaging memoises pagingCursor on its resolved cursor values, so a view
  toggle or saved-size change no longer refetches twice.
- Team sub-team paging starts from the saved size without saving picks, so
  the Users tab on the same page keeps its size and page.
- useHashPagingParams defaults to the list scale, so an off-scale hash size
  is always dropped with its page and cursor.
- Metrics test keeps the collapse check within one page scope.
- ColumnSorting spec waits on the 15-column request; ADR names the real helper.
The Users tab on the same page follows the saved size, as the page-size
ADR expects.
…tion-page-sizes

# Conflicts:
#	openmetadata-ui/src/main/resources/ui/src/hooks/paging/usePaging.integration.test.tsx
#	openmetadata-ui/src/main/resources/ui/src/hooks/paging/usePaging.ts
…tion-page-sizes

# Conflicts:
#	openmetadata-ui/src/main/resources/ui/src/components/DataProducts/InputOutputPortsTab/PortsListView/PortsListView.component.tsx
#	openmetadata-ui/src/main/resources/ui/src/components/common/NextPrevious/NextPrevious.tsx
@sonarqubecloud

sonarqubecloud Bot commented Nov 4, 2026

Copy link
Copy Markdown

…tion-page-sizes

# Conflicts:
#	openmetadata-ui-core-components/src/main/resources/ui/src/components/application/pagination/pagination.tsx
#	openmetadata-ui-core-components/src/main/resources/ui/src/stories/Pagination.stories.tsx
@gitar-bot

gitar-bot Bot commented Nov 5, 2026

Copy link
Copy Markdown
Code Review ✅ Approved 5 closed / 5 findings

🟡 Medium risk · Changing shared pagination preferences and URL/cursor handling across many UI views could show incomplete or empty result pages when page state is mismatched.

Standardizes UI pagination so lists default to 15 (picker 15/25/50) and card grids to 12 (picker 12/24/48), with saved per-scale page sizes applied across paged views. Resolved this session: the Connections view toggle now keeps the current page, the pager stays visible on an empty later page, Metrics paging resets correctly after a size change, the INCIDENT_GROUP_FILTER_KEYS JSDoc is corrected, and sub-team page size is no longer saved, matching the page-size ADR. No open findings.

✅ 5 closed
✅ Bug: Connections view toggle keeps the current page now that the scales differ

📄 openmetadata-ui/src/main/resources/ui/src/components/integration/ConnectionsPage/useConnectionsData.ts:172-183 📄 openmetadata-ui/src/main/resources/ui/src/components/integration/ConnectionsPage/ConnectionsListView.tsx:170-171 📄 openmetadata-ui/src/main/resources/ui/src/components/integration/ConnectionsPage/ConnectionsPage.constants.ts:107-110
Until this PR, Connections used 12/24/48 for both views. The removed comment in ConnectionsPage.constants.ts gave the reason: "so switching layout keeps the page you were on rather than resizing it". The list view now uses 15/25/50. When viewMode changes, useConnectionsData gets new pageSizeOptions, and usePaging's sync effect updates pageSize. Nothing resets currentPage, though. setViewMode in useConnectionsViewMode only writes viewMode, and the reset-to-page-1 queryKey in useConnectionsData does not include the page size or the view.

Example: with 40 connections, grid page 4 shows items 37–40. Switching to list keeps page 4 at 15 per page, which starts past the last row. In client mode the page renders empty next to a non-zero count. The PR description and the ADR both say the toggle goes back to page 1 on Connections, but no code does that here.

Fix: call handlePageChange(1) when pageSizeOptions (or viewMode) changes, the same way the Domains/Metrics/Learning pages reset.

✅ Edge Case: Pager hidden on an empty later page leaves user stranded

📄 openmetadata-ui/src/main/resources/ui/src/components/Settings/Applications/AppLiveIndexing/AppLiveIndexing.component.tsx:188-202 📄 openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Services.tsx:381-384
Both views now hide the pager whenever the current page's data is empty, but they don't check whether they are on page 1. The live-indexing retry queue drains as records get processed. If a user goes to page 3 after the queue has shrunk, getLiveIndexingQueue returns [] with total > 0. The pager disappears and the only thing left is the 'no retry queue records' placeholder, with no way back to earlier pages. Settings → Services behaves the same way when the currentPage/cursor in the URL points past the data, for example after services were deleted or when a stale link is shared. The fix is to hide the pager only when nothing exists at all: base the condition on paging.total (or on currentPage > 1) rather than on the current page's rows.

✅ Bug: Stale setPage on Metrics leaves paging stuck on page 1 after a size change

📄 openmetadata-ui/src/main/resources/ui/src/hooks/paging/usePageForSize.ts:24-27 📄 openmetadata-ui/src/main/resources/ui/src/pages/MetricsPage/MetricListPage/MetricListPage.tsx:270 📄 openmetadata-ui/src/main/resources/ui/src/pages/MetricsPage/MetricListPage/MetricListPage.tsx:515-518
usePageForSize returns a setPage that writes size: pageSize from its closure, so its identity changes whenever the size changes. In MetricListPage, setCurrentPage is a useCallback(..., []) and keeps the setPage from the first render. Say the page opens in table view (15) and the user switches to cards (12). Clicking Next then calls the old setPage, which stores { page: 2, size: 15 }. Since 15 !== 12, the hook reads the page as INITIAL_PAGING_VALUE. Previous/Next on Metrics stay on page 1 until the page remounts, and the same happens after any other change to the saved size. The new usePageForSize.test.ts misses this because it always calls the latest result.current[1]. The cleanest fix is to give the hook a stable setter that reads the current size from a ref; adding setPage to the setCurrentPage deps would also work.

✅ Quality: Orphaned JSDoc now documents INCIDENT_GROUP_FILTER_KEYS as page sizes

📄 openmetadata-ui/src/main/resources/ui/src/components/observability/IncidentManager/IncidentGroups/IncidentGroups.constants.ts:83-84
This commit removed INCIDENT_GROUPS_PAGE_SIZE_OPTIONS but kept its JSDoc, /** The page sizes the application's paged lists offer. */. That comment now sits directly above INCIDENT_GROUP_FILTER_KEYS, so editor hovers and generated docs describe the filter-key list as a set of page sizes. The constant also carries its own correct comment, so it now has two that disagree. Delete the leftover comment line.

✅ Quality: Sub-team page size no longer saved, contradicting the page-size ADR

📄 openmetadata-ui/src/main/resources/ui/src/components/discovery/personal-space/Profile/tabs/members/MembersTeamDetail.tsx:192-193 📄 openmetadata-ui/src/main/resources/ui/src/components/discovery/personal-space/Profile/tabs/members/MembersTeamDetail.test.tsx:809-811 📄 docs/decisions/2026-10-13-ui-page-sizes-lists-15-25-50-grids-12-24-48.md:27-30
MembersTeamDetail now seeds teamsPageSize from useSavedPageSize() once and changes it through a plain useState setter (line 192-193, passed as onTeamsPageSizeChange at line 1367). The new test (MembersTeamDetail.test.tsx:809-811) checks that picking a sub-team size leaves globalPageSize at 15. The Accepted record ADR:2026-10-13-ui-page-sizes-lists-15-25-50-grids-12-24-48 says "The size the user picks is remembered per scale (useSavedPageSize)" and "Every paged view starts from that saved size". So this view's picker no longer remembers the user's choice. Because the size is copied into state only once, the view also ignores later changes to the saved size, while the record says a mounted view picks those up and returns to page 1. Either call savePageSize (and reset teamsPage) when the size changes, or add a record that supersedes this rule with an exception such as "the Teams sub-team table keeps a session-local page size that is not saved to globalPageSize".

Verification

Rules No rules evaluated

Functional validation Not enabled

Set up

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Options

Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@sweta1308
sweta1308 merged commit 895c970 into main Nov 5, 2026
66 checks passed
@sweta1308
sweta1308 deleted the ui-standardize-pagination-page-sizes branch November 5, 2026 06:22
anuj-kumary added a commit that referenced this pull request Nov 6, 2026
…ywright specs (#37212)

* fix(ui): stop metric and asset lists dropping rows; harden governance Playwright specs

Metric list: switching card -> table view changes the page size (12 -> 15) since #35288,
which resets useMetricHierarchy. When the table query is cached, expandAll() runs in the
same commit as the reset with the previous scope's group pages in its closure, skips the
fetch, and the group renders expanded with no rows. Group pages now carry the request
generation and expandAll refetches any page from an earlier generation.

Assets tab: after linking assets, AssetsTabs fires a search with the old (empty) ids and
then one with the new ids. With no stale-response guard the slower empty response could
land last, leaving "No assets linked yet" under a count of 2. Only the latest search now
updates the list and the loading state.

Playwright:
- MetricHierarchy / Pagination: assert the 15-row list page size from #35288.
- OntologyReview: re-hover the disabled Publish trigger until the tooltip shows; the
  right-aligned header shifts when the isolated-terms badge renders late.
- OntologyStudioFlows: retry the empty-canvas double-click until the drawer opens, and
  measure the canvas after the node layout settles.

* chore(ui): organize imports in useMetricHierarchy test
chirag-madlani added a commit that referenced this pull request Nov 6, 2026
…izes

Main added GET /domains/styles and /ontologyConcepts/boundTo calls to
every entity page, and moved list pages to 15/25/50 (#35288); the
browser tests now answer both calls and read PAGE_SIZE_BASE.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
sweta1308 added a commit that referenced this pull request Nov 6, 2026
…35288 (#37234)

#35288 moved list defaults to 15 (column tables and data model columns
from 50, Audit Logs from 25, Memories from 10) and made usePaging drop a
URL pageSize outside the page's options. Specs still assumed the old
sizes and broke on main.

- AuditLogs: default page size is 15.
- Table/Dashboards columns: use nested/tag rows that sit on page 1, and
  wait for offset=15 on page 2.
- Table "should persist page size": pick 25, not the default 15.
- ContextCenterMemories: wait for limit=15; seed 16 memories so the
  pagination tests own their second page.
- TestSuite, IngestionListNameSorting, AI-mode ConnectionServiceDetails:
  stop forcing a second page with an off-scale ?pageSize=1/2, which the
  list now ignores; seed one more row than a 15-row page instead.
anuj-kumary added a commit that referenced this pull request Nov 9, 2026
…le glossary and ontology specs (#37337)

* Fix governance AUT failures: slow workflow cancel on hard delete and stale glossary/ontology specs

- WorkflowHandler.cancelInstancesForEntities: find running instances with one
  native IN query per chunk. Flowable's or().variableValueEquals() emits one
  correlated EXISTS per id, a full ACT_RU_VARIABLE scan each; with ~10k running
  instances a 100-id chunk took 15-18s, so hard-deleting a 400-concept ontology
  took ~97s and OntologyLargeGraph cleanup timed out.
- LargeGlossaryPerformance: glossary terms page at 15 since #35288; after clearing
  the search, wait for a listed term the search did not match.
- utils/glossary assignTagToGlossaryTerm: name the confirmation heading; #37179
  made the glossary title an h2.
- OntologyConceptDrawer: match "Unsaved changes" case-insensitively (Collate
  overrides the label); preselect the test's own ontology in All ontologies so a
  parallel worker deleting the first one cannot leave the drawer loading a 404.

* Cover the native cancel lookup with two ids and a surviving bystander; tighten comments

* Match SQL probe fragments past optimizer hints

EntityDAO.deleteByIds (#36868) renders DELETE /*+ INDEX(t PRIMARY) */ FROM t, so
SqlFailureProbe and SqlQueryCounter fragments like "delete from chart_entity" stopped
matching. The bulk-path atomicity cases in EntityHardDeletionAtomicityIT injected
nothing and failed. Match against the SQL with block comments removed.
Rohit0301 added a commit that referenced this pull request Nov 9, 2026
…ken by memory-status, page-size and leave-team changes (#37338)

* test(playwright): fix Context Center, Table and ProfileTeam specs after memory-status, page-size and leave-team changes

- createMemoryViaApi and the Permission owner fixture pin entityStatus Approved:
  #36989 made Collate (reviewRequired) start memories Unprocessed and hid pending
  memories from non-owners, so readers never saw the fixtures.
- Table tag-search test uses dim_customer.average_order_size: with 15-row column
  pages sorted by name (#35288), shop_id moved to page 2.
- ProfileTeam leave waits for PATCH /users/<me>: leaving now updates the user's
  teams instead of DELETE /teams/<id>/users/<id>.

* test(playwright): assert 200 on ProfileTeam join/leave responses after awaiting them

* test(playwright): address review on Context Center, Table and ProfileTeam spec fixes

- createMemoryViaApi keeps the Approved default when entityStatus is passed as undefined
- Dashboard drops the Approved asserts that only echoed the helper (OSS default is
  guarded by ContextMemoryCreateGrantIT)
- Permission owner fixture goes through createMemoryViaApi so a failed POST fails fast
- Table tag test searches the column before tagging, so pagination and sort no longer
  matter; afterAll hard-deletes the glossary and classification
- ProfileTeam join/leave waits are scoped to the admin's own PATCH via
  waitForResponseWithStatus

* chore(playwright): auto-refresh impact-map.generated.json

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
chirag-madlani added a commit that referenced this pull request Nov 23, 2026
…gration, marked) + CI (#35623)

* test(ui): add Vitest browser-mode UI integration tests and migrate Pagination.spec.ts

* test(ui): unmount before resetting MSW handlers; keep coverage on failure

vitest-browser-react unmounts in the next test's beforeEach, so the global
afterEach reset handlers and the URL under a still-mounted page, which then
refetched and got wrong-shaped responses (unhandled paging/permission errors).
Also write lcov when a test fails so one flake can't drop Sonar coverage.

* ci(ui): POC workflow for Vitest browser tests with coverage comment and stability runs

Runs the browser suite with istanbul coverage and posts a Jest-style coverage
and JUnit comment, plus five shuffled no-retry runs whose failures are
summarized in a second comment. Drops the duplicate patch file.

* test(ui): mock approval-workflow endpoints main added; keep CI timings on failure

main now calls /metadata/types/workflows/approvalEnforcedEntityTypes and
/changeRequests from entity pages, which the strict unmocked-API check caught.
The workflow now records wall time and uploads screenshots even when tests fail.

* test(ui): drop AntDConfigProvider from the browser-test harness

main removed it with the antd Form/Select/Input migration (#35509); the app
no longer mounts it.

* ci(ui): drop the browser-test stability runs

The shuffled no-retry runs showed the suite stable; the workflow now runs
the browser tests once, with coverage, on UI and core-component changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(playwright): keep migrated pagination tests, marked @migrated-browser

The 35 Pagination E2E tests covered by browser tests keep running, tagged
with their replacement, until the browser tests are validated and
PaginationIT walks cursors for every listed entity type. Records the
layering rule as a decision.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): keep browser-test failure handling when the comment cannot post

Skips the coverage comment on fork PRs and lets it fail without failing
the job; formats three browser-test files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs(agents): say which UI test layer a check belongs in

A path-scoped rule for browser tests and Playwright specs: pick the layer
(Jest, browser test, Java IT, Playwright journey), write a browser test
with the shared fixtures, and tag a moved Playwright test instead of
deleting it. The Playwright rule and test-enforcement skill point to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): mock main's new app-shell calls; follow its standard page sizes

Main added GET /domains/styles and /ontologyConcepts/boundTo calls to
every entity page, and moved list pages to 15/25/50 (#35288); the
browser tests now answer both calls and read PAGE_SIZE_BASE.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): import PAGE_SIZE_BASE in the pagination contract

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): format two browser tests' imports

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(playwright): auto-refresh impact-map.generated.json

* ci(ui): run browser tests on ubuntu-24.04 with read-only permissions

ubuntu-latest moved to 26.04, which Playwright 1.57 cannot install
Chromium on; main's Playwright workflows pin 24.04 too. Main's PR
workflow security check requires read-only permissions on pull-request
jobs, so the results go to the job summary instead of a PR comment.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): pagination search checks the rows it shows; drop unused Sonar path

Search hits now come back in a different order from the list, and the
contract asserts the visible rows after search, Next and reload, so a page
that sends the right request but keeps showing old rows fails. Sonar never
receives browser coverage yet, so its lcov path is dropped. The agent rule
names only helpers that exist on this branch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): wait for network idle, not fixed sleeps, in the pagination contract

settle() slept 300 ms. The contract now waits until MSW has nothing in
flight and no new request for a short quiet window, which is what a
request count needs to be final; render waits poll for the row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): share the network-idle wait as src/test/browser/network.ts

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): address review on the browser-test setup

- Data Models and Stored Procedures: their browser tests are pinned failing
  by a product bug (#38295), so their Playwright tests stay untagged;
  double fetch filed as #38296. Migration doc counts and rows updated.
- Decision record is Proposed until the team signs off.
- No Sonar claims (it does not read browser coverage yet); no unused JUnit.
- The workflow also runs on setup-action changes; the setup action caches
  Chromium and the ANTLR CLI.
- setup.ts resets the app-wide zustand stores between tests.
- networkIdle counts /api requests only and notes its quiet-window limit.
- Screenshot comparison runs on Linux only (its baseline's platform).
- Contract: two-page assumption checked, empty-record guard, isListPage
  shared, search mock scope documented; msw resolutions dropped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
chirag-madlani added a commit that referenced this pull request Nov 23, 2026
…arch specs to browser tests; run only affected browser tests (#36198)

* test(ui): add Vitest browser-mode UI integration tests and migrate Pagination.spec.ts

* test(ui): unmount before resetting MSW handlers; keep coverage on failure

vitest-browser-react unmounts in the next test's beforeEach, so the global
afterEach reset handlers and the URL under a still-mounted page, which then
refetched and got wrong-shaped responses (unhandled paging/permission errors).
Also write lcov when a test fails so one flake can't drop Sonar coverage.

* ci(ui): POC workflow for Vitest browser tests with coverage comment and stability runs

Runs the browser suite with istanbul coverage and posts a Jest-style coverage
and JUnit comment, plus five shuffled no-retry runs whose failures are
summarized in a second comment. Drops the duplicate patch file.

* test(ui): mock approval-workflow endpoints main added; keep CI timings on failure

main now calls /metadata/types/workflows/approvalEnforcedEntityTypes and
/changeRequests from entity pages, which the strict unmocked-API check caught.
The workflow now records wall time and uploads screenshots even when tests fail.

* test(ui): entity-page harness for browser tests and the migratedTo marker

Adds a Data Steward persona built from the seeded policies (server-accurate
ViewAll/EditAll expansion and notAllow), an entity server that applies the
page's JSON patches, a search fixture keyed by index alias, and the first
migrated flow: owners add/replace/clear on the table page. Drops the
AntDConfigProvider main removed. migratedTo.browser/javaIT tags Playwright
tests whose coverage moved, with the replacement in an annotation.

* test(ui): migrate EntityDataSteward table tests to browser mode

* test(ui): run the EntityDataSteward browser tests for all 15 entity types

* test(playwright): mark EntityDataSteward tests migrated to browser mode

* test(ui): split EntityDataSteward browser tests into one file per entity type

Vitest runs a file in one worker, so the 195 cases ran serially (6m18s
locally). The flows now live in entityDataSteward.contract.tsx and each
entity type has a thin file, so workers run types in parallel (4m25s on
3 workers). The Playwright marker points at the new files.

* test(ui): mark Playwright tests covered by Java ITs with migratedTo.javaIT

* test(ui): drop AntDConfigProvider from the browser-test harness

main removed it with the antd Form/Select/Input migration (#35509); the app
no longer mounts it.

* test(ui): speed up browser tests: short steward schema, shared page per worker

The Data Steward flows edit only the first column, yet the Table page
rendered 50 of 120 columns on every re-render (~2x per test). Serving 15
columns and reusing each worker's page across files (isolate: false, so the
app loads once per worker instead of once per file) takes the entity matrix
from 4m25s to 2m01s locally; the whole suite passes shuffled with it.

* test(ui): migrate EntityDataConsumer flows to browser tests

Shares the entity configs and steps with the Data Steward contract
(entityMatrix.ts) and adds a DATA_CONSUMER persona whose noOwner()/isOwner()
rules are evaluated against the entity's owners, as the server does.

* test(playwright): mark EntityDataConsumer tests migrated to browser tests

* fix(ui): cancel Searchbar's pending debounced search on unmount

Closing a picker within typingInterval of typing still fired the search for
a list that was gone (a wasted request and a state update after unmount).
The browser tests surfaced it as a stray /search/query in the next test.

* test(ui): name the index and query of an unmocked API call

A stray search is then traceable to the picker that sent it.

* fix(ui): cancel Searchbar's pending search on unmount only

The previous cleanup also ran whenever the debounce was recreated, i.e.
whenever the parent passed a new onSearch, so a search typed during such a
re-render was silently dropped (pagination search tests caught it on CI).
Keep the latest debounce in a ref and cancel it from an unmount-only effect.

* test(ui): give the instrumented coverage run a 30 s test timeout

Istanbul slows every test; SchemaTable's Next/Previous test passed in all
five uninstrumented runs but crossed 15 s under coverage. The strict 15 s
limit stays for test:ui:run, which the stability runs use.

* ci(ui): cache Playwright Chromium and skip its apt deps in browser-test setup

A stability run timed out at 30 min after its runner spent ~10 min on
playwright install --with-deps fetching fonts from a slow apt mirror. The
runner image already has headless Chromium's libraries; cache the browser
per Playwright version.

* test(ui): migrate ServiceEntity flows to browser tests

* test(playwright): mark ServiceEntity tests migrated to browser tests and Java ITs

* test(ui): retry announcement card actions closed by a late refetch

* ci(ui): shard the browser-test coverage and stability runs across 3 runners

One runner took ~10 min for the 510-test suite. Coverage shards write blob
reports that a report job merges (vitest --merge-reports --coverage) into the
single summary and JUnit file the PR comment uses; each shuffled stability
run is split the same way and the report sums its shards.

* ci(ui): install the ANTLR CLI from a cached pinned jar in browser-test setup

make install_antlr_cli tries apt first, which took 9-10 min on several
runners (each shard paid it). Use the Makefile's pinned 4.9.2 jar and
checksum, cached, and put it on PATH.

* test(ui): migrate Entity header, announcement and delete flows to browser tests

* test(ui): allow 30 s per browser test for a page's cold first load

TableVersionColumns failed once in 15 shuffled shard runs: its page took
over 15 s to render on its first load in that worker (isolate:false loads
a page's module graph once per worker). Coverage runs get 45 s.

* test(ui): confirm each tag and data-product pick before saving

A picker re-renders its options when its search lands. pickTag waited for
any earlier query with the same term, so a repeat toggle could click while
this search re-rendered the tree, and the page saved without the tag
(ServiceEntity.PipelineService tags). The data product picker never waited
for its search, so a removal click could be lost the same way
(EntityAdmin.Worksheet domain flow).

Each pick now waits for the search sent after its own keystrokes, then
clicks the option until the DOM shows the wanted state (tree data-selected,
menu aria-checked) before Update; the data product save also waits for its
PATCH.

Also shares the tag/glossary pickers, a column read and search endpoint on
the column fixture, data model columns backed by the entity (row PUTs and
panel PATCHes reach the same columns), and a second child per fixture, for
the column panel tests.

* test(ui): migrate Entity column detail panel and child-table flows to browser tests

* test(ui): migrate Entity Table tab flows to browser tests

* test(playwright): mark Entity tests migrated to browser tests and Java ITs

* test(ui): wait for the team owner search so it cannot land in the next test

The team picker's debounced search could fire after the owner flow ended
and reach the next test in the same worker as an unmocked call
("GET /search/query?index=team&q=PW Team 2" failing PipelineTasks and
SchemaTable under --sequence.shuffle). Wait for it like the user picker.

* test(ui): wait for the glossary picker's search and pick tags and terms by intent

The glossary picker read a term's selected state before its own search had
re-rendered the tree, so on a slow (coverage) run it could 'confirm' a state
that was already true and save nothing: PW_Term_1 stayed after its removal.
Wait until the search has filtered the tree, and let the add/update/remove
helpers pass the wanted state instead of inferring it from the DOM. The tag
picker's search wait gets a 10 s ceiling instead of expect.poll's 1 s.

* test(ui): re-click a picker trigger until the picker opens

A column panel re-rendering under the click dropped it, so the glossary
picker never opened (EntityColumnPanel.Pipeline, once in 15 shard runs).
Click until the picker's search box shows, as the Playwright helpers do.
The owner search wait gets the same 10 s ceiling as the others.

* ci(ui): retry yarn install in browser-test setup

A shard failed before running a test because the registry answered 502.

* test(ui): open the description editor through openPicker; give re-clicks a grace period

The DashboardDataModel column panel's description editor never opened once
on CI: the click was lost to a re-render. saveDescription now takes the
trigger and clicks it until the editor shows. openPicker waits 3 s before
re-clicking, so a picker that is merely slow to open is not closed again,
and polls the DOM instead of catching a failed expect.element (a caught
browser assertion still fails the test).

* test(ui): give expect.poll and expect.element a 10 s default in browser tests

A StorageService tag test failed once in 15 shard runs 2.5 s in: the
1 s default poll checked the server before the page's tag PATCH landed on a
busy runner. A condition that never comes true still fails.

* test(ui): migrate CustomProperties flows to browser tests

* test(playwright): mark CustomProperties tests migrated to browser tests

* test(ui): migrate AdvancedSearch query builder flows to browser tests

* test(playwright): mark AdvancedSearch tests migrated to browser tests

* test(ui): let a newly added advanced search rule settle before filling it

Under a shuffled run the second group's rule sometimes kept the default
Owners field while its select showed the picked one. Wait for the new rule
to show its default field, and refill a rule whose field reverted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): fix browser test races seen under coverage

Count Explore searches from before the quick filter pick, render Explore
once per custom property search test, and give a cold first load of the
settings and Explore pages 90 s under istanbul.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): run the browser suite on 5 shards, 3 shuffled stability runs

The suite grew to ~1,060 tests with CustomProperties and AdvancedSearch;
three shards ran past 10 minutes each. Five shards keep each job short,
and three shuffled runs (15 jobs) keep the total near 20 jobs per push.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(playwright): mark specs covered by the new Java ITs

Search RBAC (asset, column, explore and type counts), API collection
owner inheritance, rename consolidation for data products, tags and
glossary terms, approve/reject after a glossary term move, task
resolution on every entity type and the 16-type custom property
contract now carry migratedTo.javaIT markers.

Delete tests split to BaseEntityIT#delete_async_soft_delete, which
exercises the async endpoint the UI calls, then restores; Database
gains a marker and Database Schema switches to it. Table and Database
Service stay the real-server delete flows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(ui): show the held field when a query builder Field box is left unpicked

Typing a field name filters the selected field out of the Field combobox.
Left without a pick (blur or Escape), React Aria commits the selection it
can no longer find as null, and OMFieldSelect ignored null, so the box kept
the typed text: it showed "Name" while the rule still filtered on Owners and
the search went out on Owners. A browser test that misses the option click
under load hit exactly this (the advanced search "two conditions as a group"
flake). Reset the box to the selected field's label on that commit.

The browser helpers now leave the box after picking, so it shows what the
rule holds rather than the typed filter, and pick again if a click missed.
That replaces the earlier settle-wait and fillRule retry, whose premise (a
new rule resetting its field) did not hold up: instrumented runs showed the
pick never reached the rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): scale suite-level time limits under coverage

A describe-level { timeout } overrides the CLI --testTimeout, so the 45 s
coverage limit never reached suites that set their own (60-150 s), while
istanbul made their cold first page load several times slower:
CustomPropertyCards' first test took 63 s on a coverage shard (5-8 s
uninstrumented). suiteTimeout(ms) doubles those limits under --coverage.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(ui-core): keep a staged TreeSelect pick across an equal value

An entity refetch rebuilds the tags array the glossary and tag pickers
receive; TreeSelect resynced on value identity and discarded the staged
draft, so Apply saved nothing. Resync on the selected ids instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): drop the browser-test stability runs

The shuffled no-retry runs showed the suite stable; the workflow now runs
the browser tests once, with coverage, on UI and core-component changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): drop the browser-test stability runs

The shuffled no-retry runs showed the suite stable; the workflow now runs
the sharded browser tests once, with merged coverage, on UI and
core-component changes (and on changes to its setup action).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(playwright): keep migrated pagination tests, marked @migrated-browser

The 35 Pagination E2E tests covered by browser tests keep running, tagged
with their replacement, until the browser tests are validated and
PaginationIT walks cursors for every listed entity type. Records the
layering rule as a decision.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): keep browser-test failure handling when the comment cannot post

Skips the coverage comment on fork PRs and lets it fail without failing
the job; formats three browser-test files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): reset browser-test state even when a request never settles

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): organise imports and format migrated specs and browser tests

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): run only the browser tests a pull request affects

The full run on main records which source files each browser test file
executes (coverage counters, src/test/browser/impact.ts) and keeps the map
in the Actions cache. A pull request selects the test files that executed
its changed code, plus the tests reaching changed helpers, direct imports
of executed files, and changed en-us.json keys. A missing map, or a change
to test setup, configs, dependencies or core components, runs everything.

The static import graph cannot do this alone: lazy imports tie ~1,000
modules into one cycle (openmetadata-collate#7947).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): record the impact map on every full browser-test run

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): keep each shard's impact records when merging the map

Shards name their record file after the process id, which repeats across
runners; merged into one folder they overwrote each other (104 of 130 test
files mapped).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs(ui): drop an internal ticket reference from the browser-test selection notes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): re-click the column panel's Data Quality tab if a re-render drops it

CI screenshot showed the panel still on Overview after the click.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): scale every cold-load wait for coverage runs

A coverage run roughly doubles a cold page load, but fixed 60-90 s element
and test limits did not scale with it; the impact-analysis test timed out
with the lineage tab still loading. scaled(ms) applies the same factor as
suiteTimeout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs(agents): say which UI test layer a check belongs in

A path-scoped rule for browser tests and Playwright specs: pick the layer
(Jest, browser test, Java IT, Playwright journey), write a browser test
with the shared fixtures, and tag a moved Playwright test instead of
deleting it. The Playwright rule and test-enforcement skill point to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): run the full browser suite in the merge queue; report changed-code coverage

The merge queue now runs every browser test file (when the queued change
touches the UI), so a selection miss cannot reach main, and its passing
run publishes the impact map as an artifact pull requests download (queue
caches are not readable from pull requests). Push-to-main runs go.

The PR comment reports what ran and why, the result, and how many of the
changed lines the tests that ran executed, instead of an overall coverage
percentage that only reflects whichever tests were selected.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(ui): ignore browser-test report outputs

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): mock main's new app-shell calls; follow its standard page sizes

Main added GET /domains/styles and /ontologyConcepts/boundTo calls to
every entity page, and moved list pages to 15/25/50 (#35288); the
browser tests now answer both calls and read PAGE_SIZE_BASE.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): import PAGE_SIZE_BASE in the pagination contract

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): format two browser tests' imports

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): format two tagged Playwright specs

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): let renderApp take a distribution's router and providers

Collate mounts its own router (Collate routes, then AuthenticatedAppRouter)
and adds a provider; with these options its renderApp reuses the same
provider stack instead of repeating it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): match the Explore panel's renamed Custom properties tab

Main renamed the right panel tab from "Custom property" to "Custom
properties"; the custom-property value tests clicked the old name.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(playwright): auto-refresh impact-map.generated.json

* test(ui): follow main's custom-property settings changes

Main (#36808) labels the type "SQL Query" and names the property in the
delete confirmation by its display name inside a warning sentence.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(playwright): auto-refresh impact-map.generated.json

* ci(ui): run browser tests on ubuntu-24.04 with read-only permissions

ubuntu-latest moved to 26.04, which Playwright 1.57 cannot install
Chromium on; main's Playwright workflows pin 24.04 too. Main's PR
workflow security check requires read-only permissions on pull-request
jobs, so the results go to the job summary instead of a PR comment.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): pull requests only restore browser-test caches; refresh the impact map

Main's CI check forbids cache saves from pull-request jobs; the setup
action restores Chromium and the ANTLR CLI and saves them only outside
pull requests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): format MetricSearch.spec.ts

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): serve a topic's schema fields through the columns API

Main pages topic schema fields from /topics/name/{fqn}/columns and saves
field edits with PUT /columns/name/{fqn} (#37862); the topic page tests
now serve the fields that way, held inside the topic like a data model's
columns.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): treat core components as a library for browser-test selection

A core-components change no longer runs every browser test. It runs core's
own tests and build in a new core components job; until now no CI ran
core's Vitest suite at all. Six tag tests had rotted unnoticed: main made a
badge's tooltip trigger a non-focusable span (no nested buttons), and the
tests still expected a button.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): pagination search checks the rows it shows; drop unused Sonar path

Search hits now come back in a different order from the list, and the
contract asserts the visible rows after search, Next and reload, so a page
that sends the right request but keeps showing old rows fails. Sonar never
receives browser coverage yet, so its lcov path is dropped. The agent rule
names only helpers that exist on this branch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs(agents): name the browser-test helpers this branch adds

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): wait for network idle, not fixed sleeps, in the pagination contract

settle() slept 300 ms. The contract now waits until MSW has nothing in
flight and no new request for a short quiet window, which is what a
request count needs to be final; render waits poll for the row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): share the network-idle wait as src/test/browser/network.ts

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): wait for network idle instead of fixed sleeps in setup and advanced search

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): address review on the browser-test setup

- Data Models and Stored Procedures: their browser tests are pinned failing
  by a product bug (#38295), so their Playwright tests stay untagged;
  double fetch filed as #38296. Migration doc counts and rows updated.
- Decision record is Proposed until the team signs off.
- No Sonar claims (it does not read browser coverage yet); no unused JUnit.
- The workflow also runs on setup-action changes; the setup action caches
  Chromium and the ANTLR CLI.
- setup.ts resets the app-wide zustand stores between tests.
- networkIdle counts /api requests only and notes its quiet-window limit.
- Screenshot comparison runs on Linux only (its baseline's platform).
- Contract: two-page assumption checked, empty-record guard, isListPage
  shared, search mock scope documented; msw resolutions dropped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Address review on browser-test migration and selection

- SearchBar: one debounced search per typingInterval reading the latest
  onSearch, so a rerender then unmount leaves no old timer running.
- TreeSelect: resync on the selected nodes' content (id, label, data), so a
  renamed selection updates while an equal rebuilt value keeps the draft.
- Selection: a changed screenshot baseline runs its test, global styles run
  everything, and a deleted source file still selects its tests.
- Workflow: manual runs always run in full; a run that selects nothing
  still updates the PR comment with why.
- Tests: no as-unknown-as casts (typed EntityLike children, generic column
  fixtures); setup.ts store reset and the Bots fixture now type-check.
- pickOption keeps its confirm-then-repick, documented as the one sanctioned
  re-attempt, and the rule now says when that is allowed.
- Decision record for the selection policy.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): fix import formatting in entityMatrix.ts

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(ui): run the full browser suite in the queue for core changes; fail when selection fails

A core-only pull request still runs core's own tests, but the merge queue
now runs every browser test for it, so a core change that breaks the app
cannot reach main. If test selection fails, the report check fails instead
of being skipped (a skipped required check passes).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
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 UI UI specific issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Standardize UI pagination: 15/25/50 for lists, 12/24/48 for card grids

2 participants