Skip to content

Crash when plotting with labels and WebGL #5067

@astrofrog

Description

@astrofrog

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1needed for current cyclebugsomething broken

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions