Repository navigation
fix(ui): resolve QuickFilterDropdown import on 1.13 - #29208
Conversation
QuickFilterDropdown (cherry-picked via #29168) imported getSelectedOptionLabelString from AdvancedSearchPureUtils, a module that only exists on main (introduced by the un-backported refactor #28704, "extract form/search etc pure utils"). On the 1.13 line that split never happened, so the symbol still lives in AdvancedSearchUtils. Re-point the import (component + test mock) to AdvancedSearchUtils to fix the Collate 1.13 build failure: "Could not resolve ../../utils/AdvancedSearchPureUtils". Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
❌ PR checklist incompleteThis PR cannot be merged until the following are addressed on its linked issue:
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 |
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
Code Review ✅ ApprovedCorrects the QuickFilterDropdown import path to reference AdvancedSearchUtils instead of the missing AdvancedSearchPureUtils module, resolving the build failure on 1.13. OptionsDisplay: compact → Showing less information. Comment with these commands to change:
Was this helpful? React with 👍 / 👎 | Gitar |
What
Re-points the
getSelectedOptionLabelStringimport inQuickFilterDropdown.tsx(and its test mock) from../../utils/AdvancedSearchPureUtils→../../utils/AdvancedSearchUtils, on the 1.13 line only.Why
The Collate 1.13 build fails with:
QuickFilterDropdownwas cherry-picked into 1.13 (#29168) carrying an import ofAdvancedSearchPureUtils— a module that only exists onmain, created by the un-backported refactor #28704 ("extract form/search etc pure utils"). On 1.13 that split never happened, sogetSelectedOptionLabelStringstill lives inAdvancedSearchUtils.tsx(whereDataQualityDashboardandSearchDropdownalready import it from on 1.13).Rather than back-port the large #28704 refactor (18 files, ~±3000 lines), this adapts the cherry-pick to the 1.13 codebase by pointing at the module that actually exists there.
Scope
mainalready hasAdvancedSearchPureUtilsand is unaffected.🤖 Generated with Claude Code
Greptile Summary
This PR fixes a build breakage on the 1.13 branch where
QuickFilterDropdown.tsx(cherry-picked from main in #29168) importedgetSelectedOptionLabelStringfromAdvancedSearchPureUtils— a module introduced on main by #28704 that was never back-ported to 1.13. The fix re-points both the production import and the Jest mock toAdvancedSearchUtils, which exports the function on 1.13 (confirmed at line 242).QuickFilterDropdown.tsx: import path corrected from../../utils/AdvancedSearchPureUtils→../../utils/AdvancedSearchUtils; no logic changes.QuickFilterDropdown.test.tsx:jest.mocktarget updated to match the new import path, keeping the mock in sync with the module being tested.Confidence Score: 5/5
Safe to merge — two-line import path fix that unblocks the 1.13 build with no logic changes.
Both changed lines are pure import redirects; getSelectedOptionLabelString is confirmed to exist and be exported from AdvancedSearchUtils on 1.13, and AdvancedSearchPureUtils is confirmed absent. The test mock is updated consistently, so the test suite will resolve correctly as well.
No files require special attention.
Important Files Changed
Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A[QuickFilterDropdown.tsx] -->|"imports getSelectedOptionLabelString"| B{1.13 branch?} B -->|"Before (broken)"| C["AdvancedSearchPureUtils ❌\n(only exists on main)"] B -->|"After (fixed)"| D["AdvancedSearchUtils ✅\n(exists on 1.13, line 242)"] E[QuickFilterDropdown.test.tsx] -->|"jest.mock"| F{1.13 branch?} F -->|"Before (broken)"| G["AdvancedSearchPureUtils ❌"] F -->|"After (fixed)"| H["AdvancedSearchUtils ✅"]%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%% flowchart TD A[QuickFilterDropdown.tsx] -->|"imports getSelectedOptionLabelString"| B{1.13 branch?} B -->|"Before (broken)"| C["AdvancedSearchPureUtils ❌\n(only exists on main)"] B -->|"After (fixed)"| D["AdvancedSearchUtils ✅\n(exists on 1.13, line 242)"] E[QuickFilterDropdown.test.tsx] -->|"jest.mock"| F{1.13 branch?} F -->|"Before (broken)"| G["AdvancedSearchPureUtils ❌"] F -->|"After (fixed)"| H["AdvancedSearchUtils ✅"]Reviews (1): Last reviewed commit: "fix(ui): resolve QuickFilterDropdown imp..." | Re-trigger Greptile