Skip to content

Fixes #33865: Inline lineage editing via node and column menus - #34551

Merged
chirag-madlani merged 76 commits into
mainfrom
lineage-inline-editing
Oct 16, 2026
Merged

chirag-madlani merged 76 commits into
mainfrom
lineage-inline-editing

Conversation

@chirag-madlani

@chirag-madlani chirag-madlani commented Oct 2, 2026 •

Copy link
Copy Markdown
Collaborator

Describe your changes:

Fixes #33865, #25265, #31600

Replaces lineage edit mode with inline editing, so users add or remove lineage directly from the graph, without switching modes or dragging nodes. Asset Lineage tabs use the classic lineage graph with inline editing. The platform Lineage page (/lineage) keeps the hierarchical scene map and is view and export only.

Type of change:

  • New feature

High-level design:

  • Inline editing (asset Lineage tabs): a ⋮ menu on each node offers Edit Upstream, Edit Downstream and Delete; a ⋮ menu on each column offers Edit Upstream and Edit Downstream for column lineage. Both open AddLineagePopover, a slide-out panel built from FilterSelect + DataAssetAsyncSelectList, with a column picker for column targets. Deleting a node asks for confirmation; Delete / Backspace removes the selected node or edge. Edge actions (Edit Pipeline, Delete) live in the edge drawer.
  • Temp tables are plain nodes: no menu, and edges touching them are read-only.
  • Platform Lineage page: view and export only, no edit controls.
  • Removed: the edit-mode toggle, the drag-and-drop sidebar and drag-to-connect node handles. NodeSuggestions and LineageNodeRemoveButton stay unchanged because Collate's ER diagram still imports them; their removal is tracked in Remove NodeSuggestions and LineageNodeRemoveButton once Collate ER diagram stops using them #35330.
  • Scene map: container node cards (logo, name, "Type · kind" subtitle, child-count pill, 340px), a control bar (mini-map toggle, live zoom %, zoom in/out, Fit to screen), a "Data Asset Level" Layers menu, and semantic zoom that drills only into the node under the pointer.
  • Asset lineage fetch: the asset tab fetches its graph once per graph and ignores a response superseded by a newer request. Lineage settings loading after mount used to fetch the same graph twice; when the late response landed after switching to the Column layer it dropped the column rows and edges.
  • Backend: LineageSceneHierarchy.isExpandable treats field-bearing kinds (table, topic, dashboard, container…) as expandable even though the asset band carries no field payloads.
  • No schema or API changes, so no migration.

Tests:

Use cases covered

  • Add an upstream or downstream node from the node ⋮ menu; delete a node and its edges with confirmation
  • Add column lineage from the column ⋮ menu, picking the target column
  • Edit or delete an edge from the edge drawer; temp tables stay read-only
  • Column layer renders column rows and edges reliably after load
  • Service / Domain views on an asset tab; platform /lineage page view, search and export
  • Fit to screen, zoom % readout, semantic zoom drilling

