Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct Data Shape for Multi-Series Static Viz #42730

Merged
merged 4 commits into from
May 16, 2024

Conversation

adam-james-v
Copy link
Contributor

@adam-james-v adam-james-v commented May 15, 2024

Fixes: #41787

During the echarts migration, some backend tests needed fixing. In this process, the shape of data (eg. list of cards and their data results from execution) were altered.

This was done to fix failing tests and renders for single series cards (all Questions and many dashcards), but didn't correctly handle a multi-series card.

This conditionally adds back the expected shape.

Perhaps in a follow on PR it's worth inspecting the implementation of the :javascript_visualization render method to clean it up. Probably worth putting some Malli schemas around it too to make it clearer what shape we need.

Fixes: #41787

During the echarts migration, some backend tests needed fixing. In this process, the shape of data (eg. list of cards
and their data results from execution) were altered.

This was done to fix failing tests and renders for single series cards (all Questions and many dashcards), but didn't
correctly handle a multi-series card.

This conditionally adds back the expected shape.

Perhaps in a follow on PR it's worth inspecting the implementation of the :javascript_visualization render method to
clean it up. Probably worth putting some Malli schemas around it too to make it clearer what shape we need.
@metabase-bot metabase-bot bot added .Team/DashViz Dashboard and Viz team visual Run Percy visual testing labels May 15, 2024
Copy link

replay-io bot commented May 15, 2024

Status Complete ↗︎
Commit 7167edd
Results
⚠️ 2 Flaky
2507 Passed

@adam-james-v adam-james-v added the no-backport Do not backport this PR to any branch label May 15, 2024
We haven't made a 'unit' (perhaps more like a small integration test at this point) test for multi series dashcards
yet.

In most other cases, making sure a card (Question) renders properly is sufficient, but the multi series dashcards are
a special case. It's probably useufl to have a test or two, and the dashcards test util should hopefully help future
test writing a bit now too.
@adam-james-v adam-james-v merged commit 2f30a47 into master May 16, 2024
112 checks passed
@adam-james-v adam-james-v deleted the bugfix-41787-multi-series-cards branch May 16, 2024 20:05
Copy link

@adam-james-v Did you forget to add a milestone to the issue for this PR? When and where should I add a milestone?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-backport Do not backport this PR to any branch .Team/DashViz Dashboard and Viz team visual Run Percy visual testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[dc.js migration] missing combined card in subscription
2 participants