You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When instantiating a MatplotlibPane in Panel, I get an attribute error.
import panel as pn
from matplotlib import pyplot as plt
fig, ax = plt.subplots()
ax.plot([0,1,2], [2,2,4])
pn.pane.plot.Matplotlib(fig, interactive=True).show()
Raises
...
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/panel/pane/plot.py", line 170, in _get_widget
from ipympl.backend_nbagg import FigureManager, Canvas, is_interactive
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/ipympl/__init__.py", line 27, in <module>
matplotlib.use('module://ipympl.backend_nbagg')
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/matplotlib/__init__.py", line 1080, in use
plt.switch_backend(name)
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/matplotlib/pyplot.py", line 277, in switch_backend
class backend_mod(matplotlib.backend_bases._Backend):
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/matplotlib/pyplot.py", line 278, in backend_mod
locals().update(vars(importlib.import_module(backend_name)))
File "/home/jovyan/conda-envs/pmat/lib/python3.9/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "/home/jovyan/conda-envs/pmat/lib/python3.9/site-packages/ipympl/backend_nbagg.py", line 431, in <module>
ip.events.register('post_execute', flush_figures)
AttributeError: 'NoneType' object has no attribute 'events'
When instantiating a MatplotlibPane in Panel, I get an attribute error.
Raises
I have tried implementing the pull request suggested in https://discourse.holoviz.org/t/matplotlib-pane-throwing-attributeerror-when-interactive-true/2911/6
but then I get errors:
Here is my env:
The text was updated successfully, but these errors were encountered: