Weekly time grain in mixed chart: ticks and markers not aligned
Screenshot
Description
On a mixed chart using date in the x-axis and weekly time grain, I would expect the x-axis ticks to match the markers, which are set on Mondays. But its just labeling the first of every month and every 7 days since there.
We've also been running into this, both on regular weekly grain and with week starting on Mondays grain.
Unfortunately having weird labels like this on weekly charts makes them pretty useless, and we've been having to paste this data into Sheets to create presentable charts.
I'll add that on line graphs like the OP's, it would be helpful to be able to add padding between the chart edges / axes and the data points to avoid data point labels overlapping axis labels.
Hard to say if this is really wrong... the markers might be in the right place from what I can tell, since all the days do not appear on the X axis, most likely. If your data points are around 2/26, 3/4, 3/12, this might be right. Is this still an issue in 4.1/5.0? Tempted to close as stale if not, but we'd love to see an example chart/dataset export or get more reproduction steps to go on here.
I think https://github.com/apache/superset/pull/33729 will help here if my above theory is correct. Let me know if I'm mistaken, otherwise we'll close this as inactive/not-planned before long.
I'm still facing this issue on Superset 5.0. I've shared some screenshots here.
Took another look at this on current master, and yeah, still a thing. Turns out my #33729 theory was off, that one sets ECharts axisLabel.interval, which only does anything on a category axis, so it's a no-op for the temporal type: 'time' scale that's causing the misaligned ticks here.
Good news is there's already a "Force categorical" toggle that switches the x-axis to a category scale (one bucket = one tick), it was just hidden unless your x-axis column was numeric, so nobody on a time grain could actually reach it. Opened #41221 to expose it for temporal columns too. Default's unchanged, so it's opt-in, but it should sort out the weekly-grain case.
@Gwildor if you're able to build that branch, would love to know if it lines things up on your end.