Skip to content

fix: observability alert and incident manager header style#26467

Merged
ShaileshParmar11 merged 4 commits intomainfrom
observability-alert-feedback
Mar 13, 2026
Merged

fix: observability alert and incident manager header style#26467
ShaileshParmar11 merged 4 commits intomainfrom
observability-alert-feedback

Conversation

@ShaileshParmar11
Copy link
Contributor

@ShaileshParmar11 ShaileshParmar11 commented Mar 13, 2026

Fixes: #26468

This pull request refactors the UI for the Incident Manager and Observability Alerts pages, focusing on improving header presentation and updating test cases to match these changes. The main improvements include replacing custom header layouts with the shared PageHeader component wrapped in an Ant Design Card, updating translation keys for consistency, and adjusting tests to match new data-testid attributes and text.

UI component refactoring:

  • Replaced custom header layouts in IncidentManagerPage and ObservabilityAlertsPage with the shared PageHeader component, wrapped in a Card for a more unified look and easier maintenance. (openmetadata-ui/src/main/resources/ui/src/pages/IncidentManager/IncidentManagerPage.tsx, [1] (openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx, [2] [3]
  • Updated import statements to remove unused components and add required ones for the new layout. (openmetadata-ui/src/main/resources/ui/src/pages/IncidentManager/IncidentManagerPage.tsx, [1] (openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx, [2]

Translation and header consistency:

Test updates:

  • Updated test cases to use new data-testid attributes (heading, sub-heading) and revised expected text values to match the new translation keys and header structure. (openmetadata-ui/src/main/resources/ui/src/pages/IncidentManager/IncidentManagerPage.test.tsx, [1] (openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.test.tsx, [2]
image image

@ShaileshParmar11 ShaileshParmar11 self-assigned this Mar 13, 2026
@ShaileshParmar11 ShaileshParmar11 added the To release Will cherry-pick this PR into the release branch label Mar 13, 2026
@github-actions github-actions bot added safe to test Add this label to run secure Github workflows on PRs UI UI specific issues labels Mar 13, 2026
@ShaileshParmar11 ShaileshParmar11 marked this pull request as ready for review March 13, 2026 09:34
@ShaileshParmar11 ShaileshParmar11 requested a review from a team as a code owner March 13, 2026 09:34
Copy link
Contributor

Copilot AI commented Mar 13, 2026

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

…ions (#26469)

* Initial plan

* fix: add `t` to useMemo dependency arrays in IncidentManagerPage and ObservabilityAlertsPage

Co-authored-by: ShaileshParmar11 <71748675+ShaileshParmar11@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ShaileshParmar11 <71748675+ShaileshParmar11@users.noreply.github.com>
@gitar-bot
Copy link

gitar-bot bot commented Mar 13, 2026

Code Review ✅ Approved 1 resolved / 1 findings

Fixes observability alert and incident manager header styling while addressing a missing t translation dependency in useMemo hooks. No remaining issues found.

✅ 1 resolved
Bug: useMemo with empty deps array omits t dependency

📄 openmetadata-ui/src/main/resources/ui/src/pages/IncidentManager/IncidentManagerPage.tsx:30 📄 openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx:286
Both IncidentManagerPage.tsx and ObservabilityAlertsPage.tsx define pageHeaderData with useMemo(() => ({ header: t(...), subHeader: t(...) }), []). The t function from useTranslation is used inside the memo but missing from the dependency array. If the language changes at runtime, these memoized strings won't update.

This pattern is not used elsewhere in the codebase — other useMemo calls that reference t include it (or other relevant values) in their dependency arrays.

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing less information.

Comment with these commands to change:

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

Was this helpful? React with 👍 / 👎 | Gitar

@github-actions
Copy link
Contributor

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 65%
65.97% (57394/86992) 45.53% (30280/66504) 48.47% (9081/18733)

@ShaileshParmar11 ShaileshParmar11 enabled auto-merge (squash) March 13, 2026 10:15
@sonarqubecloud
Copy link

@github-actions
Copy link
Contributor

🟡 Playwright Results — all passed (25 flaky)

✅ 3313 passed · ❌ 0 failed · 🟡 25 flaky · ⏭️ 183 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 451 0 4 2
🟡 Shard 2 298 0 7 1
🟡 Shard 3 652 0 5 33
🟡 Shard 4 724 0 3 47
🟡 Shard 5 590 0 1 67
🟡 Shard 6 598 0 5 33
🟡 25 flaky test(s) (passed on retry)
  • Features/DataAssetRulesDisabled.spec.ts › Verify the Table entity item action after rules disabled (shard 1, 1 retry)
  • Features/Pagination.spec.ts › should test Stored Procedures normal pagination (shard 1, 1 retry)
  • Pages/Customproperties-part1.spec.ts › sqlQuery shows scrollable CodeMirror container and no expand toggle (shard 1, 1 retry)
  • Pages/CustomThemeConfig.spec.ts › Update Hover and selected Color (shard 1, 1 retry)
  • Features/Table.spec.ts › Tags term should be consistent for search (shard 2, 1 retry)
  • Features/TestSuiteMultiPipeline.spec.ts › TestSuite multi pipeline support (shard 2, 1 retry)
  • Flow/ServiceForm.spec.ts › Verify SSL cert upload with long filename and UI overflow handling (shard 2, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for Directory (shard 2, 1 retry)
  • Pages/ExploreTree.spec.ts › Verify Database and Database Schema available in explore tree (shard 2, 1 retry)
  • Pages/ExploreTree.spec.ts › Verify Database and Database schema after rename (shard 2, 1 retry)
  • Pages/TestSuite.spec.ts › Logical TestSuite (shard 2, 1 retry)
  • Features/Glossary/GlossaryHierarchy.spec.ts › should move term with children to different glossary (shard 3, 1 retry)
  • Features/ImpactAnalysis.spec.ts › verify owner filter for Asset level impact analysis (shard 3, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Features/Permissions/ServiceEntityPermissions.spec.ts › SearchIndex Service allow common operations permissions (shard 3, 1 retry)
  • Features/RestoreEntityInheritedFields.spec.ts › Validate restore with Inherited domain and data products assigned (shard 3, 1 retry)
  • Flow/ExploreDiscovery.spec.ts › Should not display deleted assets when showDeleted is checked but deleted is false in queryFilter (shard 4, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 4, 1 retry)
  • Pages/DataProductAndSubdomains.spec.ts › Add tags to data product via UI (shard 4, 1 retry)
  • Pages/EntityDataConsumer.spec.ts › Glossary Term Add, Update and Remove (shard 5, 1 retry)
  • Pages/Tag.spec.ts › Add and Remove Assets and Check Restricted Entity (shard 6, 1 retry)
  • Pages/Teams.spec.ts › Add and Remove User for Team (shard 6, 1 retry)
  • Pages/Teams.spec.ts › Should not have edit access on team page with no data available (shard 6, 1 retry)
  • Pages/Users.spec.ts › Check permissions for Data Steward (shard 6, 1 retry)
  • VersionPages/EntityVersionPages.spec.ts › Spreadsheet (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

@ShaileshParmar11 ShaileshParmar11 merged commit 5928720 into main Mar 13, 2026
25 checks passed
@ShaileshParmar11 ShaileshParmar11 deleted the observability-alert-feedback branch March 13, 2026 11:26
@github-actions
Copy link
Contributor

Changes have been cherry-picked to the 1.12.2 branch.

github-actions bot pushed a commit that referenced this pull request Mar 13, 2026
* fix: observability alert and incident manager header style

* minor fix

* fix: add `t` to useMemo dependency arrays for pageHeaderData translations (#26469)

* Initial plan

* fix: add `t` to useMemo dependency arrays in IncidentManagerPage and ObservabilityAlertsPage

Co-authored-by: ShaileshParmar11 <71748675+ShaileshParmar11@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ShaileshParmar11 <71748675+ShaileshParmar11@users.noreply.github.com>

---------

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
(cherry picked from commit 5928720)
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 To release Will cherry-pick this PR into the release branch UI UI specific issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Align Observability alerts and incident manager header style with data quality page header style

3 participants