Repository navigation
Fixes 36363: Lineage zoom drill threshold, dark-mode node text and drag re-renders - #36370
Conversation
…oom settles Drilling needed the widest card to fill 60% of the canvas width. A 340px container on a ~1400px canvas reached that at zoom 2.45 against a 2.5 maximum, so drilling only happened at the very end of the zoom range. - ZOOM_IN_SCREEN_FILL is 0.35: containers drill at ~1.43, assets at ~1.21. - The fill is measured on the node being zoomed into (under the pointer, or for button/keyboard zoom the selected node or the drillable node nearest the canvas centre), not the widest card in the scene. - Button/keyboard zoom picks the drillable node nearest the centre within the middle half of the canvas on each axis, instead of drilling only when a single drillable node is in view. - A drill waits 250ms for the zoom to settle; any further move, a pan included, restarts or cancels it.
Only the base node's title used link-primary; the rest used link-gray, whose tertiary text read washed out on dark node cards (gray-400 on raised). All titles now use link-primary in both themes, so the titleColor prop is gone.
The node footer sets no colour, so the node's test summary counts inherited React Flow's fixed #222 node text, dark on dark cards, while the column rows' counts were light. The badge now sets primary text itself.
…rame Dragging a node and holding it at the canvas edge (React Flow auto-pans) crashed the entity lineage page with "Maximum update depth exceeded" in about half of runs; it reproduces on main too. - EntityLineageCanvas gave every node a fresh `data` object whenever `nodes` changed, which is every drag frame, so every node re-rendered. Each node now keeps its extended data until its own data changes. - The handlers context was rebuilt per frame (several handlers depend on `nodes`), re-rendering every consumer (~1000 renders of the search box per drag). It now holds stable wrappers that call the latest handler. - LineageSearchSelect subscribed to the whole store and reset its options on every node change; it selects only what it renders and builds options on open. Crash rate in a headless repro went from ~1 in 2 to ~1 in 8, the same as passing nodes to React Flow unwrapped. The rest is the controlled-node round trip per auto-pan frame; making the drag uncontrolled is a follow-up.
- LineageSearchSelect rebuilds options on open; typing into the focused input reopens the menu after the filter for that text was queued, and the rebuild cancelled it, so a single keystroke or paste showed the unfiltered list. Opening now applies the current search text. - Regression tests: the keystroke-after-close case (fails on the previous commit, passes on main), the handlers context staying the same object when nodes change, and EntityLineageCanvas keeping each node's extended data across a position-only change. Each fails without its fix. - Comments trimmed to the reason.
✅ PR checks passedThe linked issue has a description and all required Shipping project fields set. Thanks! |
…ns, ADR - Unaimed drills (zoom button/keyboard, the Data Assets rail) pick only a drillable node with children near the centre, sharing the predicate getRailDrillFallbackNode already used. The scene API marks empty containers expandable, so the centre fallback could open an empty service; the rail again falls back to a service with assets. - LineageSearchSelect follows nodes added or removed while its menu is open, via a node-id key that drag-only updates leave unchanged. The search filter moves to LineageSearchSelect.utils.ts; its test uses a real zustand store so subscriptions behave as in the app. - Record ADR:2026-10-27-lineage-semantic-zoom-drills-at-35-percent-after-settling and cite it at the constants.
Code Review ✅ Approved 1 closed / 1 findings🟡 Medium risk · Changing lineage zoom thresholds, drill targeting, and search refresh behavior could open unexpected views or omit newly loaded nodes. Lineage zoom now drills at 35% screen fill on the zoomed node after a 250ms settle, with node titles and DQ badge counts moved to primary text for dark mode and fewer re-renders per drag frame. The missing decision record was added and cited at the threshold and settle constants, resolving the open finding. No open issues remain. ✅ 1 closed✅ Quality: Semantic-zoom drill threshold and settle delay have no decision record
VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
|
| Count | Rule |
|---|---|
| 2 | react-hooks/exhaustive-deps |
All findings
| Location | Rule | Message | |
|---|---|---|---|
| 🟡 | src/components/Entity/EntityLineage/CustomNodeV1.component.tsx:392:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has an unnecessary dependency: 'onSceneNodeSelect'. Either exclude it or remove the dependency array. |
| 🟡 | src/components/Lineage/EntityLineageCanvas/EntityLineageCanvas.tsx:132:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'updateEntityData'. Either include it or remove the dependency array. |
Fix locally (fast - only checks files changed in this branch):
make ui-checkstyle-changed
|
🚦 Removed from the merge queue —
|
|
🤖 Backport to |
|
🤖 Backport to |
|
🤖 Backport to |
|
🤖 Not backported to
|
…ag re-renders (#36370) (#36390) * Lineage map: drill at 35% screen fill, on the zoomed node, once the zoom settles Drilling needed the widest card to fill 60% of the canvas width. A 340px container on a ~1400px canvas reached that at zoom 2.45 against a 2.5 maximum, so drilling only happened at the very end of the zoom range. - ZOOM_IN_SCREEN_FILL is 0.35: containers drill at ~1.43, assets at ~1.21. - The fill is measured on the node being zoomed into (under the pointer, or for button/keyboard zoom the selected node or the drillable node nearest the canvas centre), not the widest card in the scene. - Button/keyboard zoom picks the drillable node nearest the centre within the middle half of the canvas on each axis, instead of drilling only when a single drillable node is in view. - A drill waits 250ms for the zoom to settle; any further move, a pan included, restarts or cancels it. * Lineage nodes: every title in primary text Only the base node's title used link-primary; the rest used link-gray, whose tertiary text read washed out on dark node cards (gray-400 on raised). All titles now use link-primary in both themes, so the titleColor prop is gone. * Lineage nodes: node-level DQ badge counts in primary text The node footer sets no colour, so the node's test summary counts inherited React Flow's fixed #222 node text, dark on dark cards, while the column rows' counts were light. The badge now sets primary text itself. * Lineage: stop re-rendering every node and handler consumer per drag frame Dragging a node and holding it at the canvas edge (React Flow auto-pans) crashed the entity lineage page with "Maximum update depth exceeded" in about half of runs; it reproduces on main too. - EntityLineageCanvas gave every node a fresh `data` object whenever `nodes` changed, which is every drag frame, so every node re-rendered. Each node now keeps its extended data until its own data changes. - The handlers context was rebuilt per frame (several handlers depend on `nodes`), re-rendering every consumer (~1000 renders of the search box per drag). It now holds stable wrappers that call the latest handler. - LineageSearchSelect subscribed to the whole store and reset its options on every node change; it selects only what it renders and builds options on open. Crash rate in a headless repro went from ~1 in 2 to ~1 in 8, the same as passing nodes to React Flow unwrapped. The rest is the controlled-node round trip per auto-pan frame; making the drag uncontrolled is a follow-up. * Lineage: address self-review — search filter on reopen, identity tests - LineageSearchSelect rebuilds options on open; typing into the focused input reopens the menu after the filter for that text was queued, and the rebuild cancelled it, so a single keystroke or paste showed the unfiltered list. Opening now applies the current search text. - Regression tests: the keystroke-after-close case (fails on the previous commit, passes on main), the handlers context staying the same object when nodes change, and EntityLineageCanvas keeping each node's extended data across a position-only change. Each fails without its fix. - Comments trimmed to the reason. * Lineage: address bot review — empty-service drills, live search options, ADR - Unaimed drills (zoom button/keyboard, the Data Assets rail) pick only a drillable node with children near the centre, sharing the predicate getRailDrillFallbackNode already used. The scene API marks empty containers expandable, so the centre fallback could open an empty service; the rail again falls back to a service with assets. - LineageSearchSelect follows nodes added or removed while its menu is open, via a node-id key that drag-only updates leave unchanged. The search filter moves to LineageSearchSelect.utils.ts; its test uses a real zustand store so subscriptions behave as in the app. - Record ADR:2026-10-27-lineage-semantic-zoom-drills-at-35-percent-after-settling and cite it at the constants. (cherry picked from commit 4ada25a) Co-authored-by: Chirag Madlani <[email protected]>
#36370 drills in once a card fills 35% of the viewport and the zoom has settled for 250ms, and lets button zoom drill the drillable node nearest the canvas centre. LineageMapPage still wheels over its own node, which targets it either way; its Javadoc and the scale doc now say so.
…sting (#35892) * Fixes #35891: Fix hierarchical lineage issues found in 2.1 release testing Lineage page (/lineage): - The header names the lens the map is drawn through (lineageLens), not the legacy platformView parameter, which the map no longer reads. - The browser tab title names the focused entity; "Entity Lineage" had no placeholder. - PNG export goes through the shared onExportClick, which reads the graph the map now publishes to the lineage store: its laid-out nodes and its edges. Lineage no longer mirrors its empty classic graph over them on this page. PNG export (both lineage views): - The capture fits its frame after beforeCapture mounts the off-screen nodes, at the size it renders (ExportData.getViewport), and hands that frame to the edge overlay. A frame fitted when the modal opened shrank any graph with nodes out of view into a corner of the image. Lineage settings: - The classic page and the AI-mode form send back the fields they do not edit. The settings PUT replaces the whole value, so every save dropped graphPerformanceConfig. Scene API: - GET /v1/lineage/scene answers a malformed query_filter with 400, not 500. Nightly scale benchmark (LineageScenePerformanceScaleIT): - Take the server handle before seeding, which starts the admin-token refresher, and call through server.sdk(). The seed outlasted the login token, and the nightly failed with 401 Expired token. - LineageMapPage follows the map markup #34551 changed: the root crumb is clicked through the breadcrumb trail, fit to screen is a button, and the map renders lineage-map-canvas again, on a wrapper because React Flow overwrites its own root's data-testid. Zoom-in wheels over the benchmark's own service, because the zoom buttons never drill while several services are in view. * chore(playwright): auto-refresh impact-map.generated.json * Keep ExportData.viewport for exports framed up front Collate's ER diagram export still passes a viewport fitted with getViewportForLineageExport(nodes, selector), so both keep their signatures from main. The lineage export fits its frame with the new getExportViewportForNodes through getViewport, which takes precedence over a preset viewport. * Use the core download icon on the lineage export button A new import from assets/svg fails the UI deprecation guard; take Download01 from @openmetadata/ui-core-components/icons instead. * Do not offer saving lineage settings that failed to load The settings PUT replaces the whole value, so saving a form whose load failed would wipe what it does not edit, graphPerformanceConfig included. Both lineage settings forms show the error state with Reload until it loads. * Export the lineage map from the store so the AI-mode header button works #36093 moved the Lineage page's export button into the AI-mode page header, which renders outside <Lineage>, where the lineage handlers context only has its no-op default. LineageExportButton now builds the PNG export itself from the graph the map publishes to the lineage store, and takes the header's button size. The PNG options (frame, edge overlay, capture hooks) move into getLineagePngExportOptions, shared with the asset Lineage tab. Nothing on the Lineage page calls onExportClick any more, so it drops its platform branch. * Describe the map's settled 35% zoom drill in the benchmark docs #36370 drills in once a card fills 35% of the viewport and the zoom has settled for 250ms, and lets button zoom drill the drillable node nearest the canvas centre. LineageMapPage still wheels over its own node, which targets it either way; its Javadoc and the scale doc now say so. --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>



Describe your changes:
Fixes #36363
Follow-up to #36093 from testing the new lineage experience, plus a mitigation for the drag crash tracked in #36362, which this PR partially addresses.
1. Zoom drill threshold (platform Lineage page). Zooming into a node drilled a level only when the widest card filled 60% of the canvas: zoom 2.45 for a 340px service card on a ~1400px canvas, against a 2.5 maximum.
ZOOM_IN_SCREEN_FILLis now0.35: service and container cards drill at ~1.43, asset cards at ~1.21. The threshold was chosen on a dev build.2. Dark mode: lineage node text.
link-primaryin both themes. Previously only the base node did; the rest usedlink-gray, which is gray-400 on dark cards.titleColoris removed.#222node colour, so they were dark on dark cards; the column badges were already light.3. Drag crash mitigation (#36362). Holding a dragged node at the canvas edge, where React Flow auto-pans, crashed the entity Lineage tab with "Maximum update depth exceeded" in about half of headless repro runs. It reproduces on main too.
EntityLineageCanvasgave every node a freshdataobject on every drag frame, re-rendering every node. The extended data is now cached per sourcedata.LineageHandlersContextvalue was rebuilt every frame, because several handlers depend onnodes; it re-rendered every consumer (~1000 renders of the search box per drag). It now holds stable wrappers that call the latest handler.LineageSearchSelectsubscribed to the whole lineage store. It now selects only what it renders and builds options when it opens, applying any search text already typed.Crash rate went from ~1 in 2 to ~1 in 8, the same as passing
nodesto React Flow unwrapped. The rest is the controlled-node round trip on each auto-pan frame; #36362 proposes making the drag uncontrolled.Type of change:
High-level design:
N/A: targeted UI fixes; the reasoning for each is above and in the commit messages.
Tests:
Use cases covered
Unit tests
LineageMap.utils.test.ts:getBoxNearestPointmeasures to box centres.LineageSearchSelect.test.tsx: a keystroke typed after the menu closed with focus kept in the input is filtered. This fails on this branch's earlier commit and passes on main.Lineage.integration.test.tsx: the handlers context value is the same object afternodeschange (fails on main).EntityLineageCanvas.test.tsx(new): each node's extendeddatais the same object across a position-only change (fails on main).8213bce8c9f):isSceneNodeDrillableWithChildren: an empty or non-expandable node is never an unaimed drill target, so the zoom button and the Data Assets rail no longer open an empty service;LineageSearchSelect: nodes loaded while the menu is open appear in the options. The test now uses a real zustand store.src/components/Entity/EntityLineage,src/components/Lineage).LineageMap.component.tsx(no component test exists); both were checked in the browser, below.Backend integration tests
Ingestion integration tests
Playwright (UI) tests
The nine impacted specs (
make playwright_affected; no impact-map gaps) ran locally against a production build of6256b61bfd7, served against a local stack with--workers=4 --retries=1:Flow/LineageSettingsPages/Lineage/DataAssetLineagePages/Lineage/LineageControlsPages/Lineage/LineageFiltersPages/Lineage/LineageInteractionPages/Lineage/LineageLargeResponsePages/Lineage/LineageNodePaginationPages/Lineage/LineageRightPanelPages/Lineage/PlatformLineageResult: 168 passed, 4 flaky (passed on retry), 1 failed, 2 skipped.
DataAssetLineagetests (two timeouts, one data-not-ready check) andLineageFilters"Domains filter" (a timeout).LineageFilters"Owners filter", a 60s timeout. "Tag filter" and "Tier filter" were skipped after it in the serial group.--workers=1 --retries=0, the four metadata-filter tests all passed in 11–15s each.742b11f2b82(the search-box reopen fix and tests) came after this build; it was checked with Jest only.Manual testing performed
sample_datadrilled into it after the step that crossed the threshold;sample_kafka, the node nearest the centre;dim_customerlineage: every node title measuredrgb(238, 240, 244)in dark andrgb(24, 29, 39)in light.UI screen recording:
Dark mode (AI mode), built from
8213bce8c9fand served against a local stack with sample data. The "before" images are from main's behaviour on the same data.Zoom drill on the platform Lineage page. The recording shows two drills:
sample_data, which drills into it once the zoom settles past the threshold;sample_kafka, the service with assets nearest the canvas centre.The local stack has many Playwright seed services, so the map opens at 14%.
lineage-zoom-drill.mp4
Checklist:
Fixes <issue-number>: <short explanation>Fixes #<issue-number>above.REVIEW.md(thepr-checklistskill runs it) and fixed every 🔴 finding, or answered it on the line below.Reviewed
6256b61bfd7; the one 🔴 (an unfiltered list after reopening by typing) is fixed with a regression test in742b11f2b82, along with both 🟡 (tests for the identity changes, trimmed comments).docs/decisions/2026-10-27-lineage-semantic-zoom-drills-at-35-percent-after-settling.md, covering the drill threshold, targeting, settle delay and centre region.🤖 Generated with Claude Code


Confidence Score: 5/5
The latest changes appear safe to merge; both previous findings are fixed.Summary
This PR makes lineage drill sooner after zooming stops, improves dark-mode text, and reduces extra renders during dragging.
Reviews (2) · Last reviewed commit: "Lineage: address bot review — empty-serv..." · Reviewed by Greptile