With a virtual environment this combination is working for me in an ipython notebook, here's the toml snippet I'm using with pdm.
"plotly==5.24.1", "kaleido==0.2.1",