Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plotly fig.to_image is stucking on windows 11. #126

Open
navdeepm20 opened this issue Jan 25, 2022 · 11 comments
Open

Plotly fig.to_image is stucking on windows 11. #126

navdeepm20 opened this issue Jan 25, 2022 · 11 comments
Labels
bug something broken P3 not needed for current cycle

Comments

@navdeepm20
Copy link

navdeepm20 commented Jan 25, 2022

I was previously in windows 10 21h2 and everything was working fine. Today I switched to windows 11 and the code is freezing very badly.

I also tried this -----

import plotly.io as pio
pio.kaleido.scope.mathjax = None

But not working. Downgrading to v0.1.0post1 helped but any solution for newest release?

@andimattes
Copy link

Having the same problem here. Windows 11 Pro 21H2 with python 3.10.2

fig.write_image() loads indefinitely and the process has to be killed. Using the above-mentioned Kaleido version v0.1.0post1 worked fine!

@jglascock
Copy link

Any word on this one. I have a user that just bought a new machine with Windows 11 and a script that works on everyone else's computer doesn't work on his. We have also tried...
import plotly.io as pio
pio.kaleido.scope.mathjax = None

@navdeepm20
Copy link
Author

Got a solution. Might be it's not the best but a solution.
I was using windows 10 and it was working but not on windows 11. But you can install wsl and use ubuntu from windows store and then can run your projects on that.

@jglascock
Copy link

The solution that I found in #110...was to downgrade to version 0.1.0post1. That was an easier solution and a lot easier to walk a person who is not as computer savvy.

@navdeepm20
Copy link
Author

Yes, I also tried this and it's working too. But if you want to use the newest release then you can try this solution too.

@eromoe
Copy link

eromoe commented Jan 12, 2023

Happen on win10 too

@lorenzo-w
Copy link

I am still experiencing this issue with an up to date plotly, kaleido and windows 11 version. Is anybody working on fixing this?

@CoralLeiCN
Copy link

I am still experiencing this issue with an up to date plotly, kaleido and windows 11 version. Is anybody working on fixing this?

I am using a workaround figure.write_html(). Not sure if it is helpful.

@danalvarez
Copy link

danalvarez commented Feb 26, 2024

Using kaleido via the R reticulate package on Windows 11 to export images generated with plotly in R. Same problem. Downgrading from kaleido 0.2.1 to 0.1.0 worked. Had another computer on Windows 11 where this was not a problem, so the issue might be related to a combination of factors.

@my-tien
Copy link

my-tien commented Mar 25, 2024

Hi there,
my system: Win11 Enterprise 22H2.
I can confirm that plotly gets stuck with kaleido==0.2.1 and that downgrading to kaleido==0.1.0post1 solves the problem for me.

If it helps, I am sometimes able to obtain a stacktrace by putting a breakpoint in io/_kaleido.py L344 (where it calls scope.transform ) and stepping through:

[0325/103510.596:ERROR:dxva_video_decode_accelerator_win.cc(1405)] DXVAVDA fatal error: Could not load mf.dll: The specified module could not be found. (0x7E)
File "***\Lib\site-packages\kaleido\scopes\base.py", line 198, in _ensure_kaleido
raise ValueError(message)
File "***\Lib\site-packages\kaleido\scopes\base.py", line 293, in _perform_transform
self._ensure_kaleido()
File "***\Lib\site-packages\kaleido\scopes\plotly.py", line 153, in transform
response = self._perform_transform(
File "***\Lib\site-packages\plotly\io\_kaleido.py", line 344, in full_figure_for_development
fig = json.loads(scope.transform(fig, format="json").decode("utf-8"))
File "***\Lib\site-packages\plotly\basedatatypes.py", line 3472, in full_figure_for_development
return pio.full_figure_for_development(self, warn, as_dict)

@danalvarez
Copy link

Hi there, my system: Win11 Enterprise 22H2. I can confirm that plotly gets stuck with kaleido==0.2.1 and that downgrading to kaleido==0.1.0post1 solves the problem for me.

If it helps, I am sometimes able to obtain a stacktrace by putting a breakpoint in io/_kaleido.py L344 (where it calls scope.transform ) and stepping through:

[0325/103510.596:ERROR:dxva_video_decode_accelerator_win.cc(1405)] DXVAVDA fatal error: Could not load mf.dll: The specified module could not be found. (0x7E)
File "***\Lib\site-packages\kaleido\scopes\base.py", line 198, in _ensure_kaleido
raise ValueError(message)
File "***\Lib\site-packages\kaleido\scopes\base.py", line 293, in _perform_transform
self._ensure_kaleido()
File "***\Lib\site-packages\kaleido\scopes\plotly.py", line 153, in transform
response = self._perform_transform(
File "***\Lib\site-packages\plotly\io\_kaleido.py", line 344, in full_figure_for_development
fig = json.loads(scope.transform(fig, format="json").decode("utf-8"))
File "***\Lib\site-packages\plotly\basedatatypes.py", line 3472, in full_figure_for_development
return pio.full_figure_for_development(self, warn, as_dict)

Previously 0.1.0 used to work, seems now only 0.1.0post1 works. I would like to ask: Is this an issue that's being worked on?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken P3 not needed for current cycle
Projects
None yet
Development

No branches or pull requests

9 participants