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
{{ message }}
Repository navigation
RecursionError while setting matplotlib backend #148
Traceback (most recent call last):
File "/home/greensort/miniconda2/envs/borowka_fix/lib/python3.7/site-packages/IPython/core/interactiveshell.py", line 3296, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "", line 1, in
matplotlib.use("TkAgg")
File "/home/greensort/pycharm-community-2019.1.1/helpers/pydev/pydev_ipython/matplotlibtools.py", line 70, in patched_use
matplotlib.real_use(*args, **kwargs)
File "/home/greensort/pycharm-community-2019.1.1/helpers/pydev/pydev_ipython/matplotlibtools.py", line 70, in patched_use
matplotlib.real_use(*args, **kwargs)
File "/home/greensort/pycharm-community-2019.1.1/helpers/pydev/pydev_ipython/matplotlibtools.py", line 70, in patched_use
matplotlib.real_use(*args, **kwargs)
[Previous line repeated 2982 more times]
RecursionError: maximum recursion depth exceeded
I'm also having a similar issue. The problem is in the patch_use function in pydev/pydev_ipython/matplotlibtools.py.
It appears what is happening is that matplotlib.real_use is being overwritten with patched_use on some subsequent call of matplotlib.use which leads to an infinite loop.
My intuition is that a fix would involve changing these lines:
Activity
floyebolu commentedon Oct 4, 2019
I'm also having a similar issue. The problem is in the
patch_usefunction in pydev/pydev_ipython/matplotlibtools.py.It appears what is happening is that
matplotlib.real_useis being overwritten withpatched_useon some subsequent call ofmatplotlib.usewhich leads to an infinite loop.My intuition is that a fix would involve changing these lines:
PyDev.Debugger/pydev_ipython/matplotlibtools.py
Lines 75 to 76 in fb6d330
to:
The try-block is to catch if the
real_useattribute exists or not. If it already exists it won't be overwritten.davisidarta commentedon Jul 10, 2020
I'm also having this issue. Any progress on this?
davisidarta commentedon Jul 11, 2020
Needed a full OS reinstall to solve the issue, since no other solution appeared. Everything working fine on Ubuntu 20.
janaben commentedon Mar 28, 2023
I ran into this exact problem today and the solution suggested by @floyebolu worked perfectly.