Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ui) Show editable field info for fields based on exact fieldPath version #12570

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

chriscollins3456
Copy link
Collaborator

We had a bug where if ingestion originally had a v1 fieldPath for a column, then a user adds a tag or a term, this adds a v1 fieldPath in editableSchemaMetadata with this tag/term.
Then if ingestion switches to v2 fieldPath, so whenever we add a tag or term, it adds it under editableSchemaMetadata with the v2 fieldPath.
However, the bug here is that we render the editable info for a field for whichever version of the fieldPath we find first in editableSchemaMetadata - so if we find v2 fieldPath first, we render that always. so we never show the new edits to the v2 field path.

My fix here is that for where we display editable info for a field, it should always match exactly what is coming from schemaMetadata either v1 or v2. That way when you edit a field, it always shows your current edits.

This means there's a possible bug if ingestion switches back and forth between v1 and v2 field paths, we will show the editable info of whatever the current version is. so ideally we don't switch back and forth between the two. But this is better than we currently have

Checklist

  • The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
  • Links to related issues (if applicable)
  • Tests for the changes have been added/updated (if applicable)
  • Docs related to the changes have been added/updated (if applicable). If a new feature has been added a Usage Guide has been added for the same.
  • For any breaking change/potential downtime/deprecation/big changes an entry has been made in Updating DataHub

@github-actions github-actions bot added the product PR or Issue related to the DataHub UI/UX label Feb 6, 2025
@datahub-cyborg datahub-cyborg bot added the needs-review Label for PRs that need review from a maintainer. label Feb 6, 2025
Copy link

codecov bot commented Feb 6, 2025

Codecov Report

Attention: Patch coverage is 80.00000% with 3 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...ema/components/SchemaFieldDrawer/AboutFieldTab.tsx 50.00% 1 Missing ⚠️
...bs/Dataset/Schema/utils/useDescriptionRenderer.tsx 50.00% 1 Missing ⚠️
...set/Schema/utils/useExtractFieldDescriptionInfo.ts 50.00% 1 Missing ⚠️

❌ Your patch check has failed because the patch coverage (80.00%) is below the target coverage (90.00%). You can increase the patch coverage or adjust the target coverage.

Files with missing lines Coverage Δ
...app/entityV2/dataset/profile/schema/utils/utils.ts 39.58% <100.00%> (+1.06%) ⬆️
...t/Schema/utils/useExtractFieldGlossaryTermsInfo.ts 100.00% <100.00%> (ø)
...bs/Dataset/Schema/utils/useExtractFieldTagsInfo.ts 100.00% <100.00%> (ø)
...ema/components/SchemaFieldDrawer/AboutFieldTab.tsx 38.26% <50.00%> (ø)
...bs/Dataset/Schema/utils/useDescriptionRenderer.tsx 78.94% <50.00%> (ø)
...set/Schema/utils/useExtractFieldDescriptionInfo.ts 96.42% <50.00%> (ø)

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4448fc2...144aba0. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-review Label for PRs that need review from a maintainer. product PR or Issue related to the DataHub UI/UX
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant