Black Lives Matter. Please consider donating to Black Girls Code today.

Multi-frames animation don't work well Histogram2dcontour

I would expect that anime (True or False) should produce the same plots.
But if I’m using Histogram2dcontour, this is not working, if it Scatter it is working.
Something is wrong with Histogram2dcontour animation?

from numpy.random import random

from plotly.graph_objs import Histogram2dcontour, Layout, Figure, Scatter
from plotly.offline import download_plotlyjs, init_notebook_mode, plot, iplot

init_notebook_mode(connected=True)

N = 10
random_x = random(N)
random_y = random(N)
print(min(random_x), max(random_x))
print(min(random_y), max(random_y))

anime = True
# anime = False

data = []
frames = []

for i in range(1, 12):
    trace = Histogram2dcontour(
        x=random_x * i,
        y=random_x * i,
        ncontours=20,
        colorscale='Hot',
        zmin=0, zmax=1, 
        reversescale=True
    )
    
    
    if anime:
        if i == 1:
            data.append(trace)
        else:
            frames.append(dict(data=[trace], layout=dict(title='P{}'.format(i), xaxis=dict(title='P{}'.format(i)))))
    else:
        layout = Layout(title='P{}'.format(i),
                        xaxis=dict(title='P{}'.format(i), range=[0, 12]),
                        yaxis=dict(title='P', range=[0, 12]),
                        height=700)

        iplot(Figure(data=[trace], layout=layout), show_link=False)

if anime:
    layout = Layout(title='P1',
                        xaxis=dict(title='P', range=[0, 12]),
                        yaxis=dict(title='P', range=[0, 12]),
                        height=700, width=700,
                        updatemenus=[{'type': 'buttons', 'buttons': [dict(label='Play', method='animate', args=[None])]}])

    iplot(Figure(data=data, layout=layout, frames=frames), show_link=False)