matplotlib broken after `pip install matplotlib --upgrade` to version 2.1.0 My OS X python installation is through homebrew. I then add python software using pip. I recently upgraded matplotlib from version 1.4.3 to 2.1.0 via pip install matplotlib --upgrade, and now matplotlib gives me this error when I try to make a basic plot:

In [1]: plt.plot(np.arange(10))
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
&lt;ipython-input-1-a81699eb47e8&gt; in &lt;module&gt;()
----&gt; 1 plt.plot(np.arange(10))

/usr/local/lib/python2.7/site-packages/matplotlib/pyplot.pyc in plot(*args, **kwargs)
   3227 @_autogen_docstring(Axes.plot)
   3228 def plot(*args, **kwargs):
-&gt; 3229     ax = gca()
   3230     # Deprecated: allow callers to override the hold state
   3231     # by passing hold=True|False

/usr/local/lib/python2.7/site-packages/matplotlib/pyplot.pyc in gca(**kwargs)
    957     matplotlib.figure.Figure.gca : The figure's gca method.
    958     """
--&gt; 959     return gcf().gca(**kwargs)
    960
    961 # More ways of creating axes:

/usr/local/lib/python2.7/site-packages/matplotlib/pyplot.pyc in gcf()
    586         return figManager.canvas.figure
    587     else:
--&gt; 588         return figure()
    589
    590

/usr/local/lib/python2.7/site-packages/matplotlib/pyplot.pyc in figure(num, figsize, dpi, facecolor, edgecolor, frameon, FigureClass, clear, **kwargs)
    554         # FigureManager base class.
    555         if matplotlib.is_interactive():
--&gt; 556             draw_if_interactive()
    557
    558         if _INSTALL_FIG_OBSERVER:

/usr/local/lib/python2.7/site-packages/matplotlib/backend_bases.pyc in draw_if_interactive(cls)
    183             manager = Gcf.get_active()
    184             if manager:
--&gt; 185                 cls.trigger_manager_draw(manager)
    186
    187     @classmethod

TypeError: unbound method trigger_manager_draw() must be called with _BackendMac instance as first argument (got FigureManagerMac instance instead)


I am not sure how to diagnose this. I do have a working Python 3 matplotlib however.

Is this actually a bug within version 2.1.0 of matplotlib?
This is an issue with matplotlib 2.1.0 on macOS. There is a bug which causes this due to some refactoring in the new release. 

It will probably be fixed in a bug fix release soon, but you will have to downgrade if you need it working now.

To install old version: pip uninstall matplotlib &amp;&amp; pip install matplotlib==2.0.2

Refs:


https://github.com/matplotlib/matplotlib/issues/9345
https://github.com/matplotlib/matplotlib/issues/9366
https://github.com/matplotlib/matplotlib/pull/9347