Float number in colorscale?

go.Figure(data=go.Scatter(x=[i for i in range(50)], 
                                     y=[0 for _ in range(50)],
                                     mode='markers',
                                     marker=dict(
                                         color=[i for i in range(50)],
                                         colorscale=[[0,'rgb(0,0,0)'], [1,'rgb(254.5,1.0,0)']],
                                         showscale=True)))

This piece of code shows a colorbar with yellow at the top. What’s going on? It will behave well if I change the 1.0 to 0.99 or 1.01 .

Hi @JohnBarren thanks for reporting this weird behaviour. This might be a bug, so I’ve opened an issue in plotly.js https://github.com/plotly/plotly.js/issues/4942 (you can register to this issue on github to be notified about further discussions).