Skip to content

fix(matrixify): Set singular metric field for pie and other single-me…#40852

Open
alexandrusoare wants to merge 1 commit into
masterfrom
alexandrusoare/fix/matrixify-piechart-metric
Open

fix(matrixify): Set singular metric field for pie and other single-me…#40852
alexandrusoare wants to merge 1 commit into
masterfrom
alexandrusoare/fix/matrixify-piechart-metric

Conversation

@alexandrusoare
Copy link
Copy Markdown
Contributor

SUMMARY

  • Pie charts (and 11 other singular-metric chart types) all render the same metric when using Matrixify's "split by metric" feature
  • Root cause: MatrixifyGridGenerator sets cellFormData.metrics (plural array), but Pie/Gauge/Funnel/BigNumber/etc. read formData.metric (singular string) — which is never set, so all panels fall back to the default empty metric
  • Fix: also set cellFormData.metric = metrics[0] when assigning per-cell metrics, so singular-metric charts pick up the correct value

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • 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

@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 64.14%. Comparing base (21189ae) to head (94144a8).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #40852   +/-   ##
=======================================
  Coverage   64.14%   64.14%           
=======================================
  Files        2652     2652           
  Lines      143488   143489    +1     
  Branches    33110    33110           
=======================================
+ Hits        92042    92043    +1     
  Misses      49837    49837           
  Partials     1609     1609           
Flag Coverage Δ
javascript 67.87% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@alexandrusoare alexandrusoare marked this pull request as ready for review June 8, 2026 15:23
@dosubot dosubot Bot added the viz:charts:pie Related to the Pie chart label Jun 8, 2026
@bito-code-review
Copy link
Copy Markdown
Contributor

bito-code-review Bot commented Jun 8, 2026

Code Review Agent Run #8b05e0

Actionable Suggestions - 0
Review Details
  • Files reviewed - 2 · Commit Range: 94144a8..94144a8
    • superset-frontend/packages/superset-ui-core/src/chart/components/Matrixify/MatrixifyGridGenerator.test.ts
    • superset-frontend/packages/superset-ui-core/src/chart/components/Matrixify/MatrixifyGridGenerator.ts
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful
    • Eslint (Linter) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

packages size/M viz:charts:pie Related to the Pie chart

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant