diff --git a/doc/conf.py b/doc/conf.py index 5a68653d38bc..84221b2bce32 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -40,11 +40,12 @@ try: from IPython.sphinxext import ipython_console_highlighting except ImportError: - extensions.append('matplotlib.sphinxext.ipython_console_highlighting') + raise ImportError( + "IPython must be installed to build the matplotlib docs") else: - print("Using IPython's ipython_console_highlighting directive") extensions.append('IPython.sphinxext.ipython_console_highlighting') extensions.append('IPython.sphinxext.ipython_directive') + try: import numpydoc except ImportError: