Skip to content

Fixes <2370>: made required changes to accommodate tempLineageTable in the Lineage tab#27617

Open
satender-kumar-collate wants to merge 4 commits intoopen-metadata:mainfrom
satender-kumar-collate:feat/temp-lineage-table-details
Open

Fixes <2370>: made required changes to accommodate tempLineageTable in the Lineage tab#27617
satender-kumar-collate wants to merge 4 commits intoopen-metadata:mainfrom
satender-kumar-collate:feat/temp-lineage-table-details

Conversation

@satender-kumar-collate
Copy link
Copy Markdown
Contributor

@satender-kumar-collate satender-kumar-collate commented Apr 22, 2026

Describe your changes:

This PR is regarding the UI changes to accommodate the tempLineageTables in the Lineage tab.

Issue 2370

image

Type of change:

  • New feature

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • 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.

New feature

  • The issue properly describes why the new feature is needed, what's the goal, and how we are building it. Any discussion or decision-making process is reflected in the issue.
  • [] I have updated the documentation.
  • [] I have added tests around the new logic.

Summary by Gitar

  • Refined Lineage Logic:
    • Optimized EntityLineageUtils.tsx to use a tempEdgeKeys set for deduplicating edges during graph construction.
    • Updated node type assignment in findUpstream and simplified selection logic in LineageProvider.tsx using an isTempTable flag.
  • Code Cleanup:
    • Cleaned up imports and formatting in TempTableNode.tsx and EntityLineageUtils.tsx for better maintainability.

This will update automatically on new commits.

@satender-kumar-collate satender-kumar-collate requested a review from a team as a code owner April 22, 2026 07:53
@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
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
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 22, 2026

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 61%
62.01% (60369/97342) 42% (31640/75316) 45.04% (9507/21104)

@gitar-bot
Copy link
Copy Markdown

gitar-bot Bot commented Apr 22, 2026

Code Review ✅ Approved 2 resolved / 2 findings

Updates the Lineage tab to support tempLineageTable, resolving issues with duplicate temp edges and incorrect entityType enums.

✅ 2 resolved
Bug: Duplicate temp edges when edge exists in both upstream and downstream

📄 openmetadata-ui/src/main/resources/ui/src/utils/EntityLineageUtils.tsx:1406-1409 📄 openmetadata-ui/src/main/resources/ui/src/utils/EntityLineageUtils.tsx:1434-1448
In extractTempLineageNodes, allEdges is built by concatenating Object.values(upstreamEdges) and Object.values(downstreamEdges). If the same edge appears in both maps (which can happen for edges connecting to the root entity), every tempLineageTables hop on that edge will produce duplicate entries in tempEdges. This results in duplicate edges rendered in the lineage graph.

The tempNodes map correctly prevents duplicate nodes, but tempEdges is a plain array with no deduplication.

Bug: entityType set to node-type enum instead of entity-type enum

📄 openmetadata-ui/src/main/resources/ui/src/utils/EntityLineageUtils.tsx:1373-1385
In createTempTableNode, entityType is set to EntityLineageNodeType.TEMP_TABLE ('temp-table'), which is a node-type enum value, not an EntityType value. The LineageNodeType interface declares entityType as coming from TableSearchSource['entityType'], which typically holds EntityType values like 'table'. Using a node-type enum value here may cause issues in downstream code that switches on entityType expecting standard entity types (e.g., icon resolution, routing, or export logic).

Options

Display: compact → Showing less information.

Comment with these commands to change:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown
Contributor

🟡 Playwright Results — all passed (12 flaky)

✅ 3699 passed · ❌ 0 failed · 🟡 12 flaky · ⏭️ 89 skipped

Shard Passed Failed Flaky Skipped
✅ Shard 1 481 0 0 4
🟡 Shard 2 654 0 2 7
🟡 Shard 3 665 0 1 1
🟡 Shard 4 646 0 2 27
🟡 Shard 5 610 0 1 42
🟡 Shard 6 643 0 6 8
🟡 12 flaky test(s) (passed on retry)
  • Features/BulkEditEntity.spec.ts › Glossary (shard 2, 1 retry)
  • Features/ColumnBulkOperations.spec.ts › should search columns with server-side API call (shard 2, 1 retry)
  • Flow/PersonaFlow.spec.ts › Set default persona for team should work properly (shard 3, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 4, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for DashboardDataModel (shard 4, 1 retry)
  • Pages/Glossary.spec.ts › Add and Remove Assets (shard 5, 2 retries)
  • Pages/Glossary.spec.ts › Column dropdown drag-and-drop functionality for Glossary Terms table (shard 6, 1 retry)
  • Pages/Lineage/DataAssetLineage.spec.ts › verify create lineage for entity - Topic (shard 6, 1 retry)
  • Pages/Lineage/LineageFilters.spec.ts › Verify lineage schema filter selection (shard 6, 1 retry)
  • Pages/Lineage/LineageRightPanel.spec.ts › Verify custom properties tab IS visible for supported type: searchIndex (shard 6, 1 retry)
  • Pages/ServiceEntity.spec.ts › Team as Owner Add, Update and Remove (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants