rusackas opened a new pull request, #43013: URL: https://github.com/apache/superset/pull/43013
Follow-up to #41442. ### SUMMARY The Sunburst chart's null-filtering path groups rows with lodash's `groupBy`, which has to coerce whatever value it's grouping on into a string to use as an object key. That means a SQL NULL and the literal string `"null"` both land under the same `"null"` key and get merged into one group, so which of them survives the "Show Null Values" filter ends up depending on which row happened to land in that group first. Swapped the grouping to use a `Map` instead of a plain-object accumulator, so keys keep their real type/identity instead of getting stringified. A SQL null and the string `"null"` now always produce two separate tree nodes, and the existing `node.name !== null` filter only removes the actual null one. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF N/A, logic fix covered by unit tests. ### TESTING INSTRUCTIONS `cd superset-frontend && npx jest plugins/plugin-chart-echarts/test/utils/treeBuilder.test.ts` Added a couple of tests: one column with a SQL null, the literal string `"null"`, and a normal value all present together, confirming they produce three distinct nodes when nulls are shown, and that turning on the filter drops only the real null. ### ADDITIONAL INFORMATION - [ ] Has associated issue: - [ ] Required feature flags: - [x] Changes UI - [ ] Includes DB Migration - [ ] Introduces new feature or API - [ ] Removes existing feature or API 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
