plotly.py icon indicating copy to clipboard operation
plotly.py copied to clipboard

Crash when plotting with labels and WebGL

Open astrofrog opened this issue 10 months ago • 1 comments

The following example crashes:

import plotly.express as px
import numpy as np
from pandas import DataFrame

N = 10

df = DataFrame()
df['x'] = np.random.random(N)
df['y'] = np.random.random(N)
df['label'] = ['a'] * N

fig = px.scatter(df, x='x', y='y', text='label', render_mode='webgl')
fig.write_image('test.png')

with the error:

ValueError: Transform failed with error code 525: POt.indexOf is not a function

This also happens by default for more than 1000 points if render_mode is not explicitly specified.

astrofrog avatar Mar 06 '25 13:03 astrofrog

Thanks @astrofrog - can you please let us know which version of plotly.py you are using? Thanks, Greg

gvwilson avatar Mar 07 '25 17:03 gvwilson