Skip to content

Deprecation warnings related to engine parameter raised when not specifying engine parameter #5286

@jdbeel

Description

@jdbeel

When running notebooks with plotly[kaleido]==6.2.0 there are instances when deprecation warnings are emitted given the same parameterization of a plot function. I had hoped to include a very sensible reproduction case for this issue, but unfortunately it's so much stranger than that.

The issue only appears to happen when instantiating a class from another library I am working with. This library is opening a handle to some binaries on my system, which is my only idea as to why there would be any difference from Jupyter or plotly's perspective. I've attached a notebook with a requirements file, but I'll go over the issue here as well.

In short,

import os
os.environ["PLOTLY_RENDERER"] = "svg"

import pmlb
import plotly.express as px

from howso.engine import Trainee

df = pmlb.fetch_data("iris")

t = Trainee()

fig = px.scatter(df, x="sepal-width", y="sepal-length", color="target")
fig.show()

produces the following warning:

file:///C:/Users/JacobBeel/workspace/plotly.py/plotly/io/_base_renderers.py:123: DeprecationWarning:


Support for the 'engine' argument is deprecated and will be removed after September 2025.
Kaleido will be the only supported engine at that time.

Whereas

import os
os.environ["PLOTLY_RENDERER"] = "svg"

import pmlb
import plotly.express as px

from howso.engine import Trainee

df = pmlb.fetch_data("iris")

fig = px.scatter(df, x="sepal-width", y="sepal-length", color="target")
fig.show()

does not. Note that all I've done is not instantiate the Trainee class.

plotly_warning.zip

I have managed a fix which I'm going to PR, but it doesn't really address the strangeness of the reproduction.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions