Plotly v4 Speed Increase Opportunities

I have a python plotting application that leverages plotly to create plots that typically have a large (~20) number of subplots. I recently upgraded from plotly v2.0.10 to v4.1.0. It was very slow to generate plots using v2, and to fix this I was able to make this change to the plotly code to get a huge speed boost:

Find in graph_objs/
self['data'] += [trace]
Replace with:

Now that I’ve upgraded, the performance problem is back. Is there a similar change I can make in v4 to fix this bottleneck? Am I correct in assuming the poor performance comes from this line in

# Make deep copy of trace data (Optimize later if needed)
new_traces_data = [deepcopy(trace._props) for trace in data]

Any thoughts/tips? Thanks

This is a #api:python question.

The best place to discuss this would probably be a Github issue here … what do you think @jmmease ?

Updated the tags, thanks