Skip to content

feat(ui): extract TablePureUtils and TagsPureUtils#28673

Merged
shah-harshit merged 4 commits into
mainfrom
feat/extract-table-pure-utils
Jun 5, 2026
Merged

feat(ui): extract TablePureUtils and TagsPureUtils#28673
shah-harshit merged 4 commits into
mainfrom
feat/extract-table-pure-utils

Conversation

@shah-harshit
Copy link
Copy Markdown
Contributor

@shah-harshit shah-harshit commented Jun 3, 2026

Summary

  • Extract 43 pure functions from TableUtils.tsx into new TablePureUtils.ts (tier/certification tag helpers, column utils, schema analysis, data type utils, table joins, field update helpers)
  • Extract 5 functions from TagsUtils.tsx into new TagsPureUtils.ts (tag query filters, permission-based index exclusion, tag redirect links)
  • Both original files re-export all moved symbols for backward compatibility — no consumer changes needed
  • TableUtils.tsx reduced from 1891 to ~1047 lines; TagsUtils.tsx reduced from 677 to ~380 lines

Ref: https://github.com/open-metadata/openmetadata-collate/issues/4230

Test plan

  • npx tsc --noEmit passes (verified locally, 0 new errors)
  • Existing table/tag tests pass unchanged (re-exports maintain import paths)
  • UI checkstyle passes

🤖 Generated with Claude Code

Move 43 pure functions from TableUtils.tsx to TablePureUtils.ts and
5 functions from TagsUtils.tsx to TagsPureUtils.ts. Both original files
re-export all moved symbols for backward compatibility.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@shah-harshit shah-harshit requested a review from a team as a code owner June 3, 2026 16:04
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 3, 2026

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 Jun 3, 2026

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 63%
63.34% (67079/105896) 44.22% (36886/83402) 46.46% (10955/23575)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 3, 2026

🟡 Playwright Results — all passed (13 flaky)

✅ 4260 passed · ❌ 0 failed · 🟡 13 flaky · ⏭️ 88 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 298 0 1 4
✅ Shard 2 803 0 0 9
🟡 Shard 3 800 0 4 8
🟡 Shard 4 850 0 4 12
✅ Shard 5 720 0 0 47
🟡 Shard 6 789 0 4 8
🟡 13 flaky test(s) (passed on retry)
  • Pages/AuditLogs.spec.ts › should apply both User and EntityType filters simultaneously (shard 1, 1 retry)
  • Features/KnowledgeCenterList.spec.ts › Knowledge Center List - Test upvote and downvote buttons (shard 3, 1 retry)
  • Features/RTL.spec.ts › Verify Following widget functionality (shard 3, 1 retry)
  • Features/UserProfileOnlineStatus.spec.ts › Should not show online status for inactive users (shard 3, 1 retry)
  • Flow/IngestionBot.spec.ts › Ingestion bot should be able to access domain specific domain (shard 3, 1 retry)
  • Flow/PersonaFlow.spec.ts › Set default persona for team should work properly (shard 4, 1 retry)
  • Pages/DataContractsSemanticRules.spec.ts › Validate Owner Rule Any_In (shard 4, 1 retry)
  • Pages/DataContractsSemanticRules.spec.ts › Validate DataProduct Rule Any_In (shard 4, 1 retry)
  • Pages/Entity.spec.ts › Tier Add, Update and Remove (shard 4, 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/Lineage/PlatformLineage.spec.ts › Verify domain platform view (shard 6, 1 retry)
  • Pages/LogsViewer.spec.ts › Logs page shows breadcrumb, summary, and log viewer or empty state after opening from bundle suite pipeline tab (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

Comment thread openmetadata-ui/src/main/resources/ui/src/utils/TablePureUtils.ts
@shah-harshit shah-harshit enabled auto-merge (squash) June 4, 2026 05:48
Convert interface, entity type, and other type-only symbols to import type
in TablePureUtils.ts, TableUtils.tsx, TagsPureUtils.ts, TagsUtils.tsx.
Runtime enum members (DataType, LabelType, State, TagSource, SettledStatus,
SearchIndex) remain value imports.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented Jun 4, 2026

@shah-harshit shah-harshit merged commit 89c6aa8 into main Jun 5, 2026
50 checks passed
@shah-harshit shah-harshit deleted the feat/extract-table-pure-utils branch June 5, 2026 04:41
@gitar-bot
Copy link
Copy Markdown

gitar-bot Bot commented Jun 5, 2026

Code Review ✅ Approved

Refactors 48 pure functions from TableUtils and TagsUtils into dedicated files to improve maintainability. Backward compatibility is preserved via re-exports, and no issues were found.

Options

Display: compact → Showing less information.

Comment with these commands to change:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

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.

2 participants