Unit tests

  • Jest: 43 lineage suites, 621 tests passing (src/components/Lineage/**, src/components/Entity/EntityLineage/**, src/utils/Lineage/**), including the new Lineage.integration.test.tsx case for the duplicate fetch (fails without the fix: 2 calls), edgeMutations.test.ts (single error toast on a failed add) and LineageColumnMenu.test.tsx
  • Core components: dropdown.dots-button.test.tsx
  • Java: LineageSceneResolverTest#assetSceneMarksFieldBearingAssetsExpandableWithoutFieldPayloads

Backend integration tests

  • Not applicable (no new or changed API endpoints; the response shape is unchanged)

Ingestion integration tests

  • Not applicable (no ingestion changes)

Playwright (UI) tests

  • Specs updated for the ⋮ menu flow and the classic asset canvas: LineageInteraction, LineageControls, LineageFilters, DataAssetLineage, PlatformLineage, LineageExportPNGSnapshot; helpers in playwright/utils/lineage.ts
  • Run locally against a production build of this branch (2 workers, 1 retry), every lineage spec green:
    • chromium: DataAssetLineage (101), LineagePipelineAnnotator (5), LineageExportPNGSnapshot (1), LineageFilters (15), PlatformLineage (2)
    • Basic: LineageInteraction (25), LineageControls, LineageNodePagination, LineageRightPanel, PlatformLineage (4), LineageSettings

Manual testing performed

  1. Served a production build of this branch against a local OpenMetadata server with sample data
  2. On dim_customer, added an upstream from the node menu, switched to the Column layer, added a column edge from the column menu, then deleted both nodes from the node menu
  3. Opened the platform Lineage page and exported

UI screen recording / screenshots:

lineage-inline-editing.mp4
  • Recorded UI: production build of lineage-inline-editing at dd06eb7ddf2 (after the main merge and the review fixes).
  • Server: local Docker stack (collate_server, MySQL and Elasticsearch containers healthy; /api/v1/system/version returned 200) with the repository sample data. That server image predates this branch, so the LineageSceneHierarchy change is covered by the Java unit test above rather than the recording.
  • Shown: node ⋮ → Edit Upstream → customers; Layers → Column; column ⋮ → Edit Downstream → customer_profile.customer_id; node ⋮ → Delete for both added nodes; platform Lineage page → Export. Each save and delete was asserted against the API response, and the added edges were removed afterwards. Light and dark (AI mode) screenshots of the reviewed screens were checked on the same build.

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 UI changes: I attached a screen recording and/or screenshots above.

  • I have added tests (unit / integration / Playwright as applicable) and listed them above.

  • The issue properly describes why the new feature is needed, what's the goal, and how we are building it.

  • I have updated the documentation.

  • I have added tests around the new logic.

RetriggerView in GreptileConfidence Score: 1/5

Do not merge until graph refresh positioning, pipeline edits and deletion, and nested-field selection are fixed.

Findings

  1. P1 Refreshed graph loses its view ▶
  2. P1 Edits target the wrong connection ▶
  3. P1 Pipeline node deletion breaks ▶
  4. P1 Nested fields cannot be picked ▶
  5. P2 Read-only edges offer edits ▶
  6. P2 New types use legacy names ▶
  7. P2 Helpers stay in component files ▶
  8. P2 New spacing bypasses tokens ▶

Summary

Replaces lineage edit mode with node and column menus on asset tabs, while keeping the platform map view-only.

  • Asset lineage menus add and remove connections directly from the graph.
  • Asset tabs use the classic graph while /lineage keeps its scene map.
  • Asset lineage loads once per graph and ignores older responses.
  • Field-bearing assets can expand to show their fields.
  • Shared dropdown and asset-picker support changes without changing their behavior.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Asset Lineage tab] --> B[EntityLineageCanvas]
  B --> C[Node or column menu]
  C --> D[AddLineagePopover]
  D --> E[Read existing edge details]
  E --> F[Merge and save lineage]
  F --> G[Refetch classic graph]
  B --> H[Edge drawer]
  H --> I[Edit pipeline or delete edge]
  B --> J[Confirm node deletion]
  K[Platform Lineage page] --> L[LineageMap]
  L --> M[View, drill, and export]
Loading

Reviews (1) · Last reviewed commit: "Merge origin/main into lineage-inline-ed..." · Reviewed by Greptile

Add canEditLineage to the lineage store, computed from hasEditAccess,
deleted, platformView, entity type, and scene band instead of the
isEditMode toggle. Remove the Edit Lineage button from CustomControls;
gate the edge overlay buttons, node connectability, delete-key handler,
and drag-drop sidebar on canEditLineage/canEditScene. isEditMode stays
in the store but nothing sets it anymore.
Add a node-delete confirmation dialog, route node removal (menu and
the temporary-node remove button) through it, and make Delete/Backspace
open the node or edge confirmation instead of deleting immediately.
Standalone, props-driven AddLineagePopover: step 1 entity type (filtered to
TABLE and DASHBOARD_DATA_MODEL when opened from a column, since those are the
only search hit shapes getEntityChildrenAndLabel can flatten via its
getTableEntityChildren resolver), step 2 entity search excluding the current
node, step 3 column picker only when opened from a column. Picking the final
value submits immediately (no Add button); placement is left for upstream,
right for downstream, no arrow.

Task 6 will mount this in LineageMap.
Adds LineageNodeMenu (a per-node dots menu) and mounts it in CustomNodeV1
in place of the already-dead always-there remove button. Wires LineageMap
to open the shared AddLineagePopover from the menu's Edit Upstream/Edit
Downstream actions and route Delete through the existing node-delete
confirmation. Closes the popover on canvas pan/zoom.
SceneDrillButton is absolutely positioned over the same top-right corner
as the new node ⋮ menu, so it always painted on top and swallowed the
click. Shift the drill button left via a has-lineage-node-menu modifier
class whenever the menu renders, and give the menu trigger an explicit
24x24 size so the offset matches its real footprint.
Dropdown.DotsButton is a plain function component with no forwardRef, so
ref={triggerRef} placed on it never attached in React 18 and the popover
fell back to the viewport origin. Anchor the ref to the wrapper div both
LineageNodeMenu and LineageColumnMenu already own instead.
Without edit mode an edge click opens the modal edge drawer, which hid the
floating edit/delete toolbar. Editors now get Edit Pipeline / Delete from a
menu in the drawer header; the canvas toolbar is removed.

Also fixes issues edit mode used to mask:
- edge clicks also reached the pane click handler and cleared the selection,
  so aggregated edges never opened the drawer
- a direct load of the Field band lost its column layer to the default layer
  setting, collapsing column lists and hiding metric column edges
- adding a column edge at the Field band always exhausted the scene refetch
  retries because the confirmation only matched entity edges
- Delete key on a selected node matched a drawer copy by reference and never
  fired; match by entity id and only offer it for removable, non-root nodes
- Delete key on a selected edge ignored editability, letting rollup edges reach
  the delete confirmation; require an editable edge
- Dropdown.DotsButton now honours a caller's aria-label, so lineage node, column
  and edge-drawer menus announce their purpose instead of "Open menu"
- The add-lineage popover title names its dialog
- Replace suppressed hook deps in NodeChildren with the real dependencies
- Read-only lineage checks wait for rendered nodes before asserting no menu
Lineage is added from the node and column menus, so the connectable handles
on each node side are no longer needed. The expand/collapse buttons keep
their handle placement classes. Removes the unused drag-connect path and the
dead buildConnectPayload helper.
…oads

The asset band fetches no field payloads, so tables, topics, dashboards and
other field-bearing kinds were reported as non-expandable and semantic zoom
could not drill into them.
- Container nodes (service/database/schema/domain/data product) render
  logo + name, a 'Type · kind' subtitle and a child count pill, at a
  fixed width by node type
- Control bar: mini-map toggle state, zoom level, fit to screen replaces
  fullscreen, aria-labels
- Semantic zoom drills only into the node under the pointer and shows a
  toast when that node has no deeper level
- Hover via ReactFlow node events, full-graph loading overlay, ReactFlow
  as the canvas root with pan-on-focus
Copilot AI balanced review requested due to automatic review settings October 2, 2026 08:50

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

github-actions Bot commented Oct 2, 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 commented Oct 2, 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: 804 → 805
- 4 added, 3 removed, 9 changed spec-list

New source→spec entries:
  openmetadata-ui/src/main/resources/ui/src/components/Lineage/AddLineagePopover/AddLineagePopover.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Lineage/LineageNodeDeleteModal/LineageNodeDeleteModal.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Lineage/LineageNodeMenu/LineageNodeMenu.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Settings/CustomProperty/CustomPropertyTable.tsx

Removed source→spec entries:
  openmetadata-ui/src/main/resources/ui/src/components/Entity/EntityLineage/AppPipelineModel/AddPipeLineModal.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Entity/EntityLineage/EdgeInteractionOverlay.component.tsx
  openmetadata-ui/src/main/resources/ui/src/components/discovery/knowledge-graph/KnowledgeGraph.tsx

Entries whose spec list changed:
  openmetadata-ui/src/main/resources/ui/playwright/support/entity/EntityClass.ts
  openmetadata-ui/src/main/resources/ui/src/components/Entity/EntityLineage/CustomControls.component.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Entity/EntityLineage/LineageControlButtons/LineageControlButtons.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx
  openmetadata-ui/src/main/resources/ui/src/components/Lineage/LineageOverlays/LineageOverlays.tsx
  openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyControlButtons.tsx
  openmetadata-ui/src/main/resources/ui/src/components/discovery/knowledge-graph/KnowledgeGraphViewControls.tsx
  openmetadata-ui/src/main/resources/ui/src/components/observability/Alerts/AlertDetailsPage.tsx
  openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/components/AlertDetailsContent.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

Copilot AI balanced review requested due to automatic review settings October 2, 2026 08:50

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@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 2, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🚦 Removed from the merge queue — manual (2026-10-15T07:39:10Z)

The entry left the queue before it was built, so no checks ran against it.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

Copy link
Copy Markdown
Contributor

🚦 Removed from the merge queue — failed_checks (2026-10-15T13:20:54Z)

Blocked the queue: playwright-summary

  • Maven Collate Tests — maven-collate-ci
  • Postgresql PR Playwright E2E Tests — playwright-summary, playwright / playwright-ci (chromium-06), playwright / playwright-ci (chromium-04), playwright / playwright-ci (chromium-09), playwright / playwright-ci (import-export-01), playwright / playwright-ci (chromium-08)

Failed Playwright tests:

  • Features/ContextCenterMemories.spec.ts › "All Assets" option in asset filter button resets the asset filter
  • Features/ContextCenterMemories.spec.ts › ArrowDown + Enter keyboard navigation selects the linked table result
  • Features/ContextCenterMemories.spec.ts › typing the linked table name in the asset search returns it as a result
  • Features/ImpactAnalysis.spec.ts › Verify switching between table and column level clears filters
  • Features/MetricBulkImportExportEdit.spec.ts › Admin starts exactly one async export job from the metrics listing
  • Pages/Lineage/LineageInteraction.spec.ts › clears field tracing when the pane is selected
  • Pages/Lineage/PlatformLineage.spec.ts › Settings depth change refetches platform lineage

- ImpactAnalysis: match "Asset Level" exactly; the Layers trigger now reads
  "Data Asset Level"
- ContextCenterMemories: the asset search escapes Elasticsearch-reserved
  characters, so compare the unescaped query
- MetricBulkImportExportEdit: Dropdown.DotsButton keeps the caller's
  aria-label, so the metrics menu is named "Actions", not "Open menu"
- LineageInteraction: fire the column click in place; the minimap can cover
  the column after fit
- PlatformLineage: pick a depth different from the current one; the global
  lineage settings are shared with other specs

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

- sv-se: keep main's datahärkomst terminology (#33416) and add this branch's
  new keys in the same wording
- LineageTabContent.less: take main's removal of .no-data-placeholder (#35506)
@github-actions

Copy link
Copy Markdown
Contributor

🚦 Removed from the merge queue — manual (2026-10-15T21:04:16Z)

The entry left the queue before it was built, so no checks ran against it.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

"lineage-map-field-count": "{{count}} fields",
"lineage-map-onboarding-altitude-description": "Overview -> group -> tables -> columns. Zooming changes detail, like Maps country -> city -> street.",
"lineage-map-onboarding-description": "Today, zoom only scales pixels. Here, two separate controls keep you oriented in graphs of any size.",
"lineage-map-onboarding-description": "Navigate lineage like a map. Pan freely, zoom in or out to adjust your level of detail, or switch between different views",

@gitar-bot gitar-bot Bot Oct 15, 2026 •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Quality: sv-se onboarding description still has the old copy

This commit rewrote message.lineage-map-onboarding-description in every locale. The old copy said "Today, zoom only scales pixels..." and the new copy is "Navigate lineage like a map...". sv-se.json was skipped (that's why its diff is +13/-1 instead of +14/-2), so line 4852 still describes the old behaviour. Swedish users will see onboarding text that no longer matches the feature. Update the sv-se value to a translation of the new en-us string.

Translate the updated en-us onboarding description for sv-se:

"lineage-map-onboarding-description": "Navigera i datahärkomsten som på en karta. Panorera fritt, zooma in eller ut för att justera detaljnivån eller växla mellan olika vyer",

Was this helpful? React with 👍 / 👎

Resolves the overlap with #35205: EdgeInfoDrawer keeps this branch's icon
imports (it already uses XClose), the overlay and sidebar #35205 edited stay
deleted, and the antd baseline follows main at 33.
@github-actions

Copy link
Copy Markdown
Contributor

🚦 Removed from the merge queue — manual (2026-10-16T06:28:56Z)

The entry left the queue before it was built, so no checks ran against it.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@gitar-bot

gitar-bot Bot commented Oct 16, 2026

Copy link
Copy Markdown
Code Review 👍 Approved with suggestions 3 closed / 4 findings

🔴 High risk · Inline lineage editing adds and deletes persisted asset and column relationships, so mistaken selections could remove or misstate lineage records.

Replaces lineage edit mode with inline ⋮ menu editing on nodes and columns, adds an AddLineagePopover for upstream/downstream targets, and makes the platform Lineage page view and export only. Resolved this session: popover search error handling, unhandled rejection on failed node delete, and duplicate error toasts on failed add-lineage requests. One open minor suggestion: the sv-se onboarding description at message.lineage-map-onboarding-description still has the old copy and should be translated to match the new en-us string.

💡 Quality: sv-se onboarding description still has the old copy

📄 openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json:4852 📄 openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json:4852

This commit rewrote message.lineage-map-onboarding-description in every locale. The old copy said "Today, zoom only scales pixels..." and the new copy is "Navigate lineage like a map...". sv-se.json was skipped (that's why its diff is +13/-1 instead of +14/-2), so line 4852 still describes the old behaviour. Swedish users will see onboarding text that no longer matches the feature. Update the sv-se value to a translation of the new en-us string.

Translate the updated en-us onboarding description for sv-se
"lineage-map-onboarding-description": "Navigera i datahärkomsten som på en karta. Panorera fritt, zooma in eller ut för att justera detaljnivån eller växla mellan olika vyer",
✅ 3 closed
✅ Edge Case: Popover search ignores errors and can show results for the old type

📄 openmetadata-ui/src/main/resources/ui/src/components/Lineage/AddLineagePopover/AddLineagePopover.tsx:73-87 📄 openmetadata-ui/src/main/resources/ui/src/components/Lineage/AddLineagePopover/AddLineagePopover.tsx:181-185
In AddLineagePopover, the debounced search awaits searchQuery with no try/catch, so a failed search request becomes an unhandled promise rejection. The user gets no toast, and the list stays empty or keeps old results. The pending debounced call is also not cancelled when the type select changes. If the user types and then switches type within 300 ms, the old call still runs and setHits fills the list with entities of the previously chosen type, overwriting the cleared list. Fix: wrap the call in try/catch and show showErrorToast. Call search.cancel() and clear query in the type onSelectionChange, or ignore responses whose index no longer matches the current type.

✅ Bug: Failed node delete causes an unhandled rejection and leaves the canvas half-updated

📄 openmetadata-ui/src/main/resources/ui/src/components/Lineage/EntityLineageCanvas/EntityLineageCanvas.tsx:263-274 📄 openmetadata-ui/src/main/resources/ui/src/components/Lineage/Lineage/Lineage.tsx:1410-1424
removeLineageHandler shows a toast and then rethrows. removeNodeHandler runs the edge deletions in Promise.all, so one failed DELETE rejects the whole call. confirmNodeDelete only has try/finally, so the rejection goes unhandled. Edges whose DELETE already succeeded have been removed from the canvas through removeEdgesBySourceTarget, but setUpdatedEntityLineage and removeNodeById never run. The node stays on screen with some of its edges missing, and the modal closes as though the delete worked. Fix: add a catch in confirmNodeDelete (the toast has already been shown) and call refetchLineage() so the graph matches the server again. Using Promise.allSettled in removeNodeHandler would also work.

✅ Bug: A failed add-lineage request shows two error toasts

📄 openmetadata-ui/src/main/resources/ui/src/components/Lineage/EntityLineageCanvas/EntityLineageCanvas.tsx:243-257 📄 openmetadata-ui/src/main/resources/ui/src/utils/Lineage/handlers/edgeMutations.ts:68-82
saveLineageEdge calls addLineageHandler, which already calls showErrorToast and then rethrows. The catch in handleAddLineageSubmit calls showErrorToast again, so each failed add shows the same error twice. Fix: drop the toast from this catch, or only toast for errors raised before addLineageHandler runs, such as a non-404 failure from the edge-details lookup.

🤖 Prompt for agents
Code Review: Replaces lineage edit mode with inline ⋮ menu editing on nodes and columns, adds an AddLineagePopover for upstream/downstream targets, and makes the platform Lineage page view and export only. Resolved this session: popover search error handling, unhandled rejection on failed node delete, and duplicate error toasts on failed add-lineage requests. One open minor suggestion: the sv-se onboarding description at `message.lineage-map-onboarding-description` still has the old copy and should be translated to match the new en-us string.

1. 💡 Quality: sv-se onboarding description still has the old copy
   Files: openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json:4852, openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json:4852

   This commit rewrote `message.lineage-map-onboarding-description` in every locale. The old copy said "Today, zoom only scales pixels..." and the new copy is "Navigate lineage like a map...". sv-se.json was skipped (that's why its diff is +13/-1 instead of +14/-2), so line 4852 still describes the old behaviour. Swedish users will see onboarding text that no longer matches the feature. Update the sv-se value to a translation of the new en-us string.

   Fix (Translate the updated en-us onboarding description for sv-se):
   "lineage-map-onboarding-description": "Navigera i datahärkomsten som på en karta. Panorera fritt, zooma in eller ut för att justera detaljnivån eller växla mellan olika vyer",

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

Comment on lines +287 to +289
if (!init) {
return <LineageSkeleton />;
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P1 Refreshed graph loses its view

After adding lineage or changing a filter, fetchLineageData sets init to false, which now unmounts ReactFlow. The fetch then centers the old instance before mounting a new one. The redraw effect watches only reactFlowInstance?.viewportInitialized, so replacing one initialized instance with another does not run it again. The new canvas also lacks fitView, leaving the selected asset potentially outside the visible area.

Keep the canvas mounted during refresh, or redraw and center whenever the instance changes.

Comment on lines +218 to +222
onEdgeClick(
canEdit && !touchesTempTable
? { ...edge, data: { ...edge.data, isEditable: true } }
: edge
);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P1 Edits target the wrong connection

When pipelineViewMode is Node, one saved connection is drawn as A → pipeline → B. This handler passes either displayed segment straight to the drawer, but the real A → B connection is stored in data.edge.extraInfo. The drawer and getNewLineageConnectionDetails use the segment endpoints instead. Editing its pipeline, description, or SQL therefore targets A → pipeline or pipeline → B, leaving the intended connection unchanged.

Resolve extraInfo before opening the drawer, as the scene map resolves its original edge.

Comment on lines +1427 to +1439
const removedEdges = await Promise.all(
edgesToRemove.map(async (edge) => {
const edgeData = getEdgeDataFromEdge(edge);
await removeLineageHandler(edgeData);

filteredEdges.push(
...(entityLineage.edges ?? []).filter(
(item) =>
!(
item.fromEntity.id === edgeData.fromId &&
item.toEntity.id === edgeData.toId
)
)
);

removeEdgesBySourceTarget(edgeData.fromId, edgeData.toId);

return edgeData;
})
);

const filteredEdges = withoutLineageEdges(
entityLineage.edges ?? [],
removedEdges

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P1 Pipeline node deletion breaks

The new node menu sends pipeline nodes to removeNodeHandler, which treats displayed segments as separate saved connections. Both segments resolve through extraInfo to the same A → B edge, so deleting the pipeline issues the same DELETE twice; the second can return 404.

Deleting an endpoint also leaves stale segments: withoutLineageEdges and removeEdgesBySourceTarget compare A → B against the displayed A → pipeline and pipeline → B segments, so neither matches. Deduplicate the saved connections and remove their displayed segments together.

Comment on lines +303 to +310
const { children } = getEntityChildrenAndLabel(
entity as unknown as LineageNodeType
);

return children.map((column) => ({
id: column.fullyQualifiedName ?? column.name ?? '',
label: column.name ?? '',
}));

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P1 Nested fields cannot be picked

columnItems only maps the top-level columns returned by the asset API. getEntityChildrenAndLabel does not flatten them; it expects flattenChildren to have been prepared already. A nested field shown on the graph, such as a child of a STRUCT column, therefore cannot be picked as the other endpoint in the replacement editor.

Prepare the asset with the existing flattening helper and include the full field path in each label.

hasEditAccess
visible
edge={selectedEdge}
hasEditAccess={canEditLineage}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 Read-only edges offer edits

canEditEdge correctly excludes temporary-table edges, but EdgeInfoDrawer receives the broader canEditLineage flag. Editors still get the SQL and description edit buttons on those read-only edges. Their save handlers use the synthetic temp_... IDs, so saving fails rather than editing a real connection. Pass canEditEdge to hasEditAccess as well.

import { LineageDirection } from '../../../generated/api/lineage/lineageDirection';
import { EdgeFromToData } from '../../../interface/lineage.interface';

export interface LineageEditRequest {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 New types use legacy names

This new file uses the legacy .interface.ts suffix. The repository guide requires new local type files to use .types.ts; legacy names are only preserved for existing files. Rename it to AddLineagePopover.types.ts and update its imports. The new LineageColumnMenu.interface.ts and LineageNodeMenu.interface.ts files have the same issue. This repository requirement must be satisfied before merging.

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines +70 to +73
// React Flow padding is a share of the viewport, not pixels.
const FIT_VIEW_OPTIONS = { padding: 0.2, maxZoom: 1 };

const toEdgeEntity = (node?: Node): EdgeFromToData | undefined => {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 Helpers stay in component files

The new canvas puts FIT_VIEW_OPTIONS and toEdgeEntity in the component file. The frontend guide requires module-level constants in a constants file and helpers in a utils file, leaving the component file for the component and its props. Move these declarations to sibling files; the new AddLineagePopover.tsx has the same pattern. This repository requirement must be satisfied before merging.

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

// positioned drill button, so shift the drill button clear of the 24px
// menu with enough gap that the two hit areas never overlap.
&.has-lineage-node-menu .lineage-scene-drill-button {
right: 34px;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 New spacing bypasses tokens

The new drill-button offset uses 34px directly. The styling guide requires non-color spacing to use --om-* tokens and says to add a token when no suitable one exists. Replace this literal with a spacing token. New raw offsets also appear in the rail's top calculations. This repository requirement must be satisfied before merging.

Context Used: AGENTS.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@sonarqubecloud

Copy link
Copy Markdown

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.

UI - design alignment for Hirarchical lineage

6 participants