Skip to content

chore(UI): upgrade react-router-dom v6 → v7 and fix column panel race condition - #30580

Draft
Rohit0301 wants to merge 21 commits into
mainfrom
upgrade-react-router-dom-v7
Draft

chore(UI): upgrade react-router-dom v6 → v7 and fix column panel race condition#30580
Rohit0301 wants to merge 21 commits into
mainfrom
upgrade-react-router-dom-v7

Conversation

@Rohit0301

@Rohit0301 Rohit0301 commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Describe your changes:

675

I upgraded react-router-dom from 6.30.4 to 7.18.1 and fixed a race condition that the upgrade exposed: in v7, navigate() is wrapped in React.startTransition, which defers the router re-render. This caused the column detail panel to briefly reopen after closing because effects still saw stale URL params during the transition window.

  • package.json / yarn.lock: bump react-router-dom to 7.18.1
  • useFqnDeepLink.ts (primary fix): move selectedColumn to a useRef so it is read without being a reactive dependency — prevents the hook re-firing when closeColumnDetailPanel sets it to null while columnPart is still stale
  • GenericProvider.tsx (defensive guard): add a skipNextColumnSync ref that is set to true inside closeColumnDetailPanel before navigate(), and consumed once in the URL-sync useEffect, blocking the panel from reopening during the deferred re-render window

SettingsSso.tsx was audited and its existing configFetched ref guard is sufficient — no code change needed there.

Type of change:

  • Improvement

High-level design:

react-router v7 wraps every navigate() / setSearchParams() call in React.startTransition, so the router's React state (useParams, useSearchParams) is updated asynchronously. Local React state (setSelectedColumn(null)) updates synchronously. Any useEffect that depends on both will fire immediately with a mix of new local state and stale URL params — creating a reopen race.

The two fixes use the "ref as a non-reactive value" pattern: store the value in a ref so it can be read inside an effect without being a trigger for it. The skipNextColumnSync flag is a one-shot guard: set before navigate, consumed once on the next effect run, then reset — so deep-link opens on initial mount and subsequent URL-driven opens are unaffected.

Tests:

Use cases covered

  • Column detail panel closes and stays closed after clicking the close button
  • Deep-linking to a column FQN in the URL still opens the panel on initial load
  • Navigating between columns (via URL change) still opens the correct panel

Unit tests

  • Not added — the race condition is timing-dependent and best caught by Playwright E2E

Backend integration tests

  • Not applicable (no backend API changes).

Ingestion integration tests

  • Not applicable (no ingestion changes).

Playwright (UI) tests

  • Existing Table.spec.ts Playwright tests cover the column detail panel close behavior ("Copy column link should have valid URL format" asserts .column-detail-panel is not visible after close)

Manual testing performed

  1. Open a table page with columns
  2. Click a column row to open the column detail panel
  3. Click the close button — verify the panel closes and stays closed
  4. Navigate directly to a URL with a column FQN hash — verify the panel opens correctly

UI screen recording / screenshots:

Not applicable.

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: I updated the migration scripts or explained why it is not needed.
  • For UI changes: I attached a screen recording and/or screenshots above.
  • I have added tests (unit / integration / Playwright as applicable) and listed them above.

Greptile Summary

The PR upgrades React Router DOM from 6.30.4 to 7.18.1 and adjusts column-detail synchronization to avoid reopening the panel while navigation is deferred.

  • Pins react-router-dom at 7.18.1 and refreshes its transitive lockfile entries.
  • Mirrors the selected column through refs so selection changes do not retrigger deep-link synchronization against stale URL parameters.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains.

Important Files Changed

Filename Overview
openmetadata-ui/src/main/resources/ui/package.json Pins React Router DOM to version 7.18.1.
openmetadata-ui/src/main/resources/ui/yarn.lock Updates React Router and its transitive dependency resolutions for version 7.18.1.
openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx Uses a selected-column ref to keep the panel-opening callback stable across selection changes.
openmetadata-ui/src/main/resources/ui/src/hooks/useFqnDeepLink.ts Reads selected-column state through a ref without making selection changes effect dependencies.

Sequence Diagram

sequenceDiagram
  participant User
  participant Panel as Column detail panel
  participant State as Selected-column state/ref
  participant Router
  participant Sync as Deep-link effect
  User->>Panel: Close panel
  Panel->>State: Clear selected column
  Panel->>Router: Navigate to entity URL
  Note over Router: Navigation may be deferred
  State-->>Sync: Selection change is non-reactive
  Router->>Sync: Commit updated URL parameters
  Sync-->>Panel: Do not reopen from stale parameters
Loading

Reviews (5): Last reviewed commit: "Merge branch 'main' into upgrade-react-r..." | Re-trigger Greptile


Summary by Gitar

  • Paging & Search Hooks:
    • Added processedPageSizeRef in usePaging to prevent URL sync effects from resetting page size on stale state
    • Removed direct reactive state dependencies in pagination and deep-link hooks to align with React Router v7 async transitions
  • Playwright Test Improvements:
    • Added robust URL and loader assertions across various E2E spec files (common.ts, TestLibrary.spec.ts, ImpactAnalysis.spec.ts, etc.) to handle React Router v7 navigation timing

This will update automatically on new commits.

… condition

- Bump react-router-dom from 6.30.4 to 7.18.1
- In v7, navigate() is wrapped in React.startTransition, deferring the
  router re-render. This caused the column detail panel to reopen after
  close because effects still saw stale URL params during the transition.
- Fix useFqnDeepLink.ts: move selectedColumn to a ref so it is read
  without triggering the effect when closeColumnDetailPanel sets it null.
- Fix GenericProvider.tsx: add skipNextColumnSync ref that is set before
  navigate() in closeColumnDetailPanel and consumed once in the URL-sync
  useEffect, preventing the panel from reopening during the deferred
  re-render window.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Rohit0301
Rohit0301 requested a review from a team as a code owner July 28, 2026 11:59
@github-actions

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

This PR cannot be merged until the following are addressed on its linked issue:

  • No GitHub issue is linked. Link an issue in the Development section of the PR (or add Fixes #12345 to the description). For a same-org cross-repo issue, add Fixes open-metadata/<repo>#123 to the description.

The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically.

Maintainers can bypass this check by adding the skip-pr-checks label.

@github-actions github-actions Bot added the UI UI specific issues label Jul 28, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Hi there 👋 Thanks for your contribution!

The OpenMetadata team will review the PR shortly! Once it has been labeled as safe to test, the CI workflows
will start executing and we'll be able to make sure everything is working as expected.

Let us know if you need any help!

@github-actions

github-actions Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

🔴 Playwright Results — workflow failed

Validated commit 3431846f3926a48adadcd9f7ccc43d395f8335d4 in Playwright run 31880677779, attempt 1.

✅ 4097 passed · ❌ 2 failed · 🟡 36 flaky · ⏭️ 2 skipped · 🧰 0 lifecycle flaky

Pipeline and setup failures (6)

  • Performance target evaluation finished with status failure.
  • Playwright coverage validation found 323 missing, 0 unexpected, 0 duplicate-plan, and 0 duplicate-execution test ID(s).
  • Shard chromium-11 did not upload a usable Playwright results artifact.
  • Shard chromium-21 did not upload a usable Playwright results artifact.
  • Shard chromium-11 test execution finished with status failure without a reported test failure.
  • Shard chromium-21 test execution finished with status failure without a reported test failure.

Performance

Blocking targets: ❌ unmet · Optimization targets: 🟡 in progress

Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting.

🕒 Full workflow signal wall (to summary) 59m 23s

⏱️ Max setup 3m 11s · max shard execution 25m 0s · max shard-job elapsed before upload 28m 48s · reporting 42s

🌐 220.28 requests/attempt · 2.30 app boots/UI scenario · 49.20% common-shard skew

Optimization targets still in progress:

  • Common shard skew was 49.2% (convergence target: at most 15%).
  • Browser traffic was 220.28 requests per attempt (convergence target: fewer than 200).
  • Application boot ratio was 2.3 per UI scenario (10955 boots / 4763 scenarios; convergence target: at most 1).
Shard Passed Failed Flaky Skipped Lifecycle failed Lifecycle flaky
✅ Shard chromium-01 161 0 0 0 0 0
✅ Shard chromium-02 199 0 0 0 0 0
🟡 Shard chromium-03 175 0 1 0 0 0
🟡 Shard chromium-04 157 0 3 1 0 0
✅ Shard chromium-05 175 0 0 0 0 0
🔴 Shard chromium-06 159 1 1 0 0 0
🟡 Shard chromium-07 148 0 3 0 0 0
✅ Shard chromium-08 194 0 0 0 0 0
✅ Shard chromium-09 181 0 0 1 0 0
🟡 Shard chromium-10 169 0 2 0 0 0
⛔ Shard chromium-11
🟡 Shard chromium-12 165 0 1 0 0 0
🟡 Shard chromium-13 145 0 2 0 0 0
🟡 Shard chromium-14 200 0 3 0 0 0
🟡 Shard chromium-15 200 0 4 0 0 0
🟡 Shard chromium-16 197 0 2 0 0 0
🟡 Shard chromium-17 188 0 2 0 0 0
🟡 Shard chromium-18 175 0 1 0 0 0
🟡 Shard chromium-19 225 0 1 0 0 0
🔴 Shard chromium-20 167 1 2 0 0 0
⛔ Shard chromium-21
🟡 Shard chromium-22 160 0 3 0 0 0
🟡 Shard chromium-23 149 0 4 0 0 0
✅ Shard data-asset-rules-01 61 0 0 0 0 0
✅ Shard domain-isolation-01 14 0 0 0 0 0
✅ Shard global-state-01 34 0 0 0 0 0
✅ Shard import-export-01 95 0 0 0 0 0
✅ Shard import-export-02 38 0 0 0 0 0
✅ Shard import-export-03 13 0 0 0 0 0
✅ Shard ingestion-01 53 0 0 0 0 0
🟡 Shard ingestion-02 32 0 1 0 0 0
✅ Shard reindex-01 28 0 0 0 0 0
✅ Shard search-01 11 0 0 0 0 0
✅ Shard search-rbac-01 29 0 0 0 0 0

Genuine Failures (failed on all attempts)

Pages/DescriptionVisibility.spec.tsCustomized Table detail page Description widget shows long description (shard chromium-06)
�[31mTest timeout of 180000ms exceeded.�[39m
Pages/Policies.spec.tsAdd new policy with invalid condition (shard chromium-20)
Error: page.fill: Error: Element is not an <input>, <textarea>, <select> or [contenteditable] and does not have a role allowing [aria-readonly] Call log: �[2m  - waiting for locator('[data-testid="rule-name"]')�[22m �[2m    - locator resolved to <span data-testid="rule-name" class="ant-typography font-medium text-base text-grey-body">Rule / test-5f522127</span>�[22m �[2m    - fill("New / Rule-test-b064e4cd")�[22m �[2m  - attempting fill action�[22m �[2m    - waiting for element to be visible, enabled and editable�[22m 
🟡 36 flaky test(s) (passed on retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-03, 1 retry)
  • Features/LandingPageWidgets/DomainDataProductsWidgets.spec.tsDomain asset count should update when assets are removed (shard chromium-04, 1 retry)
  • Pages/DataContracts.spec.tsPagination in Schema Tab with Selection Persistent (shard chromium-04, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-04, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-06, 1 retry)
  • Features/ExploreQueryBar.spec.tsfilter survives a tree click and both stack as removable chips (shard chromium-07, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-07, 1 retry)
  • Pages/ExplorePageRightPanel.spec.tsShould perform CRUD and Removal operations for database (shard chromium-07, 1 retry)
  • Pages/Glossary.spec.tsApprove and reject glossary term from Glossary Listing (shard chromium-10, 1 retry)
  • Pages/Glossary.spec.tsRequest description task for Glossary (shard chromium-10, 1 retry)
  • Features/EntityRenameConsolidation.spec.tsGlossary - multiple rename + update cycles should preserve terms (shard chromium-12, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-13, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-13, 1 retry)
  • Pages/InputOutputPorts.spec.tsOutput port drawer shows info banner about data product assets (shard chromium-14, 1 retry)
  • Pages/InputOutputPorts.spec.tsLineage with only input ports (shard chromium-14, 1 retry)
  • Pages/InputOutputPorts.spec.tsExit fullscreen with button (shard chromium-14, 1 retry)
  • Features/Glossary/GlossaryMiscOperations.spec.tsshould delete glossary and remove tags from assets (shard chromium-15, 1 retry)
  • Features/Permission.spec.tsPermissions (shard chromium-15, 1 retry)
  • Pages/ExplorePageRightPanel_KnowledgeCenter.spec.tsShould update description for knowledgeCenter (shard chromium-15, 1 retry)
  • Features/MultipleRename.spec.tsGlossary - should handle multiple consecutive renames (shard chromium-15, 1 retry)
  • Flow/AddRoleAndAssignToUser.spec.tsVerify assigned role to new user (shard chromium-16, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-16, 1 retry)
  • Pages/Entity.spec.tsDomain Propagation (shard chromium-17, 1 retry)
  • Pages/ServiceListing.spec.tsshould render the service listing page (shard chromium-17, 1 retry)
  • Pages/UserDetails.spec.tsAdmin user can edit teams from the user profile (shard chromium-18, 1 retry)
  • Features/ContextCenterMemories.spec.tstyping the linked table name in the asset search returns it as a result (shard chromium-19, 1 retry)
  • Pages/DataContracts.spec.tsContract Status badge should be visible on condition if Contract Tab is present/hidden by Persona (shard chromium-20, 1 retry)
  • VersionPages/ClassificationVersionPage.spec.tsClassification version page (shard chromium-20, 1 retry)
  • Features/Permissions/EntityPermissions.spec.tsTable allow common operations permissions (shard chromium-22, 1 retry)
  • Flow/ExploreDiscovery.spec.tsShould display domain and owner of deleted asset in suggestions when showDeleted is on (shard chromium-22, 1 retry)
  • ... and 6 more

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

Comment thread openmetadata-ui/src/main/resources/ui/src/hooks/useFqnDeepLink.ts
@Rohit0301 Rohit0301 self-assigned this Jul 28, 2026
@Rohit0301 Rohit0301 added the safe to test Add this label to run secure Github workflows on PRs label Jul 28, 2026
@github-actions

github-actions Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 66%
66.18% (78046/117917) 50.16% (47129/93954) 51.35% (14178/27606)

@sonarqubecloud

sonarqubecloud Bot commented Aug 5, 2026

Copy link
Copy Markdown

@Rohit0301
Rohit0301 marked this pull request as draft August 6, 2026 13:02
Comment thread openmetadata-ui/src/main/resources/ui/playwright/utils/domain.ts
Comment thread openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts Outdated
Comment on lines 519 to +527
await customTab.focus();
await userPage.keyboard.press('Enter');
await waitForAllLoadersToDisappear(userPage);
await userPage.waitForLoadState('domcontentloaded');

await waitForAllLoadersToDisappear(
userPage,
'entity-detail-widget-skeleton'
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Edge Case: Re-adds no-op waitForLoadState after SPA tab switch

This commit removes the clickTabAndWaitForPanel helper — which waited for the target tabpanel to become active — and reverts to focus() + Enter followed by waitForLoadState('domcontentloaded'). As the just-deleted comments documented, domcontentloaded is a no-op on an SPA tab switch (no real navigation occurs) and provides no synchronization against react-router v7's deferred navigate(), so the previous tab's content can still be in the DOM when the following assertions run. Flakiness is partly mitigated here because each test subsequently waits for a tab-specific element (KnowledgePanel.Description-* / description widget), but consider waiting for the active tabpanel to reintroduce a real guard instead of the no-op load-state wait.

Was this helpful? React with 👍 / 👎

@gitar-bot

gitar-bot Bot commented Aug 15, 2026

Copy link
Copy Markdown
Code Review 👍 Approved with suggestions 6 resolved / 7 findings

Upgrades react-router-dom from v6 to v7 and resolves column panel race conditions using refs and a skip-sync flag. Consider addressing the minor waitForLoadState usage in SPA tab switches.

💡 Edge Case: Re-adds no-op waitForLoadState after SPA tab switch

📄 openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/CustomizeDetailPage.spec.ts:519-527 📄 openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/CustomizeDetailPage.spec.ts:692-699 📄 openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DescriptionVisibility.spec.ts:420-424

This commit removes the clickTabAndWaitForPanel helper — which waited for the target tabpanel to become active — and reverts to focus() + Enter followed by waitForLoadState('domcontentloaded'). As the just-deleted comments documented, domcontentloaded is a no-op on an SPA tab switch (no real navigation occurs) and provides no synchronization against react-router v7's deferred navigate(), so the previous tab's content can still be in the DOM when the following assertions run. Flakiness is partly mitigated here because each test subsequently waits for a tab-specific element (KnowledgePanel.Description-* / description widget), but consider waiting for the active tabpanel to reintroduce a real guard instead of the no-op load-state wait.

✅ 6 resolved
Bug: useFqnDeepLink still re-fires on close via openColumnDetailPanel dep

📄 openmetadata-ui/src/main/resources/ui/src/hooks/useFqnDeepLink.ts:35-49 📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:261-263 📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:426
The stated primary fix (moving selectedColumn to a ref) does not actually stop the reopen race. The effect's dependency array still contains openColumnDetailPanel, and that callback comes from useGenericContext() where it is memoized with selectedColumn?.fullyQualifiedName in its own dep array (GenericProvider.tsx:233-263). So when closeColumnDetailPanel synchronously runs setSelectedColumn(null), openColumnDetailPanel gets a new identity, which re-triggers the useFqnDeepLink effect. Because navigate() is wrapped in React.startTransition in react-router v7, fqn/columnPart (derived from useParams) are still stale (the old column), so findFieldByFQN returns the just-closed column and — since selectedColumnRef.current is now null — the guard null?.fqn !== matched.fqn is true and openColumnDetailPanel(matchedField) reopens the panel. openColumnDetailPanel no longer short-circuits because selectedColumn is null. Fix: also read openColumnDetailPanel (and setExpandedRowKeys) through refs and drop them from the dependency array so the effect only reacts to real URL (fqn/columnPart) and data changes; that way the effect only runs when the URL truly updates (to empty), yielding an early return.

Edge Case: skipNextColumnSync one-shot flag can be consumed by unrelated re-run

📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:140-152 📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:265-279
The skipNextColumnSync guard blocks the very next execution of the sync effect regardless of what triggered it. The effect depends on [extractedColumns, columnFqn, cleanColumn], so if extractedColumns changes (e.g. a background data refresh) during the deferred-navigate window before columnFqn updates, that unrelated run consumes the flag, leaving the actual stale-columnFqn run unguarded. Conversely, if closeColumnDetailPanel runs but columnFqn never changes as a result, the flag stays true and will wrongly suppress the next legitimate deep-link sync. Consider keying the skip to the specific fqn being closed (store the closed columnFqn in the ref and only skip when the effect still sees that same stale value) instead of a blanket one-shot boolean.

Bug: Duplicate const declaration of selectedColumnRef breaks build

📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:87 📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:105
const selectedColumnRef = useRef<ColumnOrTask | null>(null); is declared twice in the same function scope (line 87 and the newly added line 105). Block-scoped const cannot be redeclared, so TypeScript/JS fails to compile with "Cannot redeclare block-scoped variable 'selectedColumnRef'". Remove the duplicate declaration added at line 105 (keep the existing one at line 87).

Quality: Redundant useEffect re-assigns selectedColumnRef already set synchronously

📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:99 📄 openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx:122-124
selectedColumnRef.current is already assigned synchronously on every render at line 99, so the newly added useEffect at lines 122-124 that assigns the same value is redundant. The effect runs after paint and can only ever be a strictly-later, identical write; remove it to avoid confusion about which assignment is authoritative.

Quality: Stale comment references rAF frames not present in code

📄 openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts:82-85
The comment in clickTabAndWaitForPanel (lines 82-85) describes forcing "Two consecutive frames" / "one full paint cycle" via requestAnimationFrame, but no rAF code exists in the function — it relies on waitForResponse, waitForAllLoadersToDisappear, and the aria-selected assertion instead. The leftover comment is misleading; remove or rewrite it to match the actual synchronization strategy.

...and 1 more resolved from earlier reviews

🤖 Prompt for agents
Code Review: Upgrades react-router-dom from v6 to v7 and resolves column panel race conditions using refs and a skip-sync flag. Consider addressing the minor waitForLoadState usage in SPA tab switches.

1. 💡 Edge Case: Re-adds no-op waitForLoadState after SPA tab switch
   Files: openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/CustomizeDetailPage.spec.ts:519-527, openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/CustomizeDetailPage.spec.ts:692-699, openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DescriptionVisibility.spec.ts:420-424

   This commit removes the `clickTabAndWaitForPanel` helper — which waited for the target tabpanel to become active — and reverts to `focus()` + `Enter` followed by `waitForLoadState('domcontentloaded')`. As the just-deleted comments documented, `domcontentloaded` is a no-op on an SPA tab switch (no real navigation occurs) and provides no synchronization against react-router v7's deferred `navigate()`, so the previous tab's content can still be in the DOM when the following assertions run. Flakiness is partly mitigated here because each test subsequently waits for a tab-specific element (`KnowledgePanel.Description-*` / description widget), but consider waiting for the active tabpanel to reintroduce a real guard instead of the no-op load-state wait.

Options

Display: compact → Showing less information.

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

@github-actions

Copy link
Copy Markdown
Contributor

❌ UI Checkstyle Failed

❌ ESLint + Prettier + Organise Imports (src)

One or more source files have linting or formatting issues.

Affected files
  • openmetadata-ui/src/main/resources/ui/src/components/Customization/GenericProvider/GenericProvider.tsx

❌ Playwright - ESLint + Prettier + Organise Imports

One or more Playwright test files have linting or formatting issues.

Affected files
  • openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/CustomizeDetailPage.spec.ts
    • openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/DataProductPersonaCustomization.spec.ts
    • openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProducts.spec.ts
    • openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DescriptionVisibility.spec.ts
    • openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Lineage/LineageFilters.spec.ts
    • openmetadata-ui/src/main/resources/ui/playwright/utils/domain.ts
    • openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts

🔍 ESLint findings in this PR's files — 0 error(s), 57 warning(s)

Errors block the build. Warnings do not yet — they are rules whose backlog is still
being worked down, listed so this PR does not add to it. See docs/ui-code-quality-gate.md.

0 error(s), 57 warning(s) across 11 changed file(s).

Count Rule
35 react-hooks/exhaustive-deps
5 sonarjs/no-duplicate-string
4 openmetadata-imports/no-circular-imports
3 openmetadata-imports/no-lower-layer-page-imports
3 sonarjs/cyclomatic-complexity
2 sonarjs/expression-complexity
1 sonarjs/no-collapsible-if
1 sonarjs/cognitive-complexity
1 jsx-a11y/no-autofocus
1 openmetadata-imports/no-cross-page-imports
All findings
Location Rule Message
🟡 src/components/Customization/GenericProvider/GenericProvider.tsx:27:1 openmetadata-imports/no-lower-layer-page-imports Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here.
🟡 src/components/Customization/GenericProvider/GenericProvider.tsx:30:1 openmetadata-imports/no-circular-imports This runtime import participates in a circular dependency. Extract the shared type/constant/utility or invert the dependency.
🟡 src/components/Customization/GenericProvider/GenericProvider.tsx:32:1 openmetadata-imports/no-circular-imports This runtime import participates in a circular dependency. Extract the shared type/constant/utility or invert the dependency.
🟡 src/components/Customization/GenericProvider/GenericProvider.tsx:37:1 openmetadata-imports/no-circular-imports This runtime import participates in a circular dependency. Extract the shared type/constant/utility or invert the dependency.
🟡 src/components/Customization/GenericTab/GenericTab.tsx:24:1 openmetadata-imports/no-lower-layer-page-imports Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here.
🟡 src/components/Customization/GenericTab/GenericTab.tsx:25:1 openmetadata-imports/no-circular-imports This runtime import participates in a circular dependency. Extract the shared type/constant/utility or invert the dependency.
🟡 src/components/Customization/GenericTab/GenericTab.tsx:77:6 react-hooks/exhaustive-deps React Hook useMemo has a missing dependency: 'handleHeightChange'. Either include it or remove the dependency array.
🟡 src/components/Dashboard/DataModel/DataModels/DataModelsTable.tsx:41:1 openmetadata-imports/no-lower-layer-page-imports Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here.
🟡 src/components/Dashboard/DataModel/DataModels/DataModelsTable.tsx:121:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/components/Dashboard/DataModel/DataModels/DataModelsTable.tsx:188:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'handlePagingChange'. Either include it or remove the dependency array.
🟡 src/components/Dashboard/DataModel/DataModels/DataModelsTable.tsx:232:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'searchDataModels'. Either include it or remove the dependency array.
🟡 src/components/Dashboard/DataModel/DataModels/DataModelsTable.tsx:245:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'fetchDashboardsDataModel'. Either include it or remove the dependency array.
🟡 src/hooks/useFqnDeepLink.ts:51:5 sonarjs/no-collapsible-if Merge this if statement with the nested one.
🟡 src/pages/APICollectionPage/APIEndpointsTab.tsx:123:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/pages/APICollectionPage/APIEndpointsTab.tsx:155:5 react-hooks/exhaustive-deps React Hook useCallback has missing dependencies: 'handlePagingChange' and 'isCustomizationPage'. Either include them or remove the dependency array.
🟡 src/pages/APICollectionPage/APIEndpointsTab.tsx:239:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'searchAPIEndpoints'. Either include it or remove the dependency array.
🟡 src/pages/APICollectionPage/APIEndpointsTab.tsx:257:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'getAPICollectionEndpoints'. Either include it or remove the dependency array.
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:75:43 sonarjs/cyclomatic-complexity {"message":"Function has a complexity of 16 which is greater than 10 authorized.","cost":6,"secondaryLocations":[{"line":75,"column":42,"endLine":75,"endColumn"
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:207:28 sonarjs/cognitive-complexity Refactor this function to reduce its Cognitive Complexity from 20 to the 15 allowed.
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:207:28 sonarjs/cyclomatic-complexity {"message":"Function has a complexity of 11 which is greater than 10 authorized.","cost":1,"secondaryLocations":[{"line":207,"column":27,"endLine":207,"endColum
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:328:23 sonarjs/no-duplicate-string Define a constant instead of duplicating this literal 5 times.
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:521:23 sonarjs/no-duplicate-string Define a constant instead of duplicating this literal 9 times.
🟡 src/pages/ContextCenterPage/ContextCenterDocumentsPage/ContextCenterDocumentsPage.tsx:649:5 sonarjs/expression-complexity Reduce the number of conditional operators (5) used in the expression (maximum allowed 3).
🟡 src/pages/ContextCenterPage/ContextCenterMemoriesPage/ContextCenterMemoriesPage.tsx:98:42 sonarjs/cyclomatic-complexity {"message":"Function has a complexity of 22 which is greater than 10 authorized.","cost":12,"secondaryLocations":[{"line":98,"column":41,"endLine":98,"endColumn
🟡 src/pages/ContextCenterPage/ContextCenterMemoriesPage/ContextCenterMemoriesPage.tsx:759:25 jsx-a11y/no-autofocus The autoFocus prop should not be used, as it can reduce usability and accessibility for users.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:126:6 react-hooks/exhaustive-deps React Hook useMemo has an unnecessary dependency: 'location.search'. Either exclude it or remove the dependency array. Outer scope values like 'location.search'
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:165:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:219:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'handlePagingChange'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:248:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:286:5 react-hooks/exhaustive-deps React Hook useMemo has missing dependencies: 'searchValue' and 't'. Either include them or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:302:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'searchSchema'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:326:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'getSchemaTables'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:340:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'setFilters'. Either include it or remove the dependency array.
🟡 src/pages/DatabaseSchemaPage/SchemaTablesTab.tsx:351:5 react-hooks/exhaustive-deps React Hook useMemo has a missing dependency: 'searchValue'. Either include it or remove the dependency array.
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:107:11 sonarjs/no-duplicate-string Define a constant instead of duplicating this literal 3 times.
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:109:5 react-hooks/exhaustive-deps React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array.
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:219:6 react-hooks/exhaustive-deps React Hook useMemo has missing dependencies: 'deleteRolePermission', 't', and 'viewPolicyPermission'. Either include them or remove the dependency array.
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:221:9 react-hooks/exhaustive-deps The 'fetchRoles' function makes the dependencies of useCallback Hook (at line 243) change on every render. To fix this, wrap the definition of 'fetchRoles' in i
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:288:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'fetchRoles'. Either include it or remove the dependency array.
🟡 src/pages/RolesPage/RolesListPage/RolesListPage.tsx:307:24 sonarjs/no-duplicate-string Define a constant instead of duplicating this literal 4 times.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:35:1 openmetadata-imports/no-cross-page-imports Page features must not import another page feature. Move shared code to components, hooks, interfaces, or pure utilities.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:75:6 react-hooks/exhaustive-deps React Hook useMemo has an unnecessary dependency: 'location.search'. Either exclude it or remove the dependency array. Outer scope values like 'location.search'
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:104:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:147:5 react-hooks/exhaustive-deps React Hook useCallback has a missing dependency: 'pageSize'. Either include it or remove the dependency array.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:183:5 react-hooks/exhaustive-deps React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:201:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'searchStoredProcedure'. Either include it or remove the dependency array.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:217:6 react-hooks/exhaustive-deps React Hook useEffect has a missing dependency: 'fetchStoreProcedureDetails'. Either include it or remove the dependency array.
🟡 src/pages/StoredProcedure/StoredProcedureTab.tsx:251:5 react-hooks/exhaustive-deps React Hook useMemo has missing dependencies: 'searchValue' and 't'. Either include them or remove the dependency array.
🟡 src/pages/UserListPage/UserListPageV1.tsx:130:21 sonarjs/no-duplicate-string Define a constant instead of duplicating this literal 12 times.
🟡 src/pages/UserListPage/UserListPageV1.tsx:162:58 sonarjs/no-nested-functions Refactor this code to not nest functions more than 4 levels deep.

… and 7 more. Run make ui-checkstyle-changed locally for the full list.


Fix locally (fast - only checks files changed in this branch):

make ui-checkstyle-changed

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.

1 participant