Skip to content
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

Fix ignoring of matplotlibrc file #1649

Merged
merged 1 commit into from
Apr 9, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ v0.13.0 (unreleased)
v0.12.6 (unreleased)
--------------------

* Fixed a bug that caused matplotlibrc files to not be ignored. [#1649]

* Fixed a non-deterministic error that happened when closing the
TableViewer. [#7310]

Expand Down
7 changes: 5 additions & 2 deletions glue/_mpl_backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,16 @@ def find_module(self, mod_name, pth=None):
set_mpl_backend()

def find_spec(self, name, import_path, target_module=None):
pass
if self.enabled and name.startswith('matplotlib'):
self.enabled = False
set_mpl_backend()


def set_mpl_backend():

try:
from qtpy import PYQT5
except:
except Exception:
# If Qt isn't available, we don't have to worry about
# setting the backend
return
Expand Down