Repository navigation
Fixes #36615: resolve bare nested-column description suggestion paths to the child column - #36632
Closed
detail-app[bot] wants to merge 2 commits into
Closed
detail-app[bot] wants to merge 2 commits into
detail-app[bot] wants to merge 2 commits into
Conversation
detail-app
Bot
requested review from
harshach
and removed request for
harshach
October 30, 2026 04:12
Contributor
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
detail-app
Bot
force-pushed
the
detail/bug-fix/fixes-36615-resolve-bare-nested-column-description-e0f4cf
branch
from
October 30, 2026 12:22
cc1108d to
91c7932
Compare
…rop duplicate tests
manerow
force-pushed
the
detail/bug-fix/fixes-36615-resolve-bare-nested-column-description-e0f4cf
branch
from
November 4, 2026 10:24
91c7932 to
c40d33f
Compare
manerow
approved these changes
Nov 4, 2026
Contributor
|
Superseded by PR #37051, which removes the field path guessing instead of patching it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Detail bug report: View on Detail
Describe your changes:
Fixes #36615
When a migrated legacy nested-column description suggestion was approved, the accepted text silently overwrote the parent column's description while the nested child the user intended stayed unchanged — and the operation reported success.
Root cause:
FieldPathUtils.parseFieldPath's dot-separator branch treated any trailing 3rd+ segment as a "property" (description/tags). The v2.0.0 suggestion→task migration (MigrationUtil.extractFieldPathFromEntityLink) never appends an explicit.description, so an unquoted nested-column link<#E::table::…::columns::profile.child>migrated to the bare pathcolumns.profile.child. That was mis-parsed as{field=profile, property=child}, and the description walkers ignorepropertyentirely — so the write landed on the parent columnprofileand reported success. The read path (getFieldDescription) had the identical defect, so the pre-write no-op comparison also read the wrong column.I worked on this because approving a suggestion is a destructive, versioned write; a silent mis-target here is data corruption that only surfaces later via the column change event.
Type of change:
High-level design:
N/A — small change.
The fix is in
openmetadata-service/.../FieldPathUtils.java, with two layers:description/tags, in a newKNOWN_FIELD_PROPERTIESset); otherwise the segment folds intofieldName. Socolumns.profile.childresolves to{field=profile.child, property=description}, matching how the quoted formcolumns."profile.child"already resolved. The producer (MigrationUtil.extractFieldPathFromEntityLink) is unchanged — both already-migrated rows and future migrations now resolve correctly.getFieldDescriptionandsetFieldDescriptionnow refuse any path whose parsedproperty != "description", mirroring the existingresolveSuggestionChangeSummaryFieldcontract. A mismatched path (e.g. a…tagspath, or a future mis-parse) can no longer be written/read as a description.Tests:
Use cases covered
columns.profile.personal) writes the nested child and leaves the parent column untouched.tagsis refused by both the description write and the description read, instead of writing or returning a description..description/.tags, quoted nested names,::separators, flat columns, entity-leveldescription) resolve exactly as before. The existingFieldPathUtilsTestcases cover these and still pass.Unit tests
All new tests are in
FieldPathUtilsTestand reuse itsnestedTable()fixture.testParseFieldPath_dotSeparator_bareNestedColumn: replaces the oldpropertyLasttest, which pinned the buggy behaviour.testSetFieldDescription_bareNestedPath_writesChildNotParent: the bug repro.testGetFieldDescription_bareNestedPath_readsChildNotParent: the same bug on the read path.testSetFieldDescription_tagsPath_refusedandtestGetFieldDescription_tagsPath_refused: the two new guards.All five fail against
main'sFieldPathUtilsand pass with this change. Cases that existing tests already cover (.tagsparsing, a missing nested child, deeper nesting) are not repeated. The change is in a pure function, so it is tested at unit level only. The approval wiring around it is already covered byTaskResourceIT.Backend integration tests
TaskResourceIT, which exercisesFieldPathUtilsthrough task approval.Ingestion integration tests
Playwright (UI) tests
Manual testing performed
Built and ran the full local Docker stack via
./docker/run_local_docker.sh -m ui -d mysql(server healthy, no migration NPE). Minted an admin JWT and exercised the suggestion-approval flow end-to-end:profile(descriptionparent-desc) whose nested childchildhad descriptionchild-old.Suggestiontask with the migration's exact payload shape —fieldPath: "columns.profile.child",suggestedValue: "NEW-TEXT"— and approved it. Result:child.description = "NEW-TEXT",profile.descriptionstayedparent-desc. Pre-fix this would have overwrittenprofileand leftchildunchanged.columns::"profile.child"::description; the description landed on the nested child, not the parent.columns.email; the description landed onemail.I did not run the in-process integration tests (
TaskResourceIT,TaskChangeEventIT, …). The sharedTestSuiteBootstrapaborts before any test runs withEntity.getEntityRelationshipRepository()being null during a v200 task-workflow-seeding migration. I confirmed this is pre-existing and unrelated to this change by stashing the fix and re-running the same command — the unmodified base code hits the identical NPE at the same point. The NPE originates inEntityRepository.getOwners()/ v200TaskWorkflowseeding code, none of which this PR touches (the diff isFieldPathUtils.java+ one test file). The production server (with this fix) starts cleanly with no such NPE, which is what enabled the manual end-to-end verification above.UI screen recording:
Not applicable — backend-only change.
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.docs/decisions/(see itsREADME.md). This description is gone fromgit logafter the squash-merge.Automatic Fixes PRs can be configured here.