Closed Sibgatulin closed 1 year ago
Firstly, thanks for the module, it has been hugely helpful for me on daily basis!
I'm glad to hear that.
Secondly, calling
plt.show()
withmatplotlib==3.6.0
(specificallymatplotlib-3.6.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
) release results inUserWarning: Matplotlib is currently using module://matplotlib-backend-kitty, which is a non-GUI backend, so cannot show the figure. _Backend.show(*args, **kwargs)
(same goes for
matplotlib-backend-notcurses
, btw).
Thanks for the report. Looks like MPL changed how plugins are initialized. This is prabably an easy fix; I'll take a look at it over the weekend.
How it is going? Thanks!
I downgraded to 3.4.3, this lib is working for me. With latest version, it seems that FigureManagerICat just didn't get registered with matplotlib.
I think that FigureManager.manager_class
isn't getting set to FigureManagerICat
, so drawing the figure happens with the default manager for FigureCanvasAgg
, which is non-GUI.
Probably not the right way of doing things, but setting the manager class manually in _BackendICatAgg
seems to work. Something like:
class _BackendICatAgg(_Backend):
FigureCanvas = FigureCanvasAgg
FigureManager = FigureManagerICat
FigureCanvas.manager_class = FigureManager
@jktr Thank you for matlotlib-backend-kitty, which I use almost every day.
Thanks, @joemilbourn. This seems to have been the underlying issue. I've pushed a proposed fix to the fix/mpl-3.6
branch. It'd be great if you could verify that that fixes it for you.
That works, thank you!
Just wanted to chime in that I also receive this error using mpl-3.5.3. Would the mpl-3.6.0 branch work on 3.5.3 by chance?
Edit: After pip installing the fix/mpl-3.6.0 branch I was able to quickly plot in kitty using the example in the readme using mpl 3.5.3!!
The fix is live. Thanks for your patience.
Firstly, thanks for the module, it has been hugely helpful for me on daily basis!
Secondly, calling
plt.show()
withmatplotlib==3.6.0
(specificallymatplotlib-3.6.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
) release results in(same goes for
matplotlib-backend-notcurses
, btw).I am, unfortunately, at a loss, if I am simply missing something. Please let me know if I can help with more information.