-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
[Bug]: backend from matplotlibrc not used #21718
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
Comments
Duplicate of #21660 |
I checked that bug-report issue #21660 but despite the changes done in response to that, as mentioned at the top, the problem is still there... unless that problem has not been solved and then this would be a duplicate. What I find baffling is that the matplotlibrc seems to have no impact (btw on 3.4.3 the QtAgg is not appreciated; best way to solve that is to remove the whole /.config/matplotlib/matploblibrc ) |
There has been no release with the fix in that report; did you patch it yourself? |
Did you apply the patch and then build from a completely clean tree, or apply the patch to the build you already made? |
No; patching should have been straight on the source, i.e. a 3.5.0.tar.gz archive after it was unpacked to /tmp, just before building (maybe the script used for this shows that to you: matplotlib_SlackBuild.txt) |
Ok, sorry; I missed updating some dependencies (as I noticed when letting pip do it all; in a virtual environment). After putting these in place it all worked as usual (with the above patches included). |
Bug summary
Import of matplotlib leads to
KeyError: 'webagg.port'
on Slackware64-current.Seems related to #21684, #21662
During building matplotlib from pypi.org source-tar.gz, patches corresponding to above commits had been applied, giving this
matplotlibrc:
Still, also after commenting out
#backend: QtAgg
in either~/.config/matplotlib/matplotlibrc
or in
/usr/lib64/python3.9/site-packages/matplotlib/mpl-data/matplotlibrc
results in this
KeyError: 'webagg.port'
Code for reproduction
Actual outcome
bash-5.1$ python
Python 3.9.9 (main, Nov 20 2021, 19:41:34)
[GCC 11.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import matplotlib
Traceback (most recent call last):
File "", line 1, in
File "/usr/lib64/python3.9/site-packages/matplotlib/init.py", line 895, in
defaultParams = rcsetup.defaultParams = {
File "/usr/lib64/python3.9/site-packages/matplotlib/init.py", line 898, in
rcParamsDefault[key]),
File "/usr/lib64/python3.9/site-packages/matplotlib/init.py", line 674, in getitem
return dict.getitem(self, key)
KeyError: 'webagg.port'
Expected outcome
bash-5.1$ python
Python 3.9.9 (main, Nov 20 2021, 19:41:34)
[GCC 11.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import matplotlib
>>>
Additional information
With matplotlib-3.4.3 nothing like this.
Operating system
Slackware64-15.0-RC2
Matplotlib Version
3.5.0
Matplotlib Backend
not possible
Python version
3.9.9
Jupyter version
not used
Installation
from source (.tar.gz)
The text was updated successfully, but these errors were encountered: