Font Size Caching in Plotly Charts?

I’m trying to include a 3D Scatter chart with Plotly and can do it succesfully, but there is a weird bug where the font size for the labels of the datapoints is big for the initial data, but then if the chart is regenerated with new data and there are new labels, then those labels will be super small.

Even weirder, is that if there is a mix of labels from the initial data and new data, then it displays both big and small.

Any ideas on how I might be able to fix this? I am not caching anything explicitly via st.cache but I don’t have this issue in Jupyter so I feel like it might be a caching issue or something else going on under the hood.

Thank you!

Initial Data:

New Data:

Hi @zacheism,
thanks a lot for posting. Can you post the code for the Streamlit app here, so I can try to repro?