-
Notifications
You must be signed in to change notification settings - Fork 13.8k
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
fix: Box Plot Chart throws an error when the average (AVG) / SUM is being calculated on the Metrics #20235
fix: Box Plot Chart throws an error when the average (AVG) / SUM is being calculated on the Metrics #20235
Conversation
…eing calculated on the Metrics
Codecov Report
@@ Coverage Diff @@
## master #20235 +/- ##
===========================================
- Coverage 66.47% 54.56% -11.91%
===========================================
Files 1727 1726 -1
Lines 64724 64782 +58
Branches 6822 6828 +6
===========================================
- Hits 43024 35349 -7675
- Misses 19969 27698 +7729
- Partials 1731 1735 +4
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the fixing. LGTM
…eing calculated on the Metrics (apache#20235) * fix: Box Plot Chart throws an error when the average (AVG) / SUM is being calculated on the Metrics * add test
SUMMARY
When creating a Box Plot Chart, users can set aggregations on the column(s) that will be applied on the Metrics field. However, if the Average aggregation function is set, the Chart won't load and below error message will be displayed:
ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe''
This may be triggered by:
Issue 1011 - Superset encountered an unexpected error.
The issue is that the boxplot post processing function uses, for most of their operators, the
nanpercentile
function.That function won't work on objects, which is the data type for bigints in postgresql.
By coercing the type to it's numeric form we get rid of that issue.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Before:
Screen.Recording.2022-06-01.at.20.28.19.mov
After:
new.mov
TESTING INSTRUCTIONS
ADDITIONAL INFORMATION