Description
It appears that null values are not handled well by scattergl. The data that is present is displayed as expected, for example 3 of 4 points are shown in the screenshot below. However mousing around the plot area throws a lot of errors from the hoverPoints
function. For example, Uncaught TypeError: Cannot read property 't' of undefined
.
Reproducible example:
https://jsfiddle.net/bhogan_mitre/u41pn9eo/
I believe this is the underlying function at fault: https://github.com/plotly/plotly.js/blob/master/src/traces/scattergl/hover.js#L15
Would it be appropriate to add some checks in that function on cd
before trying to access cd[0]
? I have also seen errors further down where it makes it past this line:
var stash = cd[0].t;
but fails here:
var x = stash.x;
I will note that this is only an issue with scattergl
and not the normal SVG scatter
.