-
Notifications
You must be signed in to change notification settings - Fork 13.9k
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: Temporal X Axis values are not properly displayed if the time column has a custom label defined #20819
Conversation
…has a custom label defined
Codecov Report
@@ Coverage Diff @@
## master #20819 +/- ##
=======================================
Coverage 66.30% 66.30%
=======================================
Files 1758 1758
Lines 66802 66802
Branches 7056 7057 +1
=======================================
Hits 44294 44294
Misses 20710 20710
Partials 1798 1798
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. |
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.
Hi! I still have this issue in 2.0.0 |
@unnyns-307 I think this case had been resolved in the Master branch. I tried to reproduce the issue and used a virtual dataset without date column, the |
Hi @zhaoyongjie, thanks for replying. I think this issue can reproduce by having the datetime column in dataset and then change the type column as string by changing from SQL code of dataset and sync column again then it shows as a string type. I found how to change the Default Datetime setting, we need to access at the USE LEGACY DATASOURCE EDITOR However, this is what I found in Superset V.2.0.0 that the datetime column which is convert to string cannot be plot on x-axis of line chart/generic chart, need to explore on newer version again. |
…has a custom label defined (apache#20819) (cherry picked from commit 51869f3)
SUMMARY
Defining a label to the time column on the dataset level breaks the axis values displayed on the chart, in case the
GENERIC_CHART_AXES
feature flag enabled.The issue is that, by changing the label, we're failing to calculate the proper type of the x axis column, since the dataType mapping is done with the original axis value.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Before:
old.mov
After:
new.mov
TESTING INSTRUCTIONS
Vehicle Sales
dataset.order_date
as the X Axis.sum(price_each)
as the metric.order_date
column.Ensure Months are still properly displayed on the X Axis.
ADDITIONAL INFORMATION
Fixes #20074