jenwitteng opened a new pull request, #43861: URL: https://github.com/apache/superset/pull/43861
### SUMMARY Matrixify builds a grid of chart cells, injecting a per-cell dimension filter (e.g. `country == 'USA'`) into each cell's `formData`. That filter was appended **only** to `adhoc_filters`. Charts with more than one query route each query through a separate adhoc-filter collection — Mixed Chart reads query A from `adhoc_filters`, query B from `adhoc_filters_b`, query C from `adhoc_filters_c`. As a result, on multi-query charts the Matrixify slice filter was **silently dropped from every query except the first**, so those cells rendered unfiltered data. This change introduces `appendMatrixifyFilters`, which fans the injected filters out to `adhoc_filters` **plus every `adhoc_filters_*` collection** present on the `formData`, so all of a chart's queries are sliced by the cell's dimension value. Design notes: - Non-array values on a matched key are treated as empty. - Each key is reassigned to a **new** array rather than mutating the shared base `formData`, so cells don't contaminate each other. - `matrixify_*` keys are deleted **before** the fan-out, so they can't be matched by the `adhoc_filters_*` pattern. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF N/A — behavior fix, no visual/layout change. Effect: Mixed Chart Matrixify cells now filter query B/C data to the cell's dimension value instead of showing the full, unfiltered series. ### TESTING INSTRUCTIONS Manual: 1. Create a Mixed Chart (query A + query B). 2. Enable Matrixify with a row dimension (e.g. `country` with 2+ values). 3. Before this change: query B's series ignore the per-cell dimension filter (every cell shows the same B data). After: both query A and query B are filtered to the cell's dimension value. Automated: - `superset-ui-core/.../Matrixify/MatrixifyGridGenerator.test.ts` — asserts the dimension filter reaches `adhoc_filters`, `adhoc_filters_b`, and `adhoc_filters_c` (including one that started empty), preserves pre-existing filters, and leaves look-alike keys such as `filters_b` untouched. - `plugin-chart-echarts/test/MixedTimeseries/buildQuery.test.ts` — asserts both compiled queries carry the Matrixify filter and query B's pre-existing free-form filter is preserved. ### ADDITIONAL INFORMATION <!--- Check any relevant boxes with "x" --> <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue --> - [x] Has associated issue: Fixes #39007 - [ ] Required feature flags: - [x] Changes UI - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351)) - [ ] Migration is atomic, supports rollback & is backwards-compatible - [ ] Confirm DB migration upgrade and downgrade tested - [ ] Runtime estimates and downtime expectations provided - [ ] Introduces new feature or API - [ ] Removes existing feature or API -- 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]
