Skip to content

Conversation

@yan-3005
Copy link
Contributor

@yan-3005 yan-3005 commented Jan 8, 2026

Describe your changes:

Fixes Issue: #2604

duplicateGlossaryTerm.mov

Type of change:

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • I have commented on my code, particularly in hard-to-understand areas.
  • For JSON Schema changes: I updated the migration scripts or explained why it is not needed.

Summary by Gitar

  • Fixed duplicate detection:
    • Changed GlossaryTermRepository.java to use getFullyQualifiedName() instead of getName() for glossaries with dots in their names
  • Enhanced validation:
    • Updated duplicate check to properly handle hierarchical glossary structures (e.g., "my.dotted.glossary")
  • Added test coverage:
    • New test_duplicateTermInGlossaryWithDottedName() in GlossaryTermResourceIT.java validates case-insensitive duplicate prevention

This will update automatically on new commits.


Copy link
Contributor

Copilot AI commented Jan 8, 2026

@yan-3005 I've opened a new pull request, #25155, to work on those changes. Once the pull request is ready, I'll request review from you.

Co-authored-by: yan-3005 <yan-3005@users.noreply.github.com>
@sonarqubecloud
Copy link

sonarqubecloud bot commented Jan 8, 2026

aji-aju
aji-aju previously approved these changes Jan 9, 2026
@gitar-bot
Copy link

gitar-bot bot commented Jan 9, 2026

🔍 CI failure analysis for caec817: CI failures span multiple test suites - Python tests (missing cachetools), Integration tests (infrastructure), and Playwright tests (UI flakiness across diverse features) - all unrelated to this PR's backend glossary validation logic changes.

Issue

Multiple CI job failures across different test suites:

  1. Python tests (4 jobs): Missing cachetools dependency
  2. Integration tests: Infrastructure failures (PostgreSQL/OpenSearch)
  3. Playwright tests: Job playwright-ci-postgresql (3, 6) - job 59896957317
    • 3 hard failures
    • 9 flaky tests
    • 456 tests passed (96% pass rate)

Root Cause

1. Python Tests: Dependency Configuration Issue

ModuleNotFoundError: No module named 'cachetools'

The fix: Explicitly add cachetools to base requirements file to ensure it's always available.

2. Integration Tests: Infrastructure Instability

  • PostgreSQL connection loss
  • OpenSearch cluster failure
  • 4 out of 7759 tests failed (99.9% pass rate)

3. Playwright Tests: UI Test Flakiness

Failed tests (12 total, 9 flaky):

  1. Audit Logs Export (3 tests) - Export flow, filters, response validation
  2. Glossary Permissions - Team-based permissions
  3. Service Permissions - SearchIndex operations
  4. Query Entity - Vote functionality
  5. Restore Entity (2 tests) - MlModel and DashboardDataModel with inherited domains
  6. Settings Navigation - Navigation blocker with unsaved changes
  7. Explore Discovery - Deleted assets display
  8. Metric Entity - Unit of measurement update
  9. Right Entity Panel - Lineage tab verification

Pattern: These are UI interaction tests across completely diverse feature areas (audit logs, permissions, settings, metrics, lineage) - none related to glossary term naming or duplicate detection.

Details

Why ALL failures are unrelated to this PR:

  1. PR scope: Only modifies GlossaryTermRepository.java - changes duplicate detection from getName() to getFullyQualifiedName() for backend validation

  2. Failure distribution: Spans Python (dependency), Java (infrastructure), and JavaScript/Playwright (UI tests) - if this PR caused issues, failures would cluster around glossary/term functionality

  3. Test areas affected: Audit logs, permissions, settings, metrics, lineage - completely unrelated subsystems to glossary term validation

  4. High pass rates: 96-99% of tests passing indicates environmental/flakiness issues, not systemic logic bugs

  5. Flaky test nature: 9 out of 12 Playwright failures are flaky (passed on retry), characteristic of timing/race condition issues in UI tests

Root patterns:

  • Python: Build configuration issue (missing explicit dependency)
  • Integration: Infrastructure service crashes
  • Playwright: UI test timing/race conditions across unrelated features

None of these relate to the glossary term duplicate detection logic changes in this PR.

Code Review ✅ Approved

Clean bug fix that correctly addresses duplicate glossary term detection for glossaries with dotted names. Both backend and E2E tests provide good coverage.

Resolved ✅ 1 resolved
Code Quality: Incorrect comment numbering in test

📄 openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/GlossaryTermResourceIT.java:361
The comment on line 361 says "// 4. Assert that the creation fails" but it should be "// 6. Assert that the creation fails" based on the sequential numbering in the test method. This is a copy-paste oversight from step 4 that creates inconsistency in the test documentation.

Suggested fix: Change the comment to "// 6. Assert that the creation fails" to maintain proper sequential numbering.

What Works Well

The fix correctly uses getFullyQualifiedName() instead of getName() to properly identify glossaries with dots in their names. Comprehensive test coverage includes both Java integration tests and Playwright E2E tests validating case-insensitive duplicate detection.

Tip

Comment Gitar fix CI or enable auto-apply: gitar auto-apply:on

Options

Auto-apply is off Gitar will not commit updates to this branch.
Display: compact Hiding non-applicable rules.

Comment with these commands to change:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | This comment will update automatically (Docs)

@github-actions
Copy link
Contributor

github-actions bot commented Jan 9, 2026

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 65%
65.25% (52213/80020) 43.14% (25832/59878) 46.53% (8094/17394)

@sonarqubecloud
Copy link

sonarqubecloud bot commented Jan 9, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants