diff --git a/doc/conf.py b/doc/conf.py index 5b2395702e62..45fd6620e373 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -37,7 +37,6 @@ 'IPython.sphinxext.ipython_directive', 'numpydoc', # Needs to be loaded *after* autodoc. 'sphinx_gallery.gen_gallery', - 'matplotlib.sphinxext.mathmpl', 'matplotlib.sphinxext.plot_directive', 'sphinxext.custom_roles', 'sphinxext.github', @@ -45,6 +44,8 @@ 'sphinxext.mock_gui_toolkits', 'sphinxext.skip_deprecated', ] +if sphinx.version_info < (1, 8): + extensions.append('matplotlib.sphinxext.mathmpl') exclude_patterns = ['api/api_changes/*', 'users/whats_new/*'] @@ -84,7 +85,10 @@ def _check_deps(): autosummary_generate = True autodoc_docstring_signature = True -autodoc_default_flags = ['members', 'undoc-members'] +if sphinx.version_info < (1, 8): + autodoc_default_flags = ['members', 'undoc-members'] +else: + autodoc_default_options = {'members': None, 'undoc-members': None} intersphinx_mapping = { 'python': ('https://docs.python.org/3', None), diff --git a/doc/sphinxext/github.py b/doc/sphinxext/github.py index 8f0ffc0d9782..75c5ce10ae9d 100644 --- a/doc/sphinxext/github.py +++ b/doc/sphinxext/github.py @@ -75,7 +75,6 @@ def ghissue_role(name, rawtext, text, lineno, inliner, options={}, content=[]): prb = inliner.problematic(rawtext, rawtext, msg) return [prb], [msg] app = inliner.document.settings.env.app - #app.info('issue %r' % text) if 'pull' in name.lower(): category = 'pull' elif 'issue' in name.lower(): @@ -105,7 +104,6 @@ def ghuser_role(name, rawtext, text, lineno, inliner, options={}, content=[]): :param content: The directive content for customization. """ app = inliner.document.settings.env.app - #app.info('user link %r' % text) ref = 'https://www.github.com/' + text node = nodes.reference(rawtext, text, refuri=ref, **options) return [node], [] @@ -126,7 +124,6 @@ def ghcommit_role(name, rawtext, text, lineno, inliner, options={}, content=[]): :param content: The directive content for customization. """ app = inliner.document.settings.env.app - #app.info('user link %r' % text) try: base = app.config.github_project_url if not base: @@ -146,7 +143,6 @@ def setup(app): :param app: Sphinx application context. """ - app.info('Initializing GitHub plugin') app.add_role('ghissue', ghissue_role) app.add_role('ghpull', ghissue_role) app.add_role('ghuser', ghuser_role)
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: