Skip to content

[2.0] Fixes #36018: gate Profiler Settings Save when the stored config fetch fails - #36091

Merged
ShaileshParmar11 merged 1 commit into
2.0from
backport-36034-2.0
Oct 23, 2026
Merged

ShaileshParmar11 merged 1 commit into
2.0from
backport-36034-2.0

Conversation

@ShaileshParmar11

@ShaileshParmar11 ShaileshParmar11 commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Backport of #36034 to 2.0. Fixes #36018.

Describe your changes:

On 2.0, ProfilerSettingsModal only shows a toast when getTableProfilerConfig fails, then renders the form with its defaults and keeps Save enabled. putTableProfileConfig replaces the stored tableProfilerConfig whole, so a single Save after a transient fetch error wipes the table's profile query, include/exclude columns, partitioning and sample settings.

2.0 still has the antd version of this modal, so #36034 does not cherry-pick; this ports the same behaviour by hand:

  • track the failed load (isFetchFailed);
  • show the error message with a Try Again action (existing label.try-again, no new i18n keys) instead of the defaults-filled form;
  • disable Save while the config has not loaded.

Type of change:

  • Bug fix

Tests

ProfilerSettingsModal.test.tsx — two new tests, both failing on unpatched 2.0:

  • a failed load hides the form, disables Save, and issues no PUT;
  • after a failed load, Try Again loads the stored config and Save sends it (profile query, excluded columns), not the defaults.

All 21 tests in the file pass; ESLint/Prettier clean on both files.

Checklist:

  • I have read the CONTRIBUTING document.
  • I have added tests around the new logic.

🤖 Generated with Claude Code

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no actionable issues were found.

Summary

Prevents saving default profiler settings after the stored config fails to load.

  • The profiler settings drawer waits for stored settings before allowing Save.

Reviews (1) · Last reviewed commit: "Fixes #36018: gate Profiler Settings Sav..." · Reviewed by Greptile

…h fails (#36034)

Backport to 2.0. A failed config load left the drawer filled with defaults
and Save enabled; the PUT replaces the stored config whole, so one save wiped
the table's profile query, column lists, partitioning and sample settings.
Show the error with a Try Again action instead of the form and disable Save
until the config loads.
@ShaileshParmar11
ShaileshParmar11 requested a review from a team as a code owner October 23, 2026 10:19
@ShaileshParmar11 ShaileshParmar11 added the UI UI specific issues label Oct 23, 2026
@ShaileshParmar11
ShaileshParmar11 requested review from karthicksharan and removed request for a team October 23, 2026 10:19
@ShaileshParmar11 ShaileshParmar11 added the safe to test Add this label to run secure Github workflows on PRs label Oct 23, 2026
@github-actions

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

This PR cannot be merged until the following are addressed on its linked issue:

  • No GitHub issue is linked. Link an issue in the Development section of the PR (or add Fixes #12345 to the description). For a same-org cross-repo issue, add Fixes open-metadata/<repo>#123 to the description.

The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically.

Maintainers can bypass this check by adding the skip-pr-checks label.

@gitar-bot

gitar-bot Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Code Review ✅ Approved

🔴 High risk · Gating Profiler Settings’ whole-config writes affects stored-data integrity; incorrect fetch-state handling could block valid edits or allow defaults to replace configuration.

Gates the Profiler Settings Save button when the stored table profiler config fails to load on 2.0, hiding the form behind an error message with a Try Again action so defaults can no longer overwrite the saved config. No issues found.

Verification

Rules No rules evaluated

Functional validation Not enabled

Set up

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Options

Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@github-actions

Copy link
Copy Markdown
Contributor

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 68%
68.33% (82957/121397) 53.23% (51387/96521) 53.97% (15281/28311)

@sonarqubecloud

Copy link
Copy Markdown

@ShaileshParmar11
ShaileshParmar11 merged commit 9ca2474 into 2.0 Oct 23, 2026
110 of 149 checks passed
@ShaileshParmar11
ShaileshParmar11 deleted the backport-36034-2.0 branch October 23, 2026 11:51

This branch was previously deployed

1 inactive deployment
